]>
Commit | Line | Data |
---|---|---|
cc90b958 BS |
1 | From: Greg Kroah-Hartman <gregkh@suse.de> |
2 | Subject: Linux 2.6.27.6 | |
3 | ||
4 | Upstream 2.6.27.6 release from kernel.org | |
5 | ||
6 | Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> | |
7 | ||
8 | Automatically created from "patches.kernel.org/patch-2.6.27.5-6" by xen-port-patches.py | |
9 | ||
10 | Index: head-2008-11-17/arch/x86/Kconfig | |
11 | =================================================================== | |
12 | --- head-2008-11-17.orig/arch/x86/Kconfig 2008-11-18 16:18:56.000000000 +0100 | |
13 | +++ head-2008-11-17/arch/x86/Kconfig 2008-11-18 16:19:14.000000000 +0100 | |
14 | @@ -1143,6 +1143,7 @@ config HIGHPTE | |
15 | config X86_RESERVE_LOW_64K | |
16 | bool "Reserve low 64K of RAM on AMI/Phoenix BIOSen" | |
17 | default y | |
18 | + depends on !XEN | |
19 | help | |
20 | Reserve the first 64K of physical RAM on BIOSes that are known | |
21 | to potentially corrupt that memory range. A numbers of BIOSes are | |
22 | Index: head-2008-11-17/arch/x86/kernel/setup-xen.c | |
23 | =================================================================== | |
24 | --- head-2008-11-17.orig/arch/x86/kernel/setup-xen.c 2008-11-17 13:42:08.000000000 +0100 | |
25 | +++ head-2008-11-17/arch/x86/kernel/setup-xen.c 2008-11-17 13:55:53.000000000 +0100 | |
26 | @@ -645,6 +645,41 @@ static struct x86_quirks default_x86_qui | |
27 | ||
28 | struct x86_quirks *x86_quirks __initdata = &default_x86_quirks; | |
29 | ||
30 | +#ifdef CONFIG_X86_RESERVE_LOW_64K | |
31 | +static int __init dmi_low_memory_corruption(const struct dmi_system_id *d) | |
32 | +{ | |
33 | + printk(KERN_NOTICE | |
34 | + "%s detected: BIOS may corrupt low RAM, working it around.\n", | |
35 | + d->ident); | |
36 | + | |
37 | + e820_update_range(0, 0x10000, E820_RAM, E820_RESERVED); | |
38 | + sanitize_e820_map(e820.map, ARRAY_SIZE(e820.map), &e820.nr_map); | |
39 | + | |
40 | + return 0; | |
41 | +} | |
42 | +#endif | |
43 | + | |
44 | +/* List of systems that have known low memory corruption BIOS problems */ | |
45 | +static struct dmi_system_id __initdata bad_bios_dmi_table[] = { | |
46 | +#ifdef CONFIG_X86_RESERVE_LOW_64K | |
47 | + { | |
48 | + .callback = dmi_low_memory_corruption, | |
49 | + .ident = "AMI BIOS", | |
50 | + .matches = { | |
51 | + DMI_MATCH(DMI_BIOS_VENDOR, "American Megatrends Inc."), | |
52 | + }, | |
53 | + }, | |
54 | + { | |
55 | + .callback = dmi_low_memory_corruption, | |
56 | + .ident = "Phoenix BIOS", | |
57 | + .matches = { | |
58 | + DMI_MATCH(DMI_BIOS_VENDOR, "Phoenix Technologies, LTD"), | |
59 | + }, | |
60 | + }, | |
61 | +#endif | |
62 | + {} | |
63 | +}; | |
64 | + | |
65 | /* | |
66 | * Determine if we were loaded by an EFI loader. If so, then we have also been | |
67 | * passed the efi memmap, systab, etc., so we should use these data structures | |
68 | @@ -819,6 +854,11 @@ void __init setup_arch(char **cmdline_p) | |
69 | ||
70 | finish_e820_parsing(); | |
71 | ||
72 | + if (is_initial_xendomain()) { | |
73 | + dmi_scan_machine(); | |
74 | + dmi_check_system(bad_bios_dmi_table); | |
75 | + } | |
76 | + | |
77 | #ifdef CONFIG_X86_32 | |
78 | probe_roms(); | |
79 | #endif | |
80 | @@ -922,9 +962,6 @@ void __init setup_arch(char **cmdline_p) | |
81 | vsmp_init(); | |
82 | #endif | |
83 | ||
84 | - if (is_initial_xendomain()) | |
85 | - dmi_scan_machine(); | |
86 | - | |
87 | io_delay_init(); | |
88 | ||
89 | #ifdef CONFIG_ACPI |