Commit c2313557 authored by Kay Sievers's avatar Kay Sievers Committed by Greg Kroah-Hartman

net: struct device - replace bus_id with dev_name(), dev_set_name()

Cc: davem@davemloft.net
Cc: netdev@vger.kernel.org
Acked-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: default avatarKay Sievers <kay.sievers@vrfy.org>
parent 744bcb13
...@@ -1059,7 +1059,7 @@ ks8695_get_drvinfo(struct net_device *ndev, struct ethtool_drvinfo *info) ...@@ -1059,7 +1059,7 @@ ks8695_get_drvinfo(struct net_device *ndev, struct ethtool_drvinfo *info)
{ {
strlcpy(info->driver, MODULENAME, sizeof(info->driver)); strlcpy(info->driver, MODULENAME, sizeof(info->driver));
strlcpy(info->version, MODULEVERSION, sizeof(info->version)); strlcpy(info->version, MODULEVERSION, sizeof(info->version));
strlcpy(info->bus_info, ndev->dev.parent->bus_id, strlcpy(info->bus_info, dev_name(ndev->dev.parent),
sizeof(info->bus_info)); sizeof(info->bus_info));
} }
......
...@@ -355,8 +355,8 @@ static int mii_probe (struct net_device *dev) ...@@ -355,8 +355,8 @@ static int mii_probe (struct net_device *dev)
/* now we are supposed to have a proper phydev, to attach to... */ /* now we are supposed to have a proper phydev, to attach to... */
BUG_ON(phydev->attached_dev); BUG_ON(phydev->attached_dev);
phydev = phy_connect(dev, phydev->dev.bus_id, &au1000_adjust_link, 0, phydev = phy_connect(dev, dev_name(&phydev->dev), &au1000_adjust_link,
PHY_INTERFACE_MODE_MII); 0, PHY_INTERFACE_MODE_MII);
if (IS_ERR(phydev)) { if (IS_ERR(phydev)) {
printk(KERN_ERR "%s: Could not attach to PHY\n", dev->name); printk(KERN_ERR "%s: Could not attach to PHY\n", dev->name);
...@@ -381,8 +381,8 @@ static int mii_probe (struct net_device *dev) ...@@ -381,8 +381,8 @@ static int mii_probe (struct net_device *dev)
aup->phy_dev = phydev; aup->phy_dev = phydev;
printk(KERN_INFO "%s: attached PHY driver [%s] " printk(KERN_INFO "%s: attached PHY driver [%s] "
"(mii_bus:phy_addr=%s, irq=%d)\n", "(mii_bus:phy_addr=%s, irq=%d)\n", dev->name,
dev->name, phydev->drv->name, phydev->dev.bus_id, phydev->irq); phydev->drv->name, dev_name(&phydev->dev), phydev->irq);
return 0; return 0;
} }
......
...@@ -415,11 +415,11 @@ static int mii_probe(struct net_device *dev) ...@@ -415,11 +415,11 @@ static int mii_probe(struct net_device *dev)
} }
#if defined(CONFIG_BFIN_MAC_RMII) #if defined(CONFIG_BFIN_MAC_RMII)
phydev = phy_connect(dev, phydev->dev.bus_id, &bfin_mac_adjust_link, 0, phydev = phy_connect(dev, dev_name(&phydev->dev), &bfin_mac_adjust_link,
PHY_INTERFACE_MODE_RMII); 0, PHY_INTERFACE_MODE_RMII);
#else #else
phydev = phy_connect(dev, phydev->dev.bus_id, &bfin_mac_adjust_link, 0, phydev = phy_connect(dev, dev_name(&phydev->dev), &bfin_mac_adjust_link,
PHY_INTERFACE_MODE_MII); 0, PHY_INTERFACE_MODE_MII);
#endif #endif
if (IS_ERR(phydev)) { if (IS_ERR(phydev)) {
...@@ -447,7 +447,7 @@ static int mii_probe(struct net_device *dev) ...@@ -447,7 +447,7 @@ static int mii_probe(struct net_device *dev)
printk(KERN_INFO "%s: attached PHY driver [%s] " printk(KERN_INFO "%s: attached PHY driver [%s] "
"(mii_bus:phy_addr=%s, irq=%d, mdc_clk=%dHz(mdc_div=%d)" "(mii_bus:phy_addr=%s, irq=%d, mdc_clk=%dHz(mdc_div=%d)"
"@sclk=%dMHz)\n", "@sclk=%dMHz)\n",
DRV_NAME, phydev->drv->name, phydev->dev.bus_id, phydev->irq, DRV_NAME, phydev->drv->name, dev_name(&phydev->dev), phydev->irq,
MDC_CLK, mdc_div, sclk/1000000); MDC_CLK, mdc_div, sclk/1000000);
return 0; return 0;
...@@ -488,7 +488,7 @@ static void bfin_mac_ethtool_getdrvinfo(struct net_device *dev, ...@@ -488,7 +488,7 @@ static void bfin_mac_ethtool_getdrvinfo(struct net_device *dev,
strcpy(info->driver, DRV_NAME); strcpy(info->driver, DRV_NAME);
strcpy(info->version, DRV_VERSION); strcpy(info->version, DRV_VERSION);
strcpy(info->fw_version, "N/A"); strcpy(info->fw_version, "N/A");
strcpy(info->bus_info, dev->dev.bus_id); strcpy(info->bus_info, dev_name(&dev->dev));
} }
static struct ethtool_ops bfin_mac_ethtool_ops = { static struct ethtool_ops bfin_mac_ethtool_ops = {
......
...@@ -1240,7 +1240,7 @@ static void bmac_get_drvinfo(struct net_device *dev, struct ethtool_drvinfo *inf ...@@ -1240,7 +1240,7 @@ static void bmac_get_drvinfo(struct net_device *dev, struct ethtool_drvinfo *inf
{ {
struct bmac_data *bp = netdev_priv(dev); struct bmac_data *bp = netdev_priv(dev);
strcpy(info->driver, "bmac"); strcpy(info->driver, "bmac");
strcpy(info->bus_info, bp->mdev->ofdev.dev.bus_id); strcpy(info->bus_info, dev_name(&bp->mdev->ofdev.dev));
} }
static const struct ethtool_ops bmac_ethtool_ops = { static const struct ethtool_ops bmac_ethtool_ops = {
......
...@@ -1161,7 +1161,7 @@ static int __devinit cpmac_probe(struct platform_device *pdev) ...@@ -1161,7 +1161,7 @@ static int __devinit cpmac_probe(struct platform_device *pdev)
priv->msg_enable = netif_msg_init(debug_level, 0xff); priv->msg_enable = netif_msg_init(debug_level, 0xff);
memcpy(dev->dev_addr, pdata->dev_addr, sizeof(dev->dev_addr)); memcpy(dev->dev_addr, pdata->dev_addr, sizeof(dev->dev_addr));
priv->phy = phy_connect(dev, cpmac_mii->phy_map[phy_id]->dev.bus_id, priv->phy = phy_connect(dev, dev_name(&cpmac_mii->phy_map[phy_id]->dev),
&cpmac_adjust_link, 0, PHY_INTERFACE_MODE_MII); &cpmac_adjust_link, 0, PHY_INTERFACE_MODE_MII);
if (IS_ERR(priv->phy)) { if (IS_ERR(priv->phy)) {
if (netif_msg_drv(priv)) if (netif_msg_drv(priv))
......
...@@ -1027,7 +1027,7 @@ static int __init dec_lance_probe(struct device *bdev, const int type) ...@@ -1027,7 +1027,7 @@ static int __init dec_lance_probe(struct device *bdev, const int type)
printk(version); printk(version);
if (bdev) if (bdev)
snprintf(name, sizeof(name), "%s", bdev->bus_id); snprintf(name, sizeof(name), "%s", dev_name(bdev));
else { else {
i = 0; i = 0;
dev = root_lance_dev; dev = root_lance_dev;
...@@ -1105,10 +1105,10 @@ static int __init dec_lance_probe(struct device *bdev, const int type) ...@@ -1105,10 +1105,10 @@ static int __init dec_lance_probe(struct device *bdev, const int type)
start = to_tc_dev(bdev)->resource.start; start = to_tc_dev(bdev)->resource.start;
len = to_tc_dev(bdev)->resource.end - start + 1; len = to_tc_dev(bdev)->resource.end - start + 1;
if (!request_mem_region(start, len, bdev->bus_id)) { if (!request_mem_region(start, len, dev_name(bdev))) {
printk(KERN_ERR printk(KERN_ERR
"%s: Unable to reserve MMIO resource\n", "%s: Unable to reserve MMIO resource\n",
bdev->bus_id); dev_name(bdev));
ret = -EBUSY; ret = -EBUSY;
goto err_out_dev; goto err_out_dev;
} }
......
...@@ -606,8 +606,8 @@ static int __init depca_hw_init (struct net_device *dev, struct device *device) ...@@ -606,8 +606,8 @@ static int __init depca_hw_init (struct net_device *dev, struct device *device)
if (!mem_start || lp->adapter < DEPCA || lp->adapter >=unknown) if (!mem_start || lp->adapter < DEPCA || lp->adapter >=unknown)
return -ENXIO; return -ENXIO;
printk ("%s: %s at 0x%04lx", printk("%s: %s at 0x%04lx",
device->bus_id, depca_signature[lp->adapter], ioaddr); dev_name(device), depca_signature[lp->adapter], ioaddr);
switch (lp->depca_bus) { switch (lp->depca_bus) {
#ifdef CONFIG_MCA #ifdef CONFIG_MCA
...@@ -669,7 +669,7 @@ static int __init depca_hw_init (struct net_device *dev, struct device *device) ...@@ -669,7 +669,7 @@ static int __init depca_hw_init (struct net_device *dev, struct device *device)
spin_lock_init(&lp->lock); spin_lock_init(&lp->lock);
sprintf(lp->adapter_name, "%s (%s)", sprintf(lp->adapter_name, "%s (%s)",
depca_signature[lp->adapter], device->bus_id); depca_signature[lp->adapter], dev_name(device));
status = -EBUSY; status = -EBUSY;
/* Initialisation Block */ /* Initialisation Block */
......
...@@ -3040,7 +3040,7 @@ static struct device *ehea_register_port(struct ehea_port *port, ...@@ -3040,7 +3040,7 @@ static struct device *ehea_register_port(struct ehea_port *port,
port->ofdev.dev.parent = &port->adapter->ofdev->dev; port->ofdev.dev.parent = &port->adapter->ofdev->dev;
port->ofdev.dev.bus = &ibmebus_bus_type; port->ofdev.dev.bus = &ibmebus_bus_type;
sprintf(port->ofdev.dev.bus_id, "port%d", port_name_cnt++); dev_set_name(&port->ofdev.dev, "port%d", port_name_cnt++);
port->ofdev.dev.release = logical_port_release; port->ofdev.dev.release = logical_port_release;
ret = of_device_register(&port->ofdev); ret = of_device_register(&port->ofdev);
......
...@@ -131,7 +131,8 @@ static int __init sonic_probe1(struct net_device *dev) ...@@ -131,7 +131,8 @@ static int __init sonic_probe1(struct net_device *dev)
if (sonic_debug && version_printed++ == 0) if (sonic_debug && version_printed++ == 0)
printk(version); printk(version);
printk(KERN_INFO "%s: Sonic ethernet found at 0x%08lx, ", lp->device->bus_id, dev->base_addr); printk(KERN_INFO "%s: Sonic ethernet found at 0x%08lx, ",
dev_name(lp->device), dev->base_addr);
/* /*
* Put the sonic into software reset, then * Put the sonic into software reset, then
...@@ -156,7 +157,8 @@ static int __init sonic_probe1(struct net_device *dev) ...@@ -156,7 +157,8 @@ static int __init sonic_probe1(struct net_device *dev)
if ((lp->descriptors = dma_alloc_coherent(lp->device, if ((lp->descriptors = dma_alloc_coherent(lp->device,
SIZEOF_SONIC_DESC * SONIC_BUS_SCALE(lp->dma_bitmode), SIZEOF_SONIC_DESC * SONIC_BUS_SCALE(lp->dma_bitmode),
&lp->descriptors_laddr, GFP_KERNEL)) == NULL) { &lp->descriptors_laddr, GFP_KERNEL)) == NULL) {
printk(KERN_ERR "%s: couldn't alloc DMA memory for descriptors.\n", lp->device->bus_id); printk(KERN_ERR "%s: couldn't alloc DMA memory for descriptors.\n",
dev_name(lp->device));
goto out; goto out;
} }
......
...@@ -211,10 +211,10 @@ static int macb_mii_probe(struct net_device *dev) ...@@ -211,10 +211,10 @@ static int macb_mii_probe(struct net_device *dev)
/* attach the mac to the phy */ /* attach the mac to the phy */
if (pdata && pdata->is_rmii) { if (pdata && pdata->is_rmii) {
phydev = phy_connect(dev, phydev->dev.bus_id, phydev = phy_connect(dev, dev_name(&phydev->dev),
&macb_handle_link_change, 0, PHY_INTERFACE_MODE_RMII); &macb_handle_link_change, 0, PHY_INTERFACE_MODE_RMII);
} else { } else {
phydev = phy_connect(dev, phydev->dev.bus_id, phydev = phy_connect(dev, dev_name(&phydev->dev),
&macb_handle_link_change, 0, PHY_INTERFACE_MODE_MII); &macb_handle_link_change, 0, PHY_INTERFACE_MODE_MII);
} }
...@@ -1077,7 +1077,7 @@ static void macb_get_drvinfo(struct net_device *dev, ...@@ -1077,7 +1077,7 @@ static void macb_get_drvinfo(struct net_device *dev,
strcpy(info->driver, bp->pdev->dev.driver->name); strcpy(info->driver, bp->pdev->dev.driver->name);
strcpy(info->version, "$Revision: 1.14 $"); strcpy(info->version, "$Revision: 1.14 $");
strcpy(info->bus_info, bp->pdev->dev.bus_id); strcpy(info->bus_info, dev_name(&bp->pdev->dev));
} }
static struct ethtool_ops macb_ethtool_ops = { static struct ethtool_ops macb_ethtool_ops = {
...@@ -1234,8 +1234,8 @@ static int __init macb_probe(struct platform_device *pdev) ...@@ -1234,8 +1234,8 @@ static int __init macb_probe(struct platform_device *pdev)
phydev = bp->phy_dev; phydev = bp->phy_dev;
printk(KERN_INFO "%s: attached PHY driver [%s] " printk(KERN_INFO "%s: attached PHY driver [%s] "
"(mii_bus:phy_addr=%s, irq=%d)\n", "(mii_bus:phy_addr=%s, irq=%d)\n", dev->name,
dev->name, phydev->drv->name, phydev->dev.bus_id, phydev->irq); phydev->drv->name, dev_name(&phydev->dev), phydev->irq);
return 0; return 0;
......
...@@ -176,7 +176,8 @@ static int __init macsonic_init(struct net_device *dev) ...@@ -176,7 +176,8 @@ static int __init macsonic_init(struct net_device *dev)
if ((lp->descriptors = dma_alloc_coherent(lp->device, if ((lp->descriptors = dma_alloc_coherent(lp->device,
SIZEOF_SONIC_DESC * SONIC_BUS_SCALE(lp->dma_bitmode), SIZEOF_SONIC_DESC * SONIC_BUS_SCALE(lp->dma_bitmode),
&lp->descriptors_laddr, GFP_KERNEL)) == NULL) { &lp->descriptors_laddr, GFP_KERNEL)) == NULL) {
printk(KERN_ERR "%s: couldn't alloc DMA memory for descriptors.\n", lp->device->bus_id); printk(KERN_ERR "%s: couldn't alloc DMA memory for descriptors.\n",
dev_name(lp->device));
return -ENOMEM; return -ENOMEM;
} }
...@@ -337,7 +338,7 @@ static int __init mac_onboard_sonic_probe(struct net_device *dev) ...@@ -337,7 +338,7 @@ static int __init mac_onboard_sonic_probe(struct net_device *dev)
sonic_version_printed = 1; sonic_version_printed = 1;
} }
printk(KERN_INFO "%s: onboard / comm-slot SONIC at 0x%08lx\n", printk(KERN_INFO "%s: onboard / comm-slot SONIC at 0x%08lx\n",
lp->device->bus_id, dev->base_addr); dev_name(lp->device), dev->base_addr);
/* The PowerBook's SONIC is 16 bit always. */ /* The PowerBook's SONIC is 16 bit always. */
if (macintosh_config->ident == MAC_MODEL_PB520) { if (macintosh_config->ident == MAC_MODEL_PB520) {
...@@ -370,10 +371,10 @@ static int __init mac_onboard_sonic_probe(struct net_device *dev) ...@@ -370,10 +371,10 @@ static int __init mac_onboard_sonic_probe(struct net_device *dev)
} }
printk(KERN_INFO printk(KERN_INFO
"%s: revision 0x%04x, using %d bit DMA and register offset %d\n", "%s: revision 0x%04x, using %d bit DMA and register offset %d\n",
lp->device->bus_id, sr, lp->dma_bitmode?32:16, lp->reg_offset); dev_name(lp->device), sr, lp->dma_bitmode?32:16, lp->reg_offset);
#if 0 /* This is sometimes useful to find out how MacOS configured the card. */ #if 0 /* This is sometimes useful to find out how MacOS configured the card. */
printk(KERN_INFO "%s: DCR: 0x%04x, DCR2: 0x%04x\n", lp->device->bus_id, printk(KERN_INFO "%s: DCR: 0x%04x, DCR2: 0x%04x\n", dev_name(lp->device),
SONIC_READ(SONIC_DCR) & 0xffff, SONIC_READ(SONIC_DCR2) & 0xffff); SONIC_READ(SONIC_DCR) & 0xffff, SONIC_READ(SONIC_DCR2) & 0xffff);
#endif #endif
...@@ -525,12 +526,12 @@ static int __init mac_nubus_sonic_probe(struct net_device *dev) ...@@ -525,12 +526,12 @@ static int __init mac_nubus_sonic_probe(struct net_device *dev)
sonic_version_printed = 1; sonic_version_printed = 1;
} }
printk(KERN_INFO "%s: %s in slot %X\n", printk(KERN_INFO "%s: %s in slot %X\n",
lp->device->bus_id, ndev->board->name, ndev->board->slot); dev_name(lp->device), ndev->board->name, ndev->board->slot);
printk(KERN_INFO "%s: revision 0x%04x, using %d bit DMA and register offset %d\n", printk(KERN_INFO "%s: revision 0x%04x, using %d bit DMA and register offset %d\n",
lp->device->bus_id, SONIC_READ(SONIC_SR), dma_bitmode?32:16, reg_offset); dev_name(lp->device), SONIC_READ(SONIC_SR), dma_bitmode?32:16, reg_offset);
#if 0 /* This is sometimes useful to find out how MacOS configured the card. */ #if 0 /* This is sometimes useful to find out how MacOS configured the card. */
printk(KERN_INFO "%s: DCR: 0x%04x, DCR2: 0x%04x\n", lp->device->bus_id, printk(KERN_INFO "%s: DCR: 0x%04x, DCR2: 0x%04x\n", dev_name(lp->device),
SONIC_READ(SONIC_DCR) & 0xffff, SONIC_READ(SONIC_DCR2) & 0xffff); SONIC_READ(SONIC_DCR) & 0xffff, SONIC_READ(SONIC_DCR2) & 0xffff);
#endif #endif
......
...@@ -2588,7 +2588,7 @@ static void phy_init(struct mv643xx_eth_private *mp, int speed, int duplex) ...@@ -2588,7 +2588,7 @@ static void phy_init(struct mv643xx_eth_private *mp, int speed, int duplex)
phy_reset(mp); phy_reset(mp);
phy_attach(mp->dev, phy->dev.bus_id, 0, PHY_INTERFACE_MODE_GMII); phy_attach(mp->dev, dev_name(&phy->dev), 0, PHY_INTERFACE_MODE_GMII);
if (speed == 0) { if (speed == 0) {
phy->autoneg = AUTONEG_ENABLE; phy->autoneg = AUTONEG_ENABLE;
......
...@@ -2478,7 +2478,7 @@ static int sbmac_mii_probe(struct net_device *dev) ...@@ -2478,7 +2478,7 @@ static int sbmac_mii_probe(struct net_device *dev)
return -ENXIO; return -ENXIO;
} }
phy_dev = phy_connect(dev, phy_dev->dev.bus_id, &sbmac_mii_poll, 0, phy_dev = phy_connect(dev, dev_name(&phy_dev->dev), &sbmac_mii_poll, 0,
PHY_INTERFACE_MODE_GMII); PHY_INTERFACE_MODE_GMII);
if (IS_ERR(phy_dev)) { if (IS_ERR(phy_dev)) {
printk(KERN_ERR "%s: could not attach to PHY\n", dev->name); printk(KERN_ERR "%s: could not attach to PHY\n", dev->name);
...@@ -2500,7 +2500,7 @@ static int sbmac_mii_probe(struct net_device *dev) ...@@ -2500,7 +2500,7 @@ static int sbmac_mii_probe(struct net_device *dev)
pr_info("%s: attached PHY driver [%s] (mii_bus:phy_addr=%s, irq=%d)\n", pr_info("%s: attached PHY driver [%s] (mii_bus:phy_addr=%s, irq=%d)\n",
dev->name, phy_dev->drv->name, dev->name, phy_dev->drv->name,
phy_dev->dev.bus_id, phy_dev->irq); dev_name(&phy_dev->dev), phy_dev->irq);
sc->phy_dev = phy_dev; sc->phy_dev = phy_dev;
...@@ -2697,7 +2697,7 @@ static int __init sbmac_probe(struct platform_device *pldev) ...@@ -2697,7 +2697,7 @@ static int __init sbmac_probe(struct platform_device *pldev)
sbm_base = ioremap_nocache(res->start, res->end - res->start + 1); sbm_base = ioremap_nocache(res->start, res->end - res->start + 1);
if (!sbm_base) { if (!sbm_base) {
printk(KERN_ERR "%s: unable to map device registers\n", printk(KERN_ERR "%s: unable to map device registers\n",
pldev->dev.bus_id); dev_name(&pldev->dev));
err = -ENOMEM; err = -ENOMEM;
goto out_out; goto out_out;
} }
...@@ -2708,7 +2708,7 @@ static int __init sbmac_probe(struct platform_device *pldev) ...@@ -2708,7 +2708,7 @@ static int __init sbmac_probe(struct platform_device *pldev)
* If we find a zero, skip this MAC. * If we find a zero, skip this MAC.
*/ */
sbmac_orig_hwaddr = __raw_readq(sbm_base + R_MAC_ETHERNET_ADDR); sbmac_orig_hwaddr = __raw_readq(sbm_base + R_MAC_ETHERNET_ADDR);
pr_debug("%s: %sconfiguring MAC at 0x%08Lx\n", pldev->dev.bus_id, pr_debug("%s: %sconfiguring MAC at 0x%08Lx\n", dev_name(&pldev->dev),
sbmac_orig_hwaddr ? "" : "not ", (long long)res->start); sbmac_orig_hwaddr ? "" : "not ", (long long)res->start);
if (sbmac_orig_hwaddr == 0) { if (sbmac_orig_hwaddr == 0) {
err = 0; err = 0;
...@@ -2721,7 +2721,7 @@ static int __init sbmac_probe(struct platform_device *pldev) ...@@ -2721,7 +2721,7 @@ static int __init sbmac_probe(struct platform_device *pldev)
dev = alloc_etherdev(sizeof(struct sbmac_softc)); dev = alloc_etherdev(sizeof(struct sbmac_softc));
if (!dev) { if (!dev) {
printk(KERN_ERR "%s: unable to allocate etherdev\n", printk(KERN_ERR "%s: unable to allocate etherdev\n",
pldev->dev.bus_id); dev_name(&pldev->dev));
err = -ENOMEM; err = -ENOMEM;
goto out_unmap; goto out_unmap;
} }
......
...@@ -1545,7 +1545,7 @@ smc911x_ethtool_getdrvinfo(struct net_device *dev, struct ethtool_drvinfo *info) ...@@ -1545,7 +1545,7 @@ smc911x_ethtool_getdrvinfo(struct net_device *dev, struct ethtool_drvinfo *info)
{ {
strncpy(info->driver, CARDNAME, sizeof(info->driver)); strncpy(info->driver, CARDNAME, sizeof(info->driver));
strncpy(info->version, version, sizeof(info->version)); strncpy(info->version, version, sizeof(info->version));
strncpy(info->bus_info, dev->dev.parent->bus_id, sizeof(info->bus_info)); strncpy(info->bus_info, dev_name(dev->dev.parent), sizeof(info->bus_info));
} }
static int smc911x_ethtool_nwayreset(struct net_device *dev) static int smc911x_ethtool_nwayreset(struct net_device *dev)
......
...@@ -1614,7 +1614,7 @@ smc_ethtool_getdrvinfo(struct net_device *dev, struct ethtool_drvinfo *info) ...@@ -1614,7 +1614,7 @@ smc_ethtool_getdrvinfo(struct net_device *dev, struct ethtool_drvinfo *info)
{ {
strncpy(info->driver, CARDNAME, sizeof(info->driver)); strncpy(info->driver, CARDNAME, sizeof(info->driver));
strncpy(info->version, version, sizeof(info->version)); strncpy(info->version, version, sizeof(info->version));
strncpy(info->bus_info, dev->dev.parent->bus_id, sizeof(info->bus_info)); strncpy(info->bus_info, dev_name(dev->dev.parent), sizeof(info->bus_info));
} }
static int smc_ethtool_nwayreset(struct net_device *dev) static int smc_ethtool_nwayreset(struct net_device *dev)
......
...@@ -769,7 +769,7 @@ static int smsc911x_mii_probe(struct net_device *dev) ...@@ -769,7 +769,7 @@ static int smsc911x_mii_probe(struct net_device *dev)
return -ENODEV; return -ENODEV;
} }
phydev = phy_connect(dev, phydev->dev.bus_id, phydev = phy_connect(dev, dev_name(&phydev->dev),
&smsc911x_phy_adjust_link, 0, pdata->config.phy_interface); &smsc911x_phy_adjust_link, 0, pdata->config.phy_interface);
if (IS_ERR(phydev)) { if (IS_ERR(phydev)) {
...@@ -778,7 +778,8 @@ static int smsc911x_mii_probe(struct net_device *dev) ...@@ -778,7 +778,8 @@ static int smsc911x_mii_probe(struct net_device *dev)
} }
pr_info("%s: attached PHY driver [%s] (mii_bus:phy_addr=%s, irq=%d)\n", pr_info("%s: attached PHY driver [%s] (mii_bus:phy_addr=%s, irq=%d)\n",
dev->name, phydev->drv->name, phydev->dev.bus_id, phydev->irq); dev->name, phydev->drv->name,
dev_name(&phydev->dev), phydev->irq);
/* mask with MAC supported features */ /* mask with MAC supported features */
phydev->supported &= (PHY_BASIC_FEATURES | SUPPORTED_Pause | phydev->supported &= (PHY_BASIC_FEATURES | SUPPORTED_Pause |
...@@ -1549,7 +1550,7 @@ static void smsc911x_ethtool_getdrvinfo(struct net_device *dev, ...@@ -1549,7 +1550,7 @@ static void smsc911x_ethtool_getdrvinfo(struct net_device *dev,
{ {
strlcpy(info->driver, SMSC_CHIPNAME, sizeof(info->driver)); strlcpy(info->driver, SMSC_CHIPNAME, sizeof(info->driver));
strlcpy(info->version, SMSC_DRV_VERSION, sizeof(info->version)); strlcpy(info->version, SMSC_DRV_VERSION, sizeof(info->version));
strlcpy(info->bus_info, dev->dev.parent->bus_id, strlcpy(info->bus_info, dev_name(dev->dev.parent),
sizeof(info->bus_info)); sizeof(info->bus_info));
} }
......
...@@ -1160,7 +1160,7 @@ static int smsc9420_mii_probe(struct net_device *dev) ...@@ -1160,7 +1160,7 @@ static int smsc9420_mii_probe(struct net_device *dev)
smsc_info(PROBE, "PHY addr %d, phy_id 0x%08X", phydev->addr, smsc_info(PROBE, "PHY addr %d, phy_id 0x%08X", phydev->addr,
phydev->phy_id); phydev->phy_id);
phydev = phy_connect(dev, phydev->dev.bus_id, phydev = phy_connect(dev, dev_name(&phydev->dev),
&smsc9420_phy_adjust_link, 0, PHY_INTERFACE_MODE_MII); &smsc9420_phy_adjust_link, 0, PHY_INTERFACE_MODE_MII);
if (IS_ERR(phydev)) { if (IS_ERR(phydev)) {
...@@ -1169,7 +1169,7 @@ static int smsc9420_mii_probe(struct net_device *dev) ...@@ -1169,7 +1169,7 @@ static int smsc9420_mii_probe(struct net_device *dev)
} }
pr_info("%s: attached PHY driver [%s] (mii_bus:phy_addr=%s, irq=%d)\n", pr_info("%s: attached PHY driver [%s] (mii_bus:phy_addr=%s, irq=%d)\n",
dev->name, phydev->drv->name, phydev->dev.bus_id, phydev->irq); dev->name, phydev->drv->name, dev_name(&phydev->dev), phydev->irq);
/* mask with MAC supported features */ /* mask with MAC supported features */
phydev->supported &= (PHY_BASIC_FEATURES | SUPPORTED_Pause | phydev->supported &= (PHY_BASIC_FEATURES | SUPPORTED_Pause |
......
...@@ -725,7 +725,7 @@ static int tc_mii_probe(struct net_device *dev) ...@@ -725,7 +725,7 @@ static int tc_mii_probe(struct net_device *dev)
} }
/* attach the mac to the phy */ /* attach the mac to the phy */
phydev = phy_connect(dev, phydev->dev.bus_id, phydev = phy_connect(dev, dev_name(&phydev->dev),
&tc_handle_link_change, 0, &tc_handle_link_change, 0,
lp->chiptype == TC35815_TX4939 ? lp->chiptype == TC35815_TX4939 ?
PHY_INTERFACE_MODE_RMII : PHY_INTERFACE_MODE_MII); PHY_INTERFACE_MODE_RMII : PHY_INTERFACE_MODE_MII);
...@@ -735,7 +735,7 @@ static int tc_mii_probe(struct net_device *dev) ...@@ -735,7 +735,7 @@ static int tc_mii_probe(struct net_device *dev)
} }
printk(KERN_INFO "%s: attached PHY driver [%s] " printk(KERN_INFO "%s: attached PHY driver [%s] "
"(mii_bus:phy_addr=%s, id=%x)\n", "(mii_bus:phy_addr=%s, id=%x)\n",
dev->name, phydev->drv->name, phydev->dev.bus_id, dev->name, phydev->drv->name, dev_name(&phydev->dev),
phydev->phy_id); phydev->phy_id);
/* mask with MAC supported features */ /* mask with MAC supported features */
......
...@@ -183,7 +183,7 @@ static int __init sonic_probe1(struct net_device *dev) ...@@ -183,7 +183,7 @@ static int __init sonic_probe1(struct net_device *dev)
if (lp->descriptors == NULL) { if (lp->descriptors == NULL) {
printk(KERN_ERR "%s: couldn't alloc DMA memory for " printk(KERN_ERR "%s: couldn't alloc DMA memory for "
" descriptors.\n", lp->device->bus_id); " descriptors.\n", dev_name(lp->device));
goto out; goto out;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment