napi.h 780 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. #undef TRACE_SYSTEM
  2. #define TRACE_SYSTEM napi
  3. #if !defined(_TRACE_NAPI_H) || defined(TRACE_HEADER_MULTI_READ)
  4. #define _TRACE_NAPI_H_
  5. #include <linux/netdevice.h>
  6. #include <linux/tracepoint.h>
  7. #include <linux/ftrace.h>
  8. #define NO_DEV "(no_device)"
  9. TRACE_EVENT(napi_poll,
  10. TP_PROTO(struct napi_struct *napi),
  11. TP_ARGS(napi),
  12. TP_STRUCT__entry(
  13. __field( struct napi_struct *, napi)
  14. __string( dev_name, napi->dev ? napi->dev->name : NO_DEV)
  15. ),
  16. TP_fast_assign(
  17. __entry->napi = napi;
  18. __assign_str(dev_name, napi->dev ? napi->dev->name : NO_DEV);
  19. ),
  20. TP_printk("napi poll on napi struct %p for device %s",
  21. __entry->napi, __get_str(dev_name))
  22. );
  23. #undef NO_DEV
  24. #endif /* _TRACE_NAPI_H_ */
  25. /* This part must be outside protection */
  26. #include <trace/define_trace.h>