[PATCH 3/3] usb: dwc3: remove base parameter of event class dwc3_log_io

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



when trace register read/write operation, it is not necessary to show
virtual address cacaulate from base and offset.

remove the base register value, it will save trace buffer.
it is enough only save and show the offset.

Signed-off-by: Linyu Yuan <quic_linyyuan@xxxxxxxxxxx>
---
 drivers/usb/dwc3/io.h    |  4 ++--
 drivers/usb/dwc3/trace.h | 17 +++++++----------
 2 files changed, 9 insertions(+), 12 deletions(-)

diff --git a/drivers/usb/dwc3/io.h b/drivers/usb/dwc3/io.h
index d24513e..fcb5726 100644
--- a/drivers/usb/dwc3/io.h
+++ b/drivers/usb/dwc3/io.h
@@ -32,7 +32,7 @@ static inline u32 dwc3_readl(void __iomem *base, u32 offset)
 	 * documentation, so we revert it back to the proper addresses, the
 	 * same way they are described on SNPS documentation
 	 */
-	trace_dwc3_readl(base, offset, value);
+	trace_dwc3_readl(offset, value);
 
 	return value;
 }
@@ -61,7 +61,7 @@ static inline void dwc3_writel(void __iomem *base, u32 offset, u32 value)
 	 * documentation, so we revert it back to the proper addresses, the
 	 * same way they are described on SNPS documentation
 	 */
-	trace_dwc3_writel(base, offset, value);
+	trace_dwc3_writel(offset, value);
 }
 
 #endif /* __DRIVERS_USB_DWC3_IO_H */
diff --git a/drivers/usb/dwc3/trace.h b/drivers/usb/dwc3/trace.h
index 1975aec..536b9a1 100644
--- a/drivers/usb/dwc3/trace.h
+++ b/drivers/usb/dwc3/trace.h
@@ -20,32 +20,29 @@
 #include "debug.h"
 
 DECLARE_EVENT_CLASS(dwc3_log_io,
-	TP_PROTO(void *base, u32 offset, u32 value),
-	TP_ARGS(base, offset, value),
+	TP_PROTO(u32 offset, u32 value),
+	TP_ARGS(offset, value),
 	TP_STRUCT__entry(
-		__field(void *, base)
 		__field(u32, offset)
 		__field(u32, value)
 	),
 	TP_fast_assign(
-		__entry->base = base;
 		__entry->offset = offset;
 		__entry->value = value;
 	),
-	TP_printk("addr %p offset %04x value %08x",
-		__entry->base + __entry->offset,
+	TP_printk("offset %04x value %08x",
 		__entry->offset,
 		__entry->value)
 );
 
 DEFINE_EVENT(dwc3_log_io, dwc3_readl,
-	TP_PROTO(void __iomem *base, u32 offset, u32 value),
-	TP_ARGS(base, offset, value)
+	TP_PROTO(u32 offset, u32 value),
+	TP_ARGS(offset, value)
 );
 
 DEFINE_EVENT(dwc3_log_io, dwc3_writel,
-	TP_PROTO(void __iomem *base, u32 offset, u32 value),
-	TP_ARGS(base, offset, value)
+	TP_PROTO(u32 offset, u32 value),
+	TP_ARGS(offset, value)
 );
 
 DECLARE_EVENT_CLASS(dwc3_log_event,
-- 
2.7.4




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux