Skip to content

Commit

Permalink
ide: struct device - replace bus_id with dev_name(), dev_set_name()
Browse files Browse the repository at this point in the history
Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
  • Loading branch information
Kay Sievers authored and Bartlomiej Zolnierkiewicz committed Dec 29, 2008
1 parent 702c026 commit dc09c78
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/ide/ide-probe.c
Original file line number Diff line number Diff line change
Expand Up @@ -642,7 +642,7 @@ static int ide_register_port(ide_hwif_t *hwif)
int ret;

/* register with global device tree */
strlcpy(hwif->gendev.bus_id,hwif->name,BUS_ID_SIZE);
dev_set_name(&hwif->gendev, hwif->name);
hwif->gendev.driver_data = hwif;
if (hwif->gendev.parent == NULL) {
if (hwif->dev)
Expand Down Expand Up @@ -1315,7 +1315,7 @@ static void hwif_register_devices(ide_hwif_t *hwif)
if ((drive->dev_flags & IDE_DFLAG_PRESENT) == 0)
continue;

snprintf(dev->bus_id, BUS_ID_SIZE, "%u.%u", hwif->index, i);
dev_set_name(dev, "%u.%u", hwif->index, i);
dev->parent = &hwif->gendev;
dev->bus = &ide_bus_type;
dev->driver_data = drive;
Expand Down

0 comments on commit dc09c78

Please sign in to comment.