diff options
author | Gu Zheng <guz.fnst@cn.fujitsu.com> | 2013-05-25 09:48:31 -0400 |
---|---|---|
committer | Bjorn Helgaas <bhelgaas@google.com> | 2013-06-05 15:49:36 -0400 |
commit | 8b1fce04dc2a2210f050484afa85acc3a81cfbba (patch) | |
tree | d790a4d12baf35c9f32cafde8386d505a7576067 /arch/sparc/kernel | |
parent | 3c6e6ae770f338ef3e54c5823c21063204f53537 (diff) |
PCI: Convert alloc_pci_dev(void) to pci_alloc_dev(bus)
Use the new pci_alloc_dev(bus) to replace the existing using of
alloc_pci_dev(void).
[bhelgaas: drop pci_bus ref later in pci_release_dev()]
Signed-off-by: Gu Zheng <guz.fnst@cn.fujitsu.com>
Signed-off-by: Jiang Liu <jiang.liu@huawei.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: David Airlie <airlied@linux.ie>
Cc: Neela Syam Kolli <megaraidlinux@lsi.com>
Cc: "James E.J. Bottomley" <JBottomley@parallels.com>
Cc: Yinghai Lu <yinghai@kernel.org>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'arch/sparc/kernel')
-rw-r--r-- | arch/sparc/kernel/pci.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/arch/sparc/kernel/pci.c b/arch/sparc/kernel/pci.c index baf4366e2d6a..e5871fb455b3 100644 --- a/arch/sparc/kernel/pci.c +++ b/arch/sparc/kernel/pci.c | |||
@@ -254,7 +254,7 @@ static struct pci_dev *of_create_pci_dev(struct pci_pbm_info *pbm, | |||
254 | const char *type; | 254 | const char *type; |
255 | u32 class; | 255 | u32 class; |
256 | 256 | ||
257 | dev = alloc_pci_dev(); | 257 | dev = pci_alloc_dev(bus); |
258 | if (!dev) | 258 | if (!dev) |
259 | return NULL; | 259 | return NULL; |
260 | 260 | ||
@@ -281,7 +281,6 @@ static struct pci_dev *of_create_pci_dev(struct pci_pbm_info *pbm, | |||
281 | printk(" create device, devfn: %x, type: %s\n", | 281 | printk(" create device, devfn: %x, type: %s\n", |
282 | devfn, type); | 282 | devfn, type); |
283 | 283 | ||
284 | dev->bus = bus; | ||
285 | dev->sysdata = node; | 284 | dev->sysdata = node; |
286 | dev->dev.parent = bus->bridge; | 285 | dev->dev.parent = bus->bridge; |
287 | dev->dev.bus = &pci_bus_type; | 286 | dev->dev.bus = &pci_bus_type; |