sparc/PCI: Stop reserving System ROM and Video ROM in PCI space

Previously, pci_register_legacy_regions() reserved PCI address space under
every PCI host bridge for the System ROM and the Video ROM, but these
regions are not part of PCI address space.

Previously, pci_register_legacy_regions() reserved the following areas of
PCI address space under every PCI host bridge:

  [bus 0xa0000-0xbffff]    Video RAM area (VGA frame buffer)
  [bus 0xc0000-0xc7fff]    Video ROM
  [bus 0xf0000-0xfffff]    System ROM

It does need to reserve the [bus 0xa0000-0xbffff] region (at least if
there's a possibility of a VGA device below the bridge) because VGA devices
can respond to that even if they don't describe it with a BAR.

But the Video ROM and System ROM areas don't seem necessary because they
are not areas that legacy PCI devices respond to.

They appear to be copied from x86, where they describe areas of system
memory that depend on BIOS conventions.  On x86, BIOS copies the option ROM
of the primary VGA device to RAM at 0xc0000, and the 0xf0000-0xfffff region
is reserved for the motherboard BIOS.  Neither of these things applies to
sparc.

Stop reserving the System ROM and Video ROM regions in PCI space.

Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Acked-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Bjorn Helgaas 2018-02-15 15:07:39 -06:00
parent b4a304489e
commit 3758a19111
1 changed files with 0 additions and 20 deletions

View File

@ -344,26 +344,6 @@ static void pci_register_legacy_regions(struct resource *io_res,
p->end = p->start + 0x1ffffUL;
p->flags = IORESOURCE_BUSY;
request_resource(mem_res, p);
p = kzalloc(sizeof(*p), GFP_KERNEL);
if (!p)
return;
p->name = "System ROM";
p->start = mem_res->start + 0xf0000UL;
p->end = p->start + 0xffffUL;
p->flags = IORESOURCE_BUSY;
request_resource(mem_res, p);
p = kzalloc(sizeof(*p), GFP_KERNEL);
if (!p)
return;
p->name = "Video ROM";
p->start = mem_res->start + 0xc0000UL;
p->end = p->start + 0x7fffUL;
p->flags = IORESOURCE_BUSY;
request_resource(mem_res, p);
}
static void pci_register_iommu_region(struct pci_pbm_info *pbm)