e1000e: Add e1000e trace module
Subsystems (2)
PATCH 1/1 e1000e: Add e1000e trace module
Add tracepoints to the driver via a new file e1000e_trace.h and some new trace calls added in interesting places in the driver. Add some tracing for s0ix flows to help in a debug of shared resources with the CSME firmware. The idea here is that tracepoints have such low performance cost when disabled that we can leave these in the upstream driver.
Performance not affected, and this can be very useful for debugging and adding new trace events to paths in the future.
Usage:
echo "e1000e_trace:*" > /sys/kernel/debug/tracing/set_event echo 1 > /sys/kernel/debug/tracing/events/e1000e_trace/enable
--- drivers/net/ethernet/intel/e1000e/Makefile | 3 ++ .../net/ethernet/intel/e1000e/e1000e_trace.h | 42 +++++++++++++++++++ drivers/net/ethernet/intel/e1000e/netdev.c | 4 ++ 3 files changed, 49 insertions(+) create mode 100644 drivers/net/ethernet/intel/e1000e/e1000e_trace.h
drivers/net/ethernet/intel/e1000e/Makefile +3 -0
@@ -5,6 +5,9 @@ # Makefile for the Intel(R) PRO/1000 ethernet driver # +ccflags-y += -I$(src) +subdir-ccflags-y += -I$(src) + obj-$(CONFIG_E1000E) += e1000e.o e1000e-objs := 82571.o ich8lan.o 80003es2lan.o \
drivers/net/ethernet/intel/e1000e/e1000e_trace.h new file +42 -0
42 lines not on this page · raw message
drivers/net/ethernet/intel/e1000e/netdev.c +4 -0
@@ -28,6 +28,8 @@#include <linux/suspend.h> #include "e1000.h" +#define CREATE_TRACE_POINTS +#include "e1000e_trace.h" char e1000e_driver_name[] ="e1000e" ;
@@ -6340,6 +6342,7 @@ static void e1000e_s0ix_entry_flow(struct e1000_adapter *adapter) mac_data =er32 (H2ME ); mac_data |=E1000_H2ME_START_DPG ; mac_data &= ~E1000_H2ME_EXIT_DPG ; +trace_e1000e_trace_mac_register (mac_data);ew32 (H2ME , mac_data); }else {/* Request driver configure the device to S0ix */
@@ -6494,6 +6497,7 @@ static void e1000e_s0ix_exit_flow(struct e1000_adapter *adapter) mac_data =er32 (H2ME ); mac_data &= ~E1000_H2ME_START_DPG ; mac_data |=E1000_H2ME_EXIT_DPG ; +trace_e1000e_trace_mac_register (mac_data);ew32 (H2ME , mac_data);/* Poll up to 2.5 seconds for ME to unconfigure DPG.
Signature · 6 lines
2.25.1 _______________________________________________ Intel-wired-lan mailing list [email protected] https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
Quoted 13 lines · Sasha Neftin
Add tracepoints to the driver via a new file
e1000e_trace.hand some new trace calls added in interesting places in the driver. Add some tracing for s0ix flows to help in a debug of shared resources with the CSME firmware. The idea here is that tracepoints have such low performance cost when disabled that we can leave these in the upstream driver.Performance not affected, and this can be very useful for debugging and adding new trace events to paths in the future.
Usage:
echo "e1000e_trace:*" >/sys/kernel/debug/tracing/set_eventecho 1 >/sys/kernel/debug/tracing/events/e1000e_trace/enable
Quoted 6 lines
Signed-off-by Sasha Neftin <[email protected]>--- drivers/net/ethernet/intel/e1000e/Makefile | 3 ++ .../net/ethernet/intel/e1000e/e1000e_trace.h | 42 +++++++++++++++++++ drivers/net/ethernet/intel/e1000e/netdev.c | 4 ++ 3 files changed, 49 insertions(+)
_______________________________________________
Intel-wired-lan mailing list
[email protected]
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan