summaryrefslogtreecommitdiffstats
path: root/arch/i386/pci/pcbios.c
diff options
context:
space:
mode:
authorAkinobu Mita <mita@miraclelinux.com>2006-06-26 00:24:39 -0700
committerLinus Torvalds <torvalds@g5.osdl.org>2006-06-26 09:58:17 -0700
commita7addcea6ac7c0e9733a48cda06ca0880f116a48 (patch)
tree5d18b98798c98dd2c044f4a9ed9c7b372c599a9c /arch/i386/pci/pcbios.c
parent8e13059a37252c45ab7173a0e4bac05e4a444ab6 (diff)
[PATCH] arch: use list_move()
This patch converts the combination of list_del(A) and list_add(A, B) to list_move(A, B) under arch/. Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: "David S. Miller" <davem@davemloft.net> Signed-off-by: Akinobu Mita <mita@miraclelinux.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/i386/pci/pcbios.c')
-rw-r--r--arch/i386/pci/pcbios.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/arch/i386/pci/pcbios.c b/arch/i386/pci/pcbios.c
index 1eec0868f4b..ed1512a175a 100644
--- a/arch/i386/pci/pcbios.c
+++ b/arch/i386/pci/pcbios.c
@@ -371,8 +371,7 @@ void __devinit pcibios_sort(void)
list_for_each(ln, &pci_devices) {
d = pci_dev_g(ln);
if (d->bus->number == bus && d->devfn == devfn) {
- list_del(&d->global_list);
- list_add_tail(&d->global_list, &sorted_devices);
+ list_move_tail(&d->global_list, &sorted_devices);
if (d == dev)
found = 1;
break;
@@ -390,8 +389,7 @@ void __devinit pcibios_sort(void)
if (!found) {
printk(KERN_WARNING "PCI: Device %s not found by BIOS\n",
pci_name(dev));
- list_del(&dev->global_list);
- list_add_tail(&dev->global_list, &sorted_devices);
+ list_move_tail(&dev->global_list, &sorted_devices);
}
}
list_splice(&sorted_devices, &pci_devices);