From 8772093db493fc3309b2c29dbdf738ce1645cc88 Mon Sep 17 00:00:00 2001 From: David Smith Date: Wed, 15 Jul 2009 11:16:51 -0500 Subject: Implemented ring_buffer iterators. * runtime/transport/ring_buffer.c (_stp_ring_buffer_empty_cpu): New function. (_stp_ring_buffer_empty): Ditto. (_stp_ring_buffer_iterator_increment): Ditto. (_stp_tracing_wait_pipe): Calls _stp_ring_buffer_empty() instead of ring_buffer_empty(). (_stp_peek_next_event): Looks at iterators first. (_stp_find_next_event): Calls _stp_ring_buffer_empty_cpu() and increments iterator. (_stp_data_read_trace): Opens and closes ring_buffer iterators. (_stp_data_poll_trace): Calls _stp_ring_buffer_empty(). (__stp_relay_wakeup_timer): Ditto. * runtime/transport/control.c (_stp_ctl_write_cmd): Increased level required to get a debug print. --- runtime/transport/control.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'runtime/transport/control.c') diff --git a/runtime/transport/control.c b/runtime/transport/control.c index 35130f0f..925a6768 100644 --- a/runtime/transport/control.c +++ b/runtime/transport/control.c @@ -34,8 +34,7 @@ static ssize_t _stp_ctl_write_cmd(struct file *file, const char __user *buf, siz count -= sizeof(u32); buf += sizeof(u32); - -#ifdef DEBUG_TRANS +#if defined(DEBUG_TRANS) && (DEBUG_TRANS >= 2) if (type < STP_MAX_CMD) dbug_trans2("Got %s. len=%d\n", _stp_command_name[type], (int)count); -- cgit