rpms/kernel/F-8 linux-2.6-x86-64-fix-overlap-of-modules-and-fixmap-areas.patch, NONE, 1.1 linux-2.6-x86-fdiv-bug-detection-fix.patch, NONE, 1.1 kernel.spec, 1.516, 1.517

Chuck Ebbert cebbert at fedoraproject.org
Fri Aug 29 23:03:34 UTC 2008


Author: cebbert

Update of /cvs/pkgs/rpms/kernel/F-8
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv458

Modified Files:
	kernel.spec 
Added Files:
	linux-2.6-x86-64-fix-overlap-of-modules-and-fixmap-areas.patch 
	linux-2.6-x86-fdiv-bug-detection-fix.patch 
Log Message:
x86-64: fix overlap of modules and fixmap areas
x86: fdiv bug detection fix (#197455)

linux-2.6-x86-64-fix-overlap-of-modules-and-fixmap-areas.patch:

--- NEW FILE linux-2.6-x86-64-fix-overlap-of-modules-and-fixmap-areas.patch ---
From: Jan Beulich <jbeulich at novell.com>
Date: Thu, 31 Jul 2008 15:48:31 +0000 (+0100)
Subject: x86-64: fix overlap of modules and fixmap areas
X-Git-Tag: v2.6.27-rc4~52^2~4
X-Git-Url: http://git.kernel.org/?p=linux%2Fkernel%2Fgit%2Ftorvalds%2Flinux-2.6.git;a=commitdiff_plain;h=66d4bdf22b8652cda215e2653c8bbec7a767ed57

x86-64: fix overlap of modules and fixmap areas

Plus add a build time check so this doesn't go unnoticed again.

Signed-off-by: Jan Beulich <jbeulich at novell.com>
Signed-off-by: Ingo Molnar <mingo at elte.hu>
---

diff --git a/arch/x86/kernel/head64.c b/arch/x86/kernel/head64.c
index 1b318e9..9bfc4d7 100644
--- a/arch/x86/kernel/head64.c
+++ b/arch/x86/kernel/head64.c
@@ -88,6 +88,7 @@ void __init x86_64_start_kernel(char * real_mode_data)
 	BUILD_BUG_ON(!(MODULES_VADDR > __START_KERNEL));
 	BUILD_BUG_ON(!(((MODULES_END - 1) & PGDIR_MASK) ==
 				(__START_KERNEL & PGDIR_MASK)));
+	BUILD_BUG_ON(__fix_to_virt(__end_of_fixed_addresses) <= MODULES_END);
 
 	/* clear bss before set_intr_gate with early_idt_handler */
 	clear_bss();
diff --git a/include/asm-x86/pgtable_64.h b/include/asm-x86/pgtable_64.h
index ac5fff4..549144d 100644
--- a/include/asm-x86/pgtable_64.h
+++ b/include/asm-x86/pgtable_64.h
@@ -151,7 +151,7 @@ static inline void native_pgd_clear(pgd_t *pgd)
 #define VMALLOC_END      _AC(0xffffe1ffffffffff, UL)
 #define VMEMMAP_START	 _AC(0xffffe20000000000, UL)
 #define MODULES_VADDR    _AC(0xffffffffa0000000, UL)
-#define MODULES_END      _AC(0xfffffffffff00000, UL)
+#define MODULES_END      _AC(0xffffffffff000000, UL)
 #define MODULES_LEN   (MODULES_END - MODULES_VADDR)
 
 #ifndef __ASSEMBLY__

linux-2.6-x86-fdiv-bug-detection-fix.patch:

--- NEW FILE linux-2.6-x86-fdiv-bug-detection-fix.patch ---
From: Krzysztof Helt <krzysztof.h1 at wp.pl>
Date: Thu, 31 Jul 2008 21:43:44 +0000 (+0200)
Subject: x86: fdiv bug detection fix
X-Git-Tag: v2.6.27-rc3~51^2~10
X-Git-Url: http://git.kernel.org/?p=linux%2Fkernel%2Fgit%2Ftorvalds%2Flinux-2.6.git;a=commitdiff_plain;h=e0d22d03c06c4e2c194d7010bc1e4a972199f156

x86: fdiv bug detection fix

The fdiv detection code writes s32 integer into
the boot_cpu_data.fdiv_bug.
However, the boot_cpu_data.fdiv_bug is only char (s8)
field so the detection overwrites already set fields for
other bugs, e.g. the f00f bug field.

Use local s32 variable to receive result.

This is a partial fix to Bugzilla #9928  - fixes wrong
information about the f00f bug (tested) and probably
for coma bug (I have no cpu to test this).

Signed-off-by: Krzysztof Helt <krzysztof.h1 at wp.pl>
Cc: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Ingo Molnar <mingo at elte.hu>
---

diff --git a/arch/x86/kernel/cpu/bugs.c b/arch/x86/kernel/cpu/bugs.c
index c9b58a8..c8e315f 100644
--- a/arch/x86/kernel/cpu/bugs.c
+++ b/arch/x86/kernel/cpu/bugs.c
@@ -50,6 +50,8 @@ static double __initdata y = 3145727.0;
  */
 static void __init check_fpu(void)
 {
+	s32 fdiv_bug;
+
 	if (!boot_cpu_data.hard_math) {
 #ifndef CONFIG_MATH_EMULATION
 		printk(KERN_EMERG "No coprocessor found and no math emulation present.\n");
@@ -74,8 +76,10 @@ static void __init check_fpu(void)
 		"fistpl %0\n\t"
 		"fwait\n\t"
 		"fninit"
-		: "=m" (*&boot_cpu_data.fdiv_bug)
+		: "=m" (*&fdiv_bug)
 		: "m" (*&x), "m" (*&y));
+
+	boot_cpu_data.fdiv_bug = fdiv_bug;
 	if (boot_cpu_data.fdiv_bug)
 		printk("Hmm, FPU with FDIV bug.\n");
 }


Index: kernel.spec
===================================================================
RCS file: /cvs/pkgs/rpms/kernel/F-8/kernel.spec,v
retrieving revision 1.516
retrieving revision 1.517
diff -u -r1.516 -r1.517
--- kernel.spec	29 Aug 2008 20:38:22 -0000	1.516
+++ kernel.spec	29 Aug 2008 23:03:04 -0000	1.517
@@ -578,6 +578,8 @@
 Patch60: linux-2.6-x86-tune-generic.patch
 Patch75: linux-2.6-x86-debug-boot.patch
 Patch87: linux-2.6-x86-apic-dump-all-regs-v3.patch
+Patch88: linux-2.6-x86-64-fix-overlap-of-modules-and-fixmap-areas.patch
+Patch89: linux-2.6-x86-fdiv-bug-detection-fix.patch
 
 #ALSA
 
@@ -989,6 +991,10 @@
 #ApplyPatch linux-2.6-x86-debug-boot.patch
 # dump *PIC state at boot with apic=debug
 ApplyPatch linux-2.6-x86-apic-dump-all-regs-v3.patch
+#
+ApplyPatch linux-2.6-x86-64-fix-overlap-of-modules-and-fixmap-areas.patch
+# x86 f00f bug not handled properly (#197455)
+ApplyPatch linux-2.6-x86-fdiv-bug-detection-fix.patch
 
 #
 # PowerPC
@@ -1773,6 +1779,10 @@
 
 
 %changelog
+* Fri Aug 29 2008 Chuck Ebbert <cebbert at redhat.com> 2.6.26.3-7
+- x86-64: fix overlap of modules and fixmap areas
+- x86: fdiv bug detection fix (#197455)
+
 * Fri Aug 29 2008 Chuck Ebbert <cebbert at redhat.com> 2.6.26.3-6
 - Silence MMCONFIG printk during boot.
 




More information about the fedora-extras-commits mailing list