summaryrefslogtreecommitdiff
path: root/drivers/net/phy/mdio-thunder.c
diff options
context:
space:
mode:
authorAndrew Lunn <andrew@lunn.ch>2020-07-07 03:49:38 +0200
committerDavid S. Miller <davem@davemloft.net>2020-07-07 12:47:11 -0700
commitc7b04d1030f505f2d883612ed31a6ddd70182705 (patch)
treebdcfa226199a1b00f75300a4ba2458353446277a /drivers/net/phy/mdio-thunder.c
parent82e7627fd4d8592be2acb908943fb943c440840d (diff)
net: phy: cavium: Improve __iomem mess
The MIPS low level register access functions seem to be missing __iomem annotation. This causes lots of sparse warnings, when code casts off the __iomem. Make the Cavium MDIO drivers cleaner by pushing the casts lower down into the helpers, allow the drivers to work as normal, with __iomem. bus->register_base is now an void *, rather than a u64. So forming the mii_bus->id string cannot use %llx any more. Use %px, so this kernel address is still exposed to user space, as it was before. v2: s/cases/causes/g Cc: Sunil Goutham <sgoutham@marvell.com> Cc: Robert Richter <rrichter@marvell.com> Reviewed-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/phy/mdio-thunder.c')
-rw-r--r--drivers/net/phy/mdio-thunder.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/phy/mdio-thunder.c b/drivers/net/phy/mdio-thunder.c
index 2a97938d1972..3d7eda99d34e 100644
--- a/drivers/net/phy/mdio-thunder.c
+++ b/drivers/net/phy/mdio-thunder.c
@@ -84,7 +84,7 @@ static int thunder_mdiobus_pci_probe(struct pci_dev *pdev,
nexus->buses[i] = bus;
i++;
- bus->register_base = (u64)nexus->bar0 +
+ bus->register_base = nexus->bar0 +
r.start - pci_resource_start(pdev, 0);
smi_en.u64 = 0;