diff options
Diffstat (limited to 'arch/sparc/kernel/pci.c')
-rw-r--r-- | arch/sparc/kernel/pci.c | 33 |
1 files changed, 14 insertions, 19 deletions
diff --git a/arch/sparc/kernel/pci.c b/arch/sparc/kernel/pci.c index 75b31bcdeadf..04bacce76fe6 100644 --- a/arch/sparc/kernel/pci.c +++ b/arch/sparc/kernel/pci.c | |||
@@ -356,7 +356,7 @@ static struct pci_dev *of_create_pci_dev(struct pci_pbm_info *pbm, | |||
356 | return dev; | 356 | return dev; |
357 | } | 357 | } |
358 | 358 | ||
359 | static void __devinit apb_calc_first_last(u8 map, u32 *first_p, u32 *last_p) | 359 | static void apb_calc_first_last(u8 map, u32 *first_p, u32 *last_p) |
360 | { | 360 | { |
361 | u32 idx, first, last; | 361 | u32 idx, first, last; |
362 | 362 | ||
@@ -378,9 +378,8 @@ static void __devinit apb_calc_first_last(u8 map, u32 *first_p, u32 *last_p) | |||
378 | /* Cook up fake bus resources for SUNW,simba PCI bridges which lack | 378 | /* Cook up fake bus resources for SUNW,simba PCI bridges which lack |
379 | * a proper 'ranges' property. | 379 | * a proper 'ranges' property. |
380 | */ | 380 | */ |
381 | static void __devinit apb_fake_ranges(struct pci_dev *dev, | 381 | static void apb_fake_ranges(struct pci_dev *dev, struct pci_bus *bus, |
382 | struct pci_bus *bus, | 382 | struct pci_pbm_info *pbm) |
383 | struct pci_pbm_info *pbm) | ||
384 | { | 383 | { |
385 | struct pci_bus_region region; | 384 | struct pci_bus_region region; |
386 | struct resource *res; | 385 | struct resource *res; |
@@ -404,15 +403,13 @@ static void __devinit apb_fake_ranges(struct pci_dev *dev, | |||
404 | pcibios_bus_to_resource(dev, res, ®ion); | 403 | pcibios_bus_to_resource(dev, res, ®ion); |
405 | } | 404 | } |
406 | 405 | ||
407 | static void __devinit pci_of_scan_bus(struct pci_pbm_info *pbm, | 406 | static void pci_of_scan_bus(struct pci_pbm_info *pbm, struct device_node *node, |
408 | struct device_node *node, | 407 | struct pci_bus *bus); |
409 | struct pci_bus *bus); | ||
410 | 408 | ||
411 | #define GET_64BIT(prop, i) ((((u64) (prop)[(i)]) << 32) | (prop)[(i)+1]) | 409 | #define GET_64BIT(prop, i) ((((u64) (prop)[(i)]) << 32) | (prop)[(i)+1]) |
412 | 410 | ||
413 | static void __devinit of_scan_pci_bridge(struct pci_pbm_info *pbm, | 411 | static void of_scan_pci_bridge(struct pci_pbm_info *pbm, |
414 | struct device_node *node, | 412 | struct device_node *node, struct pci_dev *dev) |
415 | struct pci_dev *dev) | ||
416 | { | 413 | { |
417 | struct pci_bus *bus; | 414 | struct pci_bus *bus; |
418 | const u32 *busrange, *ranges; | 415 | const u32 *busrange, *ranges; |
@@ -503,9 +500,8 @@ after_ranges: | |||
503 | pci_of_scan_bus(pbm, node, bus); | 500 | pci_of_scan_bus(pbm, node, bus); |
504 | } | 501 | } |
505 | 502 | ||
506 | static void __devinit pci_of_scan_bus(struct pci_pbm_info *pbm, | 503 | static void pci_of_scan_bus(struct pci_pbm_info *pbm, struct device_node *node, |
507 | struct device_node *node, | 504 | struct pci_bus *bus) |
508 | struct pci_bus *bus) | ||
509 | { | 505 | { |
510 | struct device_node *child; | 506 | struct device_node *child; |
511 | const u32 *reg; | 507 | const u32 *reg; |
@@ -564,7 +560,7 @@ show_pciobppath_attr(struct device * dev, struct device_attribute * attr, char * | |||
564 | 560 | ||
565 | static DEVICE_ATTR(obppath, S_IRUSR | S_IRGRP | S_IROTH, show_pciobppath_attr, NULL); | 561 | static DEVICE_ATTR(obppath, S_IRUSR | S_IRGRP | S_IROTH, show_pciobppath_attr, NULL); |
566 | 562 | ||
567 | static void __devinit pci_bus_register_of_sysfs(struct pci_bus *bus) | 563 | static void pci_bus_register_of_sysfs(struct pci_bus *bus) |
568 | { | 564 | { |
569 | struct pci_dev *dev; | 565 | struct pci_dev *dev; |
570 | struct pci_bus *child_bus; | 566 | struct pci_bus *child_bus; |
@@ -585,8 +581,8 @@ static void __devinit pci_bus_register_of_sysfs(struct pci_bus *bus) | |||
585 | pci_bus_register_of_sysfs(child_bus); | 581 | pci_bus_register_of_sysfs(child_bus); |
586 | } | 582 | } |
587 | 583 | ||
588 | struct pci_bus * __devinit pci_scan_one_pbm(struct pci_pbm_info *pbm, | 584 | struct pci_bus *pci_scan_one_pbm(struct pci_pbm_info *pbm, |
589 | struct device *parent) | 585 | struct device *parent) |
590 | { | 586 | { |
591 | LIST_HEAD(resources); | 587 | LIST_HEAD(resources); |
592 | struct device_node *node = pbm->op->dev.of_node; | 588 | struct device_node *node = pbm->op->dev.of_node; |
@@ -618,7 +614,7 @@ struct pci_bus * __devinit pci_scan_one_pbm(struct pci_pbm_info *pbm, | |||
618 | return bus; | 614 | return bus; |
619 | } | 615 | } |
620 | 616 | ||
621 | void __devinit pcibios_fixup_bus(struct pci_bus *pbus) | 617 | void pcibios_fixup_bus(struct pci_bus *pbus) |
622 | { | 618 | { |
623 | } | 619 | } |
624 | 620 | ||
@@ -949,8 +945,7 @@ static int __init pcibios_init(void) | |||
949 | subsys_initcall(pcibios_init); | 945 | subsys_initcall(pcibios_init); |
950 | 946 | ||
951 | #ifdef CONFIG_SYSFS | 947 | #ifdef CONFIG_SYSFS |
952 | static void __devinit pci_bus_slot_names(struct device_node *node, | 948 | static void pci_bus_slot_names(struct device_node *node, struct pci_bus *bus) |
953 | struct pci_bus *bus) | ||
954 | { | 949 | { |
955 | const struct pci_slot_names { | 950 | const struct pci_slot_names { |
956 | u32 slot_mask; | 951 | u32 slot_mask; |