@@ -9,7 +9,7 @@ ethtool_SOURCES = ethtool.c ethtool-copy.h internal.h net_tstamp-copy.h \
rxclass.c
if ETHTOOL_ENABLE_PRETTY_DUMP
ethtool_SOURCES += \
- amd8111e.c de2104x.c e100.c e1000.c et131x.c igb.c \
+ amd8111e.c de2104x.c dsa.c e100.c e1000.c et131x.c igb.c \
fec_8xx.c ibm_emac.c ixgb.c ixgbe.c natsemi.c \
pcnet32.c realtek.c tg3.c marvell.c vioc.c \
smsc911x.c at76c50x-usb.c sfc.c stmmac.c \
new file mode 100644
@@ -0,0 +1,12 @@
+#include <stdio.h>
+#include <string.h>
+
+#include "internal.h"
+
+int dsa_dump_regs(struct ethtool_drvinfo *info, struct ethtool_regs *regs)
+{
+ /* DSA per-driver register dump */
+
+ /* Fallback to hexdump */
+ return 1;
+}
@@ -1166,6 +1166,7 @@ static const struct {
{ "vmxnet3", vmxnet3_dump_regs },
{ "fjes", fjes_dump_regs },
{ "lan78xx", lan78xx_dump_regs },
+ { "dsa", dsa_dump_regs },
#endif
};
@@ -354,4 +354,7 @@ int fjes_dump_regs(struct ethtool_drvinfo *info, struct ethtool_regs *regs);
/* MICROCHIP LAN78XX USB ETHERNET Controller */
int lan78xx_dump_regs(struct ethtool_drvinfo *info, struct ethtool_regs *regs);
+/* Distributed Switch Architecture */
+int dsa_dump_regs(struct ethtool_drvinfo *info, struct ethtool_regs *regs);
+
#endif /* ETHTOOL_INTERNAL_H__ */
This patch adds the preliminary bits for pretty dumping the registers of the "dsa" kernel drivers. Following patches will add support for the "mv88e6xxx" DSA driver. Signed-off-by: Vivien Didelot <vivien.didelot@gmail.com> --- Makefile.am | 2 +- dsa.c | 12 ++++++++++++ ethtool.c | 1 + internal.h | 3 +++ 4 files changed, 17 insertions(+), 1 deletion(-) create mode 100644 dsa.c