EFI: warn only for pre-1.00 system tables
authorBjorn Helgaas <bjorn.helgaas@hp.com>
Tue, 8 May 2007 07:29:57 +0000 (00:29 -0700)
committerLinus Torvalds <torvalds@woody.linux-foundation.org>
Tue, 8 May 2007 18:15:10 +0000 (11:15 -0700)
We used to warn unless the EFI system table major revision was exactly 1.
But EFI 2.00 firmware is starting to appear, and the 2.00 changes don't
affect anything in Linux.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Andi Kleen <ak@suse.de>
Cc: "Luck, Tony" <tony.luck@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
arch/i386/kernel/efi.c
arch/ia64/hp/sim/boot/fw-emu.c
arch/ia64/kernel/efi.c
include/linux/efi.h

index dd9e7faafa7c787c8a006093228b3acd118f65f2..a1808022ea19bf6a5fab059c6cff765bdde3acfb 100644 (file)
@@ -347,14 +347,12 @@ void __init efi_init(void)
                printk(KERN_ERR PFX "Woah! Couldn't map the EFI system table.\n");
        if (efi.systab->hdr.signature != EFI_SYSTEM_TABLE_SIGNATURE)
                printk(KERN_ERR PFX "Woah! EFI system table signature incorrect\n");
-       if ((efi.systab->hdr.revision ^ EFI_SYSTEM_TABLE_REVISION) >> 16 != 0)
-               printk(KERN_ERR PFX
-                      "Warning: EFI system table major version mismatch: "
-                      "got %d.%02d, expected %d.%02d\n",
+       if ((efi.systab->hdr.revision >> 16) == 0)
+               printk(KERN_ERR PFX "Warning: EFI system table version "
+                      "%d.%02d, expected 1.00 or greater\n",
                       efi.systab->hdr.revision >> 16,
-                      efi.systab->hdr.revision & 0xffff,
-                      EFI_SYSTEM_TABLE_REVISION >> 16,
-                      EFI_SYSTEM_TABLE_REVISION & 0xffff);
+                      efi.systab->hdr.revision & 0xffff);
+
        /*
         * Grab some details from the system table
         */
index 5a0a7afcfc3a0ad010ceb29ff18a8618fdc81b4d..300acd913d9c5df9d7fa8aa396a58a6b71c2e9fa 100644 (file)
@@ -287,7 +287,7 @@ sys_fw_init (const char *args, int arglen)
 
        memset(efi_systab, 0, sizeof(efi_systab));
        efi_systab->hdr.signature = EFI_SYSTEM_TABLE_SIGNATURE;
-       efi_systab->hdr.revision  = EFI_SYSTEM_TABLE_REVISION;
+       efi_systab->hdr.revision  = ((1 << 16) | 00);
        efi_systab->hdr.headersize = sizeof(efi_systab->hdr);
        efi_systab->fw_vendor = __pa("H\0e\0w\0l\0e\0t\0t\0-\0P\0a\0c\0k\0a\0r\0d\0\0");
        efi_systab->fw_revision = 1;
index 78d29b79947dc3223a1e9c47e7975b71a90b5862..75ec3478d8a2c3aaf593810391e1d54a992fed1d 100644 (file)
@@ -445,11 +445,11 @@ efi_init (void)
                panic("Woah! Can't find EFI system table.\n");
        if (efi.systab->hdr.signature != EFI_SYSTEM_TABLE_SIGNATURE)
                panic("Woah! EFI system table signature incorrect\n");
-       if ((efi.systab->hdr.revision ^ EFI_SYSTEM_TABLE_REVISION) >> 16 != 0)
-               printk(KERN_WARNING "Warning: EFI system table major version mismatch: "
-                      "got %d.%02d, expected %d.%02d\n",
-                      efi.systab->hdr.revision >> 16, efi.systab->hdr.revision & 0xffff,
-                      EFI_SYSTEM_TABLE_REVISION >> 16, EFI_SYSTEM_TABLE_REVISION & 0xffff);
+       if ((efi.systab->hdr.revision >> 16) == 0)
+               printk(KERN_WARNING "Warning: EFI system table version "
+                      "%d.%02d, expected 1.00 or greater\n",
+                      efi.systab->hdr.revision >> 16,
+                      efi.systab->hdr.revision & 0xffff);
 
        config_tables = __va(efi.systab->tables);
 
index f8ebd7c1ddb3f40019fd2c14902c58ff14de23e3..0b9579a4cd424d03d95a6ba4a397ee22f4e23b3d 100644 (file)
@@ -213,7 +213,6 @@ typedef struct {
 } efi_config_table_t;
 
 #define EFI_SYSTEM_TABLE_SIGNATURE ((u64)0x5453595320494249ULL)
-#define EFI_SYSTEM_TABLE_REVISION  ((1 << 16) | 00)
 
 typedef struct {
        efi_table_hdr_t hdr;