Skip to content

tools lib traceevent: Plugin unload enhancement (v2)

Namhyung Kim lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest12 patches 1 replyIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/12tools lib traceevent: Add pevent_unregister_event_handler()tools/lib/traceevent/event-parse.c tools/lib/traceevent/event-parse.h+102 -140 replies
2/12tools lib traceevent: Add pevent_unregister_print_function()tools/lib/traceevent/event-parse.c tools/lib/traceevent/event-parse.h+25 -00 replies
3/12tools lib traceevent: Unregister handler when function plugin unloadedtools/lib/traceevent/plugin_function.c+3 -00 replies
4/12tools lib traceevent: Unregister handler when hrtimer plugin unloadedtools/lib/traceevent/plugin_hrtimer.c+10 -00 replies
5/12tools lib traceevent: Unregister handler when kmem plugin unloadedtools/lib/traceevent/plugin_kmem.c+22 -00 replies
6/12tools lib traceevent: Unregister handler when kvm plugin unloadedtools/lib/traceevent/plugin_kvm.c+29 -00 replies
7/12tools lib traceevent: Unregister handler when sched_switch plugin unloadedtools/lib/traceevent/plugin_sched_switch.c+12 -00 replies
8/12tools lib traceevent: Unregister handler when mac80211 plugin unloadedtools/lib/traceevent/plugin_mac80211.c+7 -00 replies
9/12tools lib traceevent: Unregister handler when cfg80211 plugin unloadedtools/lib/traceevent/plugin_cfg80211.c+6 -01 reply
10/12tools lib traceevent: Unregister handler when jbd2 plugin unloadedtools/lib/traceevent/plugin_jbd2.c+9 -00 replies
11/12tools lib traceevent: Unregister handler when scsi plugin unloadedtools/lib/traceevent/plugin_scsi.c+6 -00 replies
12/12tools lib traceevent: Unregister handler when xen plugin unloadedtools/lib/traceevent/plugin_xen.c+6 -00 replies

Reviews trailers per patch

All 12 patches have a Reviewed-by or Acked-by.

PatchSteven RostedtJiri Olsa
1/12A-b R-b
2/12A-b R-b
3/12A-b R-b
4/12A-b R-b
5/12A-b R-b
6/12A-b R-b
7/12A-b R-b
8/12A-b R-b
9/12R-b
10/12R-b
11/12R-b
12/12R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCHSET 00/12] tools lib traceevent: Plugin unload enhancement (v2)

Hello,

When plugins are loaded, they register various event and function handlers. But they don't unregister even after the plugins unloaded so that events could have refererences to non-existing handlers.

This patchset added relevant unregister functions to handle that.

Note that this is not a problem as of now since all of users unload plugins after finishing their access to events. But being a generic library, it should be handled properly IMHO.

* changes in v2)
- add ack and review tags from Steve and Jiri
- improve message on handler unregister (Steve)
- cleanup coding style issue (Steve)

I put the series on the 'libtraceevent/plugin-v2' branch in my tree

git://git.kernel.org/pub/scm/linux/kernel/git/namhyung/linux-perf.git

Any comments are welcome, thanks
Namhyung

Namhyung Kim (12):
tools lib traceevent: Add pevent_unregister_event_handler() tools lib traceevent: Add pevent_unregister_print_function() tools lib traceevent: Unregister handler when function plugin
unloaded
tools lib traceevent: Unregister handler when hrtimer plugin unloaded tools lib traceevent: Unregister handler when kmem plugin unloaded tools lib traceevent: Unregister handler when kvm plugin unloaded tools lib traceevent: Unregister handler when sched_switch plugin
unloaded
tools lib traceevent: Unregister handler when mac80211 plugin
unloaded
tools lib traceevent: Unregister handler when cfg80211 plugin
unloaded
tools lib traceevent: Unregister handler when jbd2 plugin unloaded tools lib traceevent: Unregister handler when scsi plugin unloaded tools lib traceevent: Unregister handler when xen plugin unloaded

 tools/lib/traceevent/event-parse.c         | 136 ++++++++++++++++++++++++++---
 tools/lib/traceevent/event-parse.h         |   5 ++
 tools/lib/traceevent/plugin_cfg80211.c     |   6 ++
 tools/lib/traceevent/plugin_function.c     |   3 +
 tools/lib/traceevent/plugin_hrtimer.c      |  10 +++
 tools/lib/traceevent/plugin_jbd2.c         |   9 ++
 tools/lib/traceevent/plugin_kmem.c         |  22 +++++
 tools/lib/traceevent/plugin_kvm.c          |  29 ++++++
 tools/lib/traceevent/plugin_mac80211.c     |   7 ++
 tools/lib/traceevent/plugin_sched_switch.c |  12 +++
 tools/lib/traceevent/plugin_scsi.c         |   6 ++
 tools/lib/traceevent/plugin_xen.c          |   6 ++
 12 files changed, 237 insertions(+), 14 deletions(-)
Signature · 1 line
1.7.11.7