Skip to content

Commit 27d8e3d

Browse files
Bjorn HelgaasLinus Torvalds
authored andcommitted
[PATCH] DMI: only ioremap stuff we actually need
dmi_scan_machine() tries to ioremap 0x10000 (64K) bytes, even though it only looks at the first 32 bytes or so. If the SMBIOS table is near the end of a memory region, the ioremap() may fail when it shouldn't. This is in the efi_enabled path, so it really only affects ia64 at the moment. Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com> Cc: Matt Domsch <Matt_Domsch@dell.com> Cc: "Tolentino, Matthew E" <matthew.e.tolentino@intel.com> Cc: "Brown, Len" <len.brown@intel.com> Cc: Andi Kleen <ak@muc.de> Acked-by: "Luck, Tony" <tony.luck@intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
1 parent e9b0a07 commit 27d8e3d

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎arch/i386/kernel/dmi_scan.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ void __init dmi_scan_machine(void)
224224
* needed during early boot. This also means we can
225225
* iounmap the space when we're done with it.
226226
*/
227-
p = dmi_ioremap((unsigned long)efi.smbios, 0x10000);
227+
p = dmi_ioremap((unsigned long)efi.smbios, 32);
228228
if (p == NULL)
229229
goto out;
230230

0 commit comments

Comments
 (0)