public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] provide PCI resources with a parent
@ 2004-08-06 20:24 Jesse Barnes
  0 siblings, 0 replies; only message in thread
From: Jesse Barnes @ 2004-08-06 20:24 UTC (permalink / raw)
  To: linux-ia64

[-- Attachment #1: Type: text/plain, Size: 286 bytes --]

In working on the patch to export PCI ROM space via sysfs, I found that the 
sn2 PCI code doesn't assign a parent resource to any of the PCI device 
resources as it builds them.  This provides a simple fix for that problem.

Signed-off-by: Jesse Barnes <jbarnes@sgi.com>

Thanks,
Jesse

[-- Attachment #2: pci-res-parent.patch --]
[-- Type: text/plain, Size: 1143 bytes --]

===== arch/ia64/sn/io/machvec/pci_bus_cvlink.c 1.42 vs edited =====
--- 1.42/arch/ia64/sn/io/machvec/pci_bus_cvlink.c	2004-06-07 08:45:20 -07:00
+++ edited/arch/ia64/sn/io/machvec/pci_bus_cvlink.c	2004-08-06 10:38:58 -07:00
@@ -290,6 +290,7 @@
 			addr |= __IA64_UNCACHED_OFFSET;
 			dev->resource[idx].start = addr;
 			dev->resource[idx].end = addr + size;
+			dev->resource[idx].parent = &ioport_resource;
 		}
 
 		if (dev->resource[idx].flags & IORESOURCE_IO)
@@ -322,6 +323,7 @@
 			addr |= __IA64_UNCACHED_OFFSET;
 			dev->resource[idx].start = addr;
 			dev->resource[idx].end = addr + size;
+			dev->resource[idx].parent = &iomem_resource;
 		}
 
 		if (dev->resource[idx].flags & IORESOURCE_MEM)
@@ -351,6 +353,7 @@
                         addr |= __IA64_UNCACHED_OFFSET;
                         dev->resource[PCI_ROM_RESOURCE].start = addr;
                         dev->resource[PCI_ROM_RESOURCE].end = addr + size;
+			dev->resource[idx].parent = &iomem_resource;
                         if (dev->resource[PCI_ROM_RESOURCE].flags & IORESOURCE_MEM)
                                 cmd |= PCI_COMMAND_MEMORY;
                 }

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2004-08-06 20:24 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-08-06 20:24 [PATCH] provide PCI resources with a parent Jesse Barnes

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox