aboutsummaryrefslogtreecommitdiff
path: root/drivers/net
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/tc35815.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/tc35815.c b/drivers/net/tc35815.c
index 744f11f5ffb..10e4e85da3f 100644
--- a/drivers/net/tc35815.c
+++ b/drivers/net/tc35815.c
@@ -766,7 +766,8 @@ static int tc_mii_init(struct net_device *dev)
lp->mii_bus.name = "tc35815_mii_bus";
lp->mii_bus.read = tc_mdio_read;
lp->mii_bus.write = tc_mdio_write;
- lp->mii_bus.id = (lp->pci_dev->bus->number << 8) | lp->pci_dev->devfn;
+ snprintf(lp->mii_bus.id, MII_BUS_ID_SIZE, "%x",
+ (lp->pci_dev->bus->number << 8) | lp->pci_dev->devfn);
lp->mii_bus.priv = dev;
lp->mii_bus.dev = &lp->pci_dev->dev;
lp->mii_bus.irq = kmalloc(sizeof(int) * PHY_MAX_ADDR, GFP_KERNEL);