aboutsummaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorGravatar Niklas Cassel <niklas.cassel@axis.com> 2017-05-15 10:56:06 +0200
committerGravatar David S. Miller <davem@davemloft.net> 2017-05-15 10:02:19 -0400
commit66c25f6e31766a9ec19c2bdc7f5f69f9c59bafd7 (patch)
treed89deb6f2febf271a07513a19e5533d0100cdde6 /drivers
parentvmxnet3: ensure that adapter is in proper state during force_close (diff)
downloadlinux-66c25f6e31766a9ec19c2bdc7f5f69f9c59bafd7.tar.gz
linux-66c25f6e31766a9ec19c2bdc7f5f69f9c59bafd7.tar.bz2
linux-66c25f6e31766a9ec19c2bdc7f5f69f9c59bafd7.zip
net: stmmac: use correct pointer when printing normal descriptor ring
There are two pointers in sysfs_display_ring, one that increments if using normal dma descriptors, another if using extended dma descriptors. When printing the normal dma descriptors, the wrong pointer is used, thus the printed descriptor addresses are incorrect. Signed-off-by: Niklas Cassel <niklas.cassel@axis.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/ethernet/stmicro/stmmac/stmmac_main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
index cd8c60132390..a74c481401c4 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
@@ -3725,7 +3725,7 @@ static void sysfs_display_ring(void *head, int size, int extend_desc,
ep++;
} else {
seq_printf(seq, "%d [0x%x]: 0x%x 0x%x 0x%x 0x%x\n",
- i, (unsigned int)virt_to_phys(ep),
+ i, (unsigned int)virt_to_phys(p),
le32_to_cpu(p->des0), le32_to_cpu(p->des1),
le32_to_cpu(p->des2), le32_to_cpu(p->des3));
p++;