Skip to contentSkip to conversation

net: stmmac: Add additional registers for dwmac1000_dma ethtool

PATCH Applied [email protected] 3 participants 3 messages Jun 27, 2017 – Jun 29, 2017

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 net: stmmac: Add additional registers for dwmac1000_dma ethtool

From: Thor Thayer <[email protected]>

Version 3.70a of the Designware has additional DMA registers so add those to the ethtool DMA Register dump.
Offset 9 - Receive Interrupt Watchdog Timer Register Offset 10 - AXI Bus Mode Register
Offset 11 - AHB or AXI Status Register
Offset 22 - HW Feature Register

---
 drivers/net/ethernet/stmicro/stmmac/dwmac1000_dma.c  | 4 ++--
 drivers/net/ethernet/stmicro/stmmac/stmmac_ethtool.c | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
drivers/net/ethernet/stmicro/stmmac/dwmac1000_dma.c +2 -2
index 471a9aa..22cf635 100644
@@ -205,8 +205,8 @@ static void dwmac1000_dump_dma_regs(void __iomem *ioaddr, u32 *reg_space)
 {
 	int i;
 
-	for (i = 0; i < 22; i++)
-		if ((i < 9) || (i > 17))
+	for (i = 0; i < 23; i++)
+		if ((i < 12) || (i > 17))
 			reg_space[DMA_BUS_MODE / 4 + i] =
 				readl(ioaddr + DMA_BUS_MODE + i * 4);
 }
drivers/net/ethernet/stmicro/stmmac/stmmac_ethtool.c +1 -1
index 743170d..babb39c 100644
@@ -29,7 +29,7 @@
 #include "stmmac.h"
 #include "dwmac_dma.h"
 
-#define REG_SPACE_SIZE	0x1054
+#define REG_SPACE_SIZE	0x1060
 #define MAC100_ETHTOOL_NAME	"st_mac100"
 #define GMAC_ETHTOOL_NAME	"st_gmac"
 
Signature · 1 line
2.7.4
Acked-by on v1 1/1
#1 lore raw
Quoted 10 lines · On 6/28/2017 12:16 AM, [email protected] wrote:

From: Thor Thayer <[email protected]>

Version 3.70a of the Designware has additional DMA registers so add those to the ethtool DMA Register dump.
Offset 9 - Receive Interrupt Watchdog Timer Register Offset 10 - AXI Bus Mode Register
Offset 11 - AHB or AXI Status Register
Offset 22 - HW Feature Register

Quoted 33 lines
---
  drivers/net/ethernet/stmicro/stmmac/dwmac1000_dma.c  | 4 ++--
  drivers/net/ethernet/stmicro/stmmac/stmmac_ethtool.c | 2 +-
  2 files changed, 3 insertions(+), 3 deletions(-)
drivers/net/ethernet/stmicro/stmmac/dwmac1000_dma.c +2 -2
index 471a9aa..22cf635 100644
@@ -205,8 +205,8 @@ static void dwmac1000_dump_dma_regs(void __iomem *ioaddr, u32 *reg_space)
  {
  	int i;
 
-	for (i = 0; i < 22; i++)
-		if ((i < 9) || (i > 17))
+	for (i = 0; i < 23; i++)
+		if ((i < 12) || (i > 17))
  			reg_space[DMA_BUS_MODE / 4 + i] =
  				readl(ioaddr + DMA_BUS_MODE + i * 4);
  }
drivers/net/ethernet/stmicro/stmmac/stmmac_ethtool.c +1 -1
index 743170d..babb39c 100644
@@ -29,7 +29,7 @@
  #include "stmmac.h"
  #include "dwmac_dma.h"
 
-#define REG_SPACE_SIZE	0x1054
+#define REG_SPACE_SIZE	0x1060
  #define MAC100_ETHTOOL_NAME	"st_mac100"
  #define GMAC_ETHTOOL_NAME	"st_gmac"
 
maintainer Applied
#2 lore raw
In reply to [email protected]

From: [email protected]
Date: Tue, 27 Jun 2017 17:16:27 -0500

Quoted 10 lines

From: Thor Thayer <[email protected]>

Version 3.70a of the Designware has additional DMA registers so add those to the ethtool DMA Register dump.
Offset 9 - Receive Interrupt Watchdog Timer Register Offset 10 - AXI Bus Mode Register
Offset 11 - AHB or AXI Status Register
Offset 22 - HW Feature Register

Applied to net-next, thanks.