phy: Change mii_bus id field to a string
Having the id field be an int was making more complex bus topologies excessively difficult. For now, just convert it to a string, and change all instances of "bus->id = val" to snprintf(id, MII_BUS_ID_LEN, "%x", val). Signed-off-by: Andy Fleming <afleming@freescale.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
This commit is contained in:
committed by
Jeff Garzik
parent
d080cd6301
commit
9d9326d3bc
@ -241,7 +241,7 @@ static int __devinit gpio_mdio_probe(struct of_device *ofdev,
|
||||
new_bus->reset = &gpio_mdio_reset;
|
||||
|
||||
prop = of_get_property(np, "reg", NULL);
|
||||
new_bus->id = *prop;
|
||||
snprintf(new_bus->id, MII_BUS_ID_SIZE, "%x", *prop);
|
||||
new_bus->priv = priv;
|
||||
|
||||
new_bus->phy_mask = 0;
|
||||
|
Reference in New Issue
Block a user