aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ide')
-rw-r--r--drivers/ide/ide-disk.c2
-rw-r--r--drivers/ide/ide-probe.c7
-rw-r--r--drivers/ide/legacy/ide-cs.c2
3 files changed, 6 insertions, 5 deletions
diff --git a/drivers/ide/ide-disk.c b/drivers/ide/ide-disk.c
index f9c1acb4ed6a..c9d3a00a3c0c 100644
--- a/drivers/ide/ide-disk.c
+++ b/drivers/ide/ide-disk.c
@@ -1220,7 +1220,7 @@ static int ide_disk_probe(struct device *dev)
1220 goto failed; 1220 goto failed;
1221 1221
1222 g = alloc_disk_node(1 << PARTN_BITS, 1222 g = alloc_disk_node(1 << PARTN_BITS,
1223 pcibus_to_node(drive->hwif->pci_dev->bus)); 1223 hwif_to_node(drive->hwif));
1224 if (!g) 1224 if (!g)
1225 goto out_free_idkp; 1225 goto out_free_idkp;
1226 1226
diff --git a/drivers/ide/ide-probe.c b/drivers/ide/ide-probe.c
index 7df85af75371..c1128ae5cd2f 100644
--- a/drivers/ide/ide-probe.c
+++ b/drivers/ide/ide-probe.c
@@ -978,8 +978,7 @@ static int ide_init_queue(ide_drive_t *drive)
978 * do not. 978 * do not.
979 */ 979 */
980 980
981 q = blk_init_queue_node(do_ide_request, &ide_lock, 981 q = blk_init_queue_node(do_ide_request, &ide_lock, hwif_to_node(hwif));
982 pcibus_to_node(drive->hwif->pci_dev->bus));
983 if (!q) 982 if (!q)
984 return 1; 983 return 1;
985 984
@@ -1048,6 +1047,8 @@ static int init_irq (ide_hwif_t *hwif)
1048 1047
1049 BUG_ON(in_interrupt()); 1048 BUG_ON(in_interrupt());
1050 BUG_ON(irqs_disabled()); 1049 BUG_ON(irqs_disabled());
1050 BUG_ON(hwif == NULL);
1051
1051 down(&ide_cfg_sem); 1052 down(&ide_cfg_sem);
1052 hwif->hwgroup = NULL; 1053 hwif->hwgroup = NULL;
1053#if MAX_HWIFS > 1 1054#if MAX_HWIFS > 1
@@ -1097,7 +1098,7 @@ static int init_irq (ide_hwif_t *hwif)
1097 spin_unlock_irq(&ide_lock); 1098 spin_unlock_irq(&ide_lock);
1098 } else { 1099 } else {
1099 hwgroup = kmalloc_node(sizeof(ide_hwgroup_t), GFP_KERNEL, 1100 hwgroup = kmalloc_node(sizeof(ide_hwgroup_t), GFP_KERNEL,
1100 pcibus_to_node(hwif->drives[0].hwif->pci_dev->bus)); 1101 hwif_to_node(hwif->drives[0].hwif));
1101 if (!hwgroup) 1102 if (!hwgroup)
1102 goto out_up; 1103 goto out_up;
1103 1104
diff --git a/drivers/ide/legacy/ide-cs.c b/drivers/ide/legacy/ide-cs.c
index 03747439ac9c..f1d1ec4e9677 100644
--- a/drivers/ide/legacy/ide-cs.c
+++ b/drivers/ide/legacy/ide-cs.c
@@ -508,5 +508,5 @@ static void __exit exit_ide_cs(void)
508 BUG_ON(dev_list != NULL); 508 BUG_ON(dev_list != NULL);
509} 509}
510 510
511module_init(init_ide_cs); 511late_initcall(init_ide_cs);
512module_exit(exit_ide_cs); 512module_exit(exit_ide_cs);