X-Git-Url: https://git.lttng.org/?a=blobdiff_plain;f=ltt%2Fbranches%2Fpoly%2Flttv%2Fmodules%2Fgui%2Fresourceview%2Feventhooks.c;h=6c74bdbbb3c82e84b3b61a1c2256635153cfd4b5;hb=ec7a5af61127aa50a1839eee5be99ce53494c57b;hp=778ec18a5300f1a3df98cc4f09979c3efb09e7a8;hpb=a81d2a59d85b15507a64cc2e8cc53b7be4330fdc;p=lttv.git diff --git a/ltt/branches/poly/lttv/modules/gui/resourceview/eventhooks.c b/ltt/branches/poly/lttv/modules/gui/resourceview/eventhooks.c index 778ec18a..6c74bdbb 100644 --- a/ltt/branches/poly/lttv/modules/gui/resourceview/eventhooks.c +++ b/ltt/branches/poly/lttv/modules/gui/resourceview/eventhooks.c @@ -78,7 +78,7 @@ #define MAX_PATH_LEN 256 -#define STATE_LINE_WIDTH 4 +#define STATE_LINE_WIDTH 6 #define COLLISION_POSITION(height) (((height - STATE_LINE_WIDTH)/2) -3) extern GSList *g_legend_list; @@ -313,10 +313,12 @@ static void irq_set_line_color(PropertiesLine *prop_line, LttvIRQState *s) static void soft_irq_set_line_color(PropertiesLine *prop_line, LttvSoftIRQState *s) { GQuark present_state; - if(s->running == 0) - prop_line->color = drawing_colors_soft_irq[COL_SOFT_IRQ_IDLE]; - else + if(s->running) prop_line->color = drawing_colors_soft_irq[COL_SOFT_IRQ_BUSY]; + else if(s->pending) + prop_line->color = drawing_colors_soft_irq[COL_SOFT_IRQ_PENDING]; + else + prop_line->color = drawing_colors_soft_irq[COL_SOFT_IRQ_IDLE]; } static void trap_set_line_color(PropertiesLine *prop_line, LttvTrapState *s) @@ -1002,9 +1004,10 @@ int before_execmode_hook_soft_irq(void *hook_data, void *call_data) guint64 softirq; guint cpu = tfs->cpu; + guint16 ev_id_raise = marker_get_id_from_info(trace, marker_get_info_from_name(trace, lttv_merge_facility_event_name(LTT_FACILITY_KERNEL, LTT_EVENT_SOFT_IRQ_RAISE))); guint16 ev_id_entry = marker_get_id_from_info(trace, marker_get_info_from_name(trace, lttv_merge_facility_event_name(LTT_FACILITY_KERNEL, LTT_EVENT_SOFT_IRQ_ENTRY))); guint16 ev_id_exit = marker_get_id_from_info(trace, marker_get_info_from_name(trace, lttv_merge_facility_event_name(LTT_FACILITY_KERNEL, LTT_EVENT_SOFT_IRQ_EXIT))); - if(ev_id_entry == e->event_id) { + if(ev_id_entry == e->event_id || ev_id_raise == e->event_id) { softirq = ltt_event_get_long_unsigned(e, lttv_trace_get_hook_field(th, 0)); } else if(ev_id_exit == e->event_id) { @@ -2018,6 +2021,11 @@ int before_chunk(void *hook_data, void *call_data) return 0; } +/* before_request + * + * This gets executed just before an events request is executed + */ + int before_request(void *hook_data, void *call_data) { EventsRequest *events_request = (EventsRequest*)hook_data;