diff options
author | Greg Kroah-Hartman <gregkh@suse.de> | 2006-06-12 18:14:29 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2006-06-27 12:23:58 -0400 |
commit | 1396a8c3f7cec9f5e0d00bd089be21fc468f0f1c (patch) | |
tree | b96018459e26a24e20221f0bb7d5bb25d6608147 /drivers/pci/setup-res.c | |
parent | 7c7459d1f91abdf1e31ef80cad526e83e8b8ba4e (diff) |
[PATCH] 64bit resource: fix up printks for resources in pci core and hotplug drivers
This is needed if we wish to change the size of the resource structures.
Based on an original patch from Vivek Goyal <vgoyal@in.ibm.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/pci/setup-res.c')
-rw-r--r-- | drivers/pci/setup-res.c | 28 |
1 files changed, 17 insertions, 11 deletions
diff --git a/drivers/pci/setup-res.c b/drivers/pci/setup-res.c index 577f4b55c46d..f5ff0d3ba620 100644 --- a/drivers/pci/setup-res.c +++ b/drivers/pci/setup-res.c | |||
@@ -40,8 +40,9 @@ pci_update_resource(struct pci_dev *dev, struct resource *res, int resno) | |||
40 | 40 | ||
41 | pcibios_resource_to_bus(dev, ®ion, res); | 41 | pcibios_resource_to_bus(dev, ®ion, res); |
42 | 42 | ||
43 | pr_debug(" got res [%lx:%lx] bus [%lx:%lx] flags %lx for " | 43 | pr_debug(" got res [%llx:%llx] bus [%lx:%lx] flags %lx for " |
44 | "BAR %d of %s\n", res->start, res->end, | 44 | "BAR %d of %s\n", (unsigned long long)res->start, |
45 | (unsigned long long)res->end, | ||
45 | region.start, region.end, res->flags, resno, pci_name(dev)); | 46 | region.start, region.end, res->flags, resno, pci_name(dev)); |
46 | 47 | ||
47 | new = region.start | (res->flags & PCI_REGION_FLAG_MASK); | 48 | new = region.start | (res->flags & PCI_REGION_FLAG_MASK); |
@@ -104,10 +105,12 @@ pci_claim_resource(struct pci_dev *dev, int resource) | |||
104 | err = insert_resource(root, res); | 105 | err = insert_resource(root, res); |
105 | 106 | ||
106 | if (err) { | 107 | if (err) { |
107 | printk(KERN_ERR "PCI: %s region %d of %s %s [%lx:%lx]\n", | 108 | printk(KERN_ERR "PCI: %s region %d of %s %s [%llx:%llx]\n", |
108 | root ? "Address space collision on" : | 109 | root ? "Address space collision on" : |
109 | "No parent found for", | 110 | "No parent found for", |
110 | resource, dtype, pci_name(dev), res->start, res->end); | 111 | resource, dtype, pci_name(dev), |
112 | (unsigned long long)res->start, | ||
113 | (unsigned long long)res->end); | ||
111 | } | 114 | } |
112 | 115 | ||
113 | return err; | 116 | return err; |
@@ -145,9 +148,11 @@ int pci_assign_resource(struct pci_dev *dev, int resno) | |||
145 | } | 148 | } |
146 | 149 | ||
147 | if (ret) { | 150 | if (ret) { |
148 | printk(KERN_ERR "PCI: Failed to allocate %s resource #%d:%lx@%lx for %s\n", | 151 | printk(KERN_ERR "PCI: Failed to allocate %s resource " |
149 | res->flags & IORESOURCE_IO ? "I/O" : "mem", | 152 | "#%d:%llx@%llx for %s\n", |
150 | resno, size, res->start, pci_name(dev)); | 153 | res->flags & IORESOURCE_IO ? "I/O" : "mem", |
154 | resno, (unsigned long long)size, | ||
155 | (unsigned long long)res->start, pci_name(dev)); | ||
151 | } else if (resno < PCI_BRIDGE_RESOURCES) { | 156 | } else if (resno < PCI_BRIDGE_RESOURCES) { |
152 | pci_update_resource(dev, res, resno); | 157 | pci_update_resource(dev, res, resno); |
153 | } | 158 | } |
@@ -213,8 +218,9 @@ pdev_sort_resources(struct pci_dev *dev, struct resource_list *head) | |||
213 | continue; | 218 | continue; |
214 | if (!r_align) { | 219 | if (!r_align) { |
215 | printk(KERN_WARNING "PCI: Ignore bogus resource %d " | 220 | printk(KERN_WARNING "PCI: Ignore bogus resource %d " |
216 | "[%lx:%lx] of %s\n", | 221 | "[%llx:%llx] of %s\n", |
217 | i, r->start, r->end, pci_name(dev)); | 222 | i, (unsigned long long)r->start, |
223 | (unsigned long long)r->end, pci_name(dev)); | ||
218 | continue; | 224 | continue; |
219 | } | 225 | } |
220 | r_align = (i < PCI_BRIDGE_RESOURCES) ? r_align + 1 : r->start; | 226 | r_align = (i < PCI_BRIDGE_RESOURCES) ? r_align + 1 : r->start; |