[kernel] r9931 - in dists/sid/linux-2.6/debian: . patches/bugfix/sparc patches/series
Maximilian Attems
maks at alioth.debian.org
Sun Dec 9 23:25:57 UTC 2007
Author: maks
Date: Sun Dec 9 23:25:57 2007
New Revision: 9931
Log:
[sparc] Add davem get_cpu() SunFire boot patch. (closes: #440720)
this will surely come through stable too..
Added:
dists/sid/linux-2.6/debian/patches/bugfix/sparc/sunfire-get_cpu.patch
Modified:
dists/sid/linux-2.6/debian/changelog
dists/sid/linux-2.6/debian/patches/series/2
Modified: dists/sid/linux-2.6/debian/changelog
==============================================================================
--- dists/sid/linux-2.6/debian/changelog (original)
+++ dists/sid/linux-2.6/debian/changelog Sun Dec 9 23:25:57 2007
@@ -12,8 +12,9 @@
[ maximilian attems ]
* [ppc] Reenable PMAC_BACKLIGHT.
+ * [sparc] Add davem get_cpu() SunFire boot patch. (closes: #440720)
- -- maximilian attems <maks at debian.org> Sat, 08 Dec 2007 11:22:06 +0100
+ -- maximilian attems <maks at debian.org> Mon, 10 Dec 2007 00:24:29 +0100
linux-2.6 (2.6.23-1) unstable; urgency=low
Added: dists/sid/linux-2.6/debian/patches/bugfix/sparc/sunfire-get_cpu.patch
==============================================================================
--- (empty file)
+++ dists/sid/linux-2.6/debian/patches/bugfix/sparc/sunfire-get_cpu.patch Sun Dec 9 23:25:57 2007
@@ -0,0 +1,67 @@
+Gitweb: http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=b332b8bc9c67165eabdfc7d10b4a2e4cc9f937d0
+Commit: b332b8bc9c67165eabdfc7d10b4a2e4cc9f937d0
+Parent: f194d132e4971111f85c18c96067acffb13cee6d
+Author: David S. Miller <davem at sunset.davemloft.net>
+AuthorDate: Fri Dec 7 00:58:55 2007 -0800
+Committer: David S. Miller <davem at sunset.davemloft.net>
+CommitDate: Fri Dec 7 01:10:14 2007 -0800
+
+ [SPARC64]: Fix memory controller register access when non-SMP.
+
+ get_cpu() always returns zero on non-SMP builds, but we
+ really want the physical cpu number in this code in order
+ to do the right thing.
+
+ Based upon a non-SMP kernel boot failure report from Bernd Zeimetz.
+
+ Signed-off-by: David S. Miller <davem at davemloft.net>
+---
+ arch/sparc64/kernel/chmc.c | 16 ++++++++++------
+ 1 files changed, 10 insertions(+), 6 deletions(-)
+
+diff --git a/arch/sparc64/kernel/chmc.c b/arch/sparc64/kernel/chmc.c
+index 777d345..6d4f02e 100644
+--- a/arch/sparc64/kernel/chmc.c
++++ b/arch/sparc64/kernel/chmc.c
+@@ -1,7 +1,6 @@
+-/* $Id: chmc.c,v 1.4 2002/01/08 16:00:14 davem Exp $
+- * memctrlr.c: Driver for UltraSPARC-III memory controller.
++/* memctrlr.c: Driver for UltraSPARC-III memory controller.
+ *
+- * Copyright (C) 2001 David S. Miller (davem at redhat.com)
++ * Copyright (C) 2001, 2007 David S. Miller (davem at davemloft.net)
+ */
+
+ #include <linux/module.h>
+@@ -16,6 +15,7 @@
+ #include <linux/init.h>
+ #include <asm/spitfire.h>
+ #include <asm/chmctrl.h>
++#include <asm/cpudata.h>
+ #include <asm/oplib.h>
+ #include <asm/prom.h>
+ #include <asm/io.h>
+@@ -242,8 +242,11 @@ int chmc_getunumber(int syndrome_code,
+ */
+ static u64 read_mcreg(struct mctrl_info *mp, unsigned long offset)
+ {
+- unsigned long ret;
+- int this_cpu = get_cpu();
++ unsigned long ret, this_cpu;
++
++ preempt_disable();
++
++ this_cpu = real_hard_smp_processor_id();
+
+ if (mp->portid == this_cpu) {
+ __asm__ __volatile__("ldxa [%1] %2, %0"
+@@ -255,7 +258,8 @@ static u64 read_mcreg(struct mctrl_info *mp, unsigned long offset)
+ : "r" (mp->regs + offset),
+ "i" (ASI_PHYS_BYPASS_EC_E));
+ }
+- put_cpu();
++
++ preempt_enable();
+
+ return ret;
+ }
Modified: dists/sid/linux-2.6/debian/patches/series/2
==============================================================================
--- dists/sid/linux-2.6/debian/patches/series/2 (original)
+++ dists/sid/linux-2.6/debian/patches/series/2 Sun Dec 9 23:25:57 2007
@@ -1,2 +1,3 @@
+ bugfix/arm/glantank-rtc.patch
+ features/all/export-gfs2-locking-symbols.patch
++ bugfix/sparc/sunfire-get_cpu.patch
More information about the Kernel-svn-changes
mailing list