aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/ide/ide-probe.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/ide/ide-probe.c b/drivers/ide/ide-probe.c
index c1cd1af2646b..aaefd70dbff6 100644
--- a/drivers/ide/ide-probe.c
+++ b/drivers/ide/ide-probe.c
@@ -642,7 +642,7 @@ static int ide_register_port(ide_hwif_t *hwif)
642 int ret; 642 int ret;
643 643
644 /* register with global device tree */ 644 /* register with global device tree */
645 strlcpy(hwif->gendev.bus_id,hwif->name,BUS_ID_SIZE); 645 dev_set_name(&hwif->gendev, hwif->name);
646 hwif->gendev.driver_data = hwif; 646 hwif->gendev.driver_data = hwif;
647 if (hwif->gendev.parent == NULL) { 647 if (hwif->gendev.parent == NULL) {
648 if (hwif->dev) 648 if (hwif->dev)
@@ -1315,7 +1315,7 @@ static void hwif_register_devices(ide_hwif_t *hwif)
1315 if ((drive->dev_flags & IDE_DFLAG_PRESENT) == 0) 1315 if ((drive->dev_flags & IDE_DFLAG_PRESENT) == 0)
1316 continue; 1316 continue;
1317 1317
1318 snprintf(dev->bus_id, BUS_ID_SIZE, "%u.%u", hwif->index, i); 1318 dev_set_name(dev, "%u.%u", hwif->index, i);
1319 dev->parent = &hwif->gendev; 1319 dev->parent = &hwif->gendev;
1320 dev->bus = &ide_bus_type; 1320 dev->bus = &ide_bus_type;
1321 dev->driver_data = drive; 1321 dev->driver_data = drive;