Patch "x86/efistub: Fix PCI ROM preservation in mixed mode" has been added to the 5.10-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    x86/efistub: Fix PCI ROM preservation in mixed mode

to the 5.10-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     x86-efistub-fix-pci-rom-preservation-in-mixed-mode.patch
and it can be found in the queue-5.10 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit b700848ab4d9b9d63c0fc2346ac1ccbfe0647892
Author: Mikel Rychliski <mikel@xxxxxxxxxx>
Date:   Wed Aug 23 17:51:58 2023 -0400

    x86/efistub: Fix PCI ROM preservation in mixed mode
    
    [ Upstream commit 8b94da92559f7e403dc7ab81937cc50f949ee2fd ]
    
    preserve_pci_rom_image() was accessing the romsize field in
    efi_pci_io_protocol_t directly instead of using the efi_table_attr()
    helper. This prevents the ROM image from being saved correctly during a
    mixed mode boot.
    
    Fixes: 2c3625cb9fa2 ("efi/x86: Fold __setup_efi_pci32() and __setup_efi_pci64() into one function")
    Signed-off-by: Mikel Rychliski <mikel@xxxxxxxxxx>
    Signed-off-by: Ard Biesheuvel <ardb@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/firmware/efi/libstub/x86-stub.c b/drivers/firmware/efi/libstub/x86-stub.c
index 5d0f1b1966fc6..9f998e6bff957 100644
--- a/drivers/firmware/efi/libstub/x86-stub.c
+++ b/drivers/firmware/efi/libstub/x86-stub.c
@@ -60,7 +60,7 @@ preserve_pci_rom_image(efi_pci_io_protocol_t *pci, struct pci_setup_rom **__rom)
 	rom->data.type	= SETUP_PCI;
 	rom->data.len	= size - sizeof(struct setup_data);
 	rom->data.next	= 0;
-	rom->pcilen	= pci->romsize;
+	rom->pcilen	= romsize;
 	*__rom = rom;
 
 	status = efi_call_proto(pci, pci.read, EfiPciIoWidthUint16,



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux