mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-24 01:41:39 +00:00
ide: struct device - replace bus_id with dev_name(), dev_set_name()
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>
This commit is contained in:
parent
702c026be8
commit
dc09c78425
1 changed files with 2 additions and 2 deletions
|
@ -642,7 +642,7 @@ static int ide_register_port(ide_hwif_t *hwif)
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
/* register with global device tree */
|
/* 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;
|
hwif->gendev.driver_data = hwif;
|
||||||
if (hwif->gendev.parent == NULL) {
|
if (hwif->gendev.parent == NULL) {
|
||||||
if (hwif->dev)
|
if (hwif->dev)
|
||||||
|
@ -1315,7 +1315,7 @@ static void hwif_register_devices(ide_hwif_t *hwif)
|
||||||
if ((drive->dev_flags & IDE_DFLAG_PRESENT) == 0)
|
if ((drive->dev_flags & IDE_DFLAG_PRESENT) == 0)
|
||||||
continue;
|
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->parent = &hwif->gendev;
|
||||||
dev->bus = &ide_bus_type;
|
dev->bus = &ide_bus_type;
|
||||||
dev->driver_data = drive;
|
dev->driver_data = drive;
|
||||||
|
|
Loading…
Reference in a new issue