Open netedwardwu opened 4 years ago
Yes, the reason is due to the following definition:
#define TRACEPOINT_PROBE(category, event) \
int tracepoint__##category##__##event(struct tracepoint__##category##__##event *args)
The workaround is to define the function prototype explicitly like
struct tracepoit__xhci_urb_enqueue { ...}
int tracepoint__xhci_urb_enqueue(struct tracepoit__xhci_urb_enqueue *args) { ...}
The function name and struct name can be different from the above.
The name has -
is quite rare, it would be good to get it fixed. But probably not urgent.
Source code
Result
Ubuntu 18.04
Kernel version
This issue happens when the name of the event has "-" symbol. attach_tracepoint() is workable on this case.
Thank you