Fix handle-efi-roms.patch to actually use the copy it got from EFI
This commit is contained in:
parent
cc41f66d97
commit
61db236d13
|
@ -332,19 +332,25 @@ diff -ur linux-3.6.0-0.rc2.git2.1.fc18.x86_64/drivers/pci/pci.c ../kernel-3.5.fc
|
|||
diff -ur linux-3.6.0-0.rc2.git2.1.fc18.x86_64/drivers/pci/rom.c ../kernel-3.5.fc18.bak/linux-3.6.0-0.rc2.git2.1.fc18.x86_64/drivers/pci/rom.c
|
||||
--- linux-3.6.0-0.rc2.git2.1.fc18.x86_64/drivers/pci/rom.c 2012-07-21 16:58:29.000000000 -0400
|
||||
+++ ../kernel-3.5.fc18.bak/linux-3.6.0-0.rc2.git2.1.fc18.x86_64/drivers/pci/rom.c 2012-08-22 15:25:40.531244893 -0400
|
||||
@@ -126,6 +126,12 @@
|
||||
@@ -118,11 +118,17 @@ void __iomem *pci_map_rom(struct pci_dev *pdev, size_t *size)
|
||||
void __iomem *rom;
|
||||
|
||||
/*
|
||||
+ * Some devices may provide ROMs via a source other than the BAR
|
||||
+ */
|
||||
+ if (pdev->rom && pdev->romlen) {
|
||||
+ *size = pdev->romlen;
|
||||
+ return phys_to_virt(pdev->rom);
|
||||
+ /*
|
||||
* IORESOURCE_ROM_SHADOW set on x86, x86_64 and IA64 supports legacy
|
||||
* memory map if the VGA enable bit of the Bridge Control register is
|
||||
* set for embedded VGA.
|
||||
*/
|
||||
- if (res->flags & IORESOURCE_ROM_SHADOW) {
|
||||
+ } else if (res->flags & IORESOURCE_ROM_SHADOW) {
|
||||
/* primary video rom always starts here */
|
||||
start = (loff_t)0xC0000;
|
||||
*size = 0x20000; /* cover C000:0 through E000:0 */
|
||||
+ /*
|
||||
+ * Some devices may provide ROMs via a source other than the BAR
|
||||
+ */
|
||||
+ } else if (pdev->rom && pdev->romlen) {
|
||||
+ *size = pdev->romlen;
|
||||
+ return phys_to_virt(pdev->rom);
|
||||
} else {
|
||||
if (res->flags &
|
||||
(IORESOURCE_ROM_COPY | IORESOURCE_ROM_BIOS_COPY)) {
|
||||
@@ -219,7 +225,8 @@
|
||||
if (res->flags & (IORESOURCE_ROM_COPY | IORESOURCE_ROM_BIOS_COPY))
|
||||
return;
|
||||
|
|
Loading…
Reference in New Issue