From 43d7488cffb2e6eab87af36b8db51e60acb2f5c5 Mon Sep 17 00:00:00 2001 From: hunt Date: Fri, 22 Sep 2006 16:37:51 +0000 Subject: 2006-09-22 Martin Hunt * print.c: Replace STP_PRINT_BUF_LEN with STP_BUFFER_SIZE. * string.c: Ditto. --- runtime/print.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'runtime/print.c') diff --git a/runtime/print.c b/runtime/print.c index 674bd4a0..904104f8 100644 --- a/runtime/print.c +++ b/runtime/print.c @@ -41,14 +41,11 @@ #define STP_PRINT_BUF_START (STP_TIMESTAMP_SIZE) -#ifndef STP_PRINT_BUF_LEN -#define STP_PRINT_BUF_LEN 8192 -#endif typedef struct __stp_pbuf { uint32_t len; /* bytes used in the buffer */ char timestamp[STP_TIMESTAMP_SIZE]; - char buf[STP_PRINT_BUF_LEN]; + char buf[STP_BUFFER_SIZE]; } _stp_pbuf; void *Stp_pbuf = NULL; @@ -118,10 +115,10 @@ static void * _stp_reserve_bytes (int numbytes) static void * _stp_reserve_bytes (int numbytes) { _stp_pbuf *pb = per_cpu_ptr(Stp_pbuf, smp_processor_id()); - int size = STP_PRINT_BUF_LEN - pb->len; + int size = STP_BUFFER_SIZE - pb->len; void * ret; - if (unlikely(numbytes == 0 || numbytes > STP_PRINT_BUF_LEN)) + if (unlikely(numbytes == 0 || numbytes > STP_BUFFER_SIZE)) return NULL; if (numbytes > size) -- cgit