Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1584621

[PATCH RFC] net: stmmac: unify registers dumps methods

From Corentin Labbe <clabbe.montjoie@gmail.com>
Newsgroups linux.kernel
Subject [PATCH RFC] net: stmmac: unify registers dumps methods
Date 2017-02-20 14:50 +0100
Message-ID <tcWvM-5kr-5@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


hello

The following patch address the problem that two way of dumping registers are
available in stmmac, via ethtool and directly at init (if NETIF_MSG_HW is enabled).
It is better to keep only one method, ethtool, since the other was ugly (logs of pr_xxx).

But by working on this issue, I saw two problem:
- "ethtool" for gmac/gmac4 always dump the 55 first registers, while dwmac4_dump_regs dump the first 132 registers, so clearly the current stmmac_ethtool_gregs miss some registers
- stmmac_ethtool_gregs claim to dump whole address space (len=REG_SPACE_SIZE), but in fact concat two distant address space.

The current patch address all by being bijective between reg_space and address space, so all DMA registers goes to their "real" address in reg_space.
But this fix break the pretty print of registers name of ethtool. (ethtool -d eth0 hex on still works).

What do you think about this issue ?

Corentin Labbe (1):
  net: stmmac: unify registers dumps methods

 drivers/net/ethernet/stmicro/stmmac/common.h       |  4 +-
 .../net/ethernet/stmicro/stmmac/dwmac1000_core.c   | 10 +--
 .../net/ethernet/stmicro/stmmac/dwmac1000_dma.c    | 16 ++---
 .../net/ethernet/stmicro/stmmac/dwmac100_core.c    | 30 +++------
 drivers/net/ethernet/stmicro/stmmac/dwmac100_dma.c | 15 ++---
 drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c  | 12 +---
 drivers/net/ethernet/stmicro/stmmac/dwmac4_dma.c   | 78 +++++++++++-----------
 .../net/ethernet/stmicro/stmmac/stmmac_ethtool.c   | 21 +-----
 drivers/net/ethernet/stmicro/stmmac/stmmac_main.c  |  5 --
 9 files changed, 71 insertions(+), 120 deletions(-)

-- 
2.10.2

Back to linux.kernel | Previous | NextNext in thread | Find similar | Unroll thread


Thread

[PATCH RFC] net: stmmac: unify registers dumps methods Corentin Labbe <clabbe.montjoie@gmail.com> - 2017-02-20 14:50 +0100
  [PATCH RFC] net: stmmac: unify registers dumps methods Corentin Labbe <clabbe.montjoie@gmail.com> - 2017-02-20 14:50 +0100
    Re: [PATCH RFC] net: stmmac: unify registers dumps methods Giuseppe CAVALLARO <peppe.cavallaro@st.com> - 2017-02-21 10:40 +0100

csiph-web