Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 5626
b: refs/heads/master
c: 556e58f
h: refs/heads/master
v: v3
  • Loading branch information
Ravikiran G Thirumalai authored and Linus Torvalds committed Aug 4, 2005
1 parent 16bb1f5 commit 898652b
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: fd6f31c31825f62eb91f491e8316129e5ce81fc6
refs/heads/master: 556e58febf90c8cb1da25669d0892bf5fd2ddac2
16 changes: 13 additions & 3 deletions trunk/drivers/ide/ide-probe.c
Original file line number Diff line number Diff line change
Expand Up @@ -960,6 +960,15 @@ static void save_match(ide_hwif_t *hwif, ide_hwif_t *new, ide_hwif_t **match)
}
#endif /* MAX_HWIFS > 1 */

static inline int hwif_to_node(ide_hwif_t *hwif)
{
if (hwif->pci_dev)
return pcibus_to_node(hwif->pci_dev->bus);
else
/* Add ways to determine the node of other busses here */
return -1;
}

/*
* init request queue
*/
Expand All @@ -978,8 +987,7 @@ static int ide_init_queue(ide_drive_t *drive)
* do not.
*/

q = blk_init_queue_node(do_ide_request, &ide_lock,
pcibus_to_node(drive->hwif->pci_dev->bus));
q = blk_init_queue_node(do_ide_request, &ide_lock, hwif_to_node(hwif));
if (!q)
return 1;

Expand Down Expand Up @@ -1048,6 +1056,8 @@ static int init_irq (ide_hwif_t *hwif)

BUG_ON(in_interrupt());
BUG_ON(irqs_disabled());
BUG_ON(hwif == NULL);

down(&ide_cfg_sem);
hwif->hwgroup = NULL;
#if MAX_HWIFS > 1
Expand Down Expand Up @@ -1097,7 +1107,7 @@ static int init_irq (ide_hwif_t *hwif)
spin_unlock_irq(&ide_lock);
} else {
hwgroup = kmalloc_node(sizeof(ide_hwgroup_t), GFP_KERNEL,
pcibus_to_node(hwif->drives[0].hwif->pci_dev->bus));
hwif_to_node(hwif->drives[0].hwif));
if (!hwgroup)
goto out_up;

Expand Down

0 comments on commit 898652b

Please sign in to comment.