Merge branch 'linus' into x86/cleanups
authorIngo Molnar <mingo@elte.hu>
Sat, 8 Nov 2008 19:23:02 +0000 (20:23 +0100)
committerIngo Molnar <mingo@elte.hu>
Sat, 8 Nov 2008 19:23:02 +0000 (20:23 +0100)
arch/x86/Kconfig
arch/x86/ia32/ia32_signal.c
arch/x86/include/asm/bitops.h
arch/x86/include/asm/byteorder.h
arch/x86/include/asm/irq.h
arch/x86/mm/init_32.c

index 4cf0ab13d187a943f88afc1d9761c739fee41008..7bf10f9b25a3cf0929dfa3fe4002baa611eb551d 100644 (file)
@@ -239,21 +239,13 @@ config X86_FIND_SMP_CONFIG
        def_bool y
        depends on X86_MPPARSE || X86_VOYAGER
 
-if ACPI
 config X86_MPPARSE
-       def_bool y
-       bool "Enable MPS table"
+       bool "Enable MPS table" if ACPI
+       default y
        depends on X86_LOCAL_APIC
        help
          For old smp systems that do not have proper acpi support. Newer systems
          (esp with 64bit cpus) with acpi support, MADT and DSDT will override it
-endif
-
-if !ACPI
-config X86_MPPARSE
-       def_bool y
-       depends on X86_LOCAL_APIC
-endif
 
 choice
        prompt "Subarchitecture Type"
index 4bc02b23674b5dfaaf91e813fb2be320dc57cd23..e82ebd6522637f3cdca85c3ddb9dbca352026c06 100644 (file)
@@ -572,11 +572,6 @@ int ia32_setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info,
        regs->dx = (unsigned long) &frame->info;
        regs->cx = (unsigned long) &frame->uc;
 
-       /* Make -mregparm=3 work */
-       regs->ax = sig;
-       regs->dx = (unsigned long) &frame->info;
-       regs->cx = (unsigned long) &frame->uc;
-
        loadsegment(ds, __USER32_DS);
        loadsegment(es, __USER32_DS);
 
index 360010322711037f80040829acceed8de6a15f42..9fa9dcdf344baeb25ccfa79db6222b5aae470ba5 100644 (file)
@@ -168,7 +168,15 @@ static inline void __change_bit(int nr, volatile unsigned long *addr)
  */
 static inline void change_bit(int nr, volatile unsigned long *addr)
 {
-       asm volatile(LOCK_PREFIX "btc %1,%0" : ADDR : "Ir" (nr));
+       if (IS_IMMEDIATE(nr)) {
+               asm volatile(LOCK_PREFIX "xorb %1,%0"
+                       : CONST_MASK_ADDR(nr, addr)
+                       : "iq" ((u8)CONST_MASK(nr)));
+       } else {
+               asm volatile(LOCK_PREFIX "btc %1,%0"
+                       : BITOP_ADDR(addr)
+                       : "Ir" (nr));
+       }
 }
 
 /**
index e02ae2d89acf13936aad26502e485aa6ddae0b65..f110ad417df3e0121333cbb06564a492ef8be2c2 100644 (file)
@@ -4,26 +4,33 @@
 #include <asm/types.h>
 #include <linux/compiler.h>
 
-#ifdef __GNUC__
+#define __LITTLE_ENDIAN
 
-#ifdef __i386__
-
-static inline __attribute_const__ __u32 ___arch__swab32(__u32 x)
+static inline __attribute_const__ __u32 __arch_swab32(__u32 val)
 {
-#ifdef CONFIG_X86_BSWAP
-       asm("bswap %0" : "=r" (x) : "0" (x));
-#else
+#ifdef __i386__
+# ifdef CONFIG_X86_BSWAP
+       asm("bswap %0" : "=r" (val) : "0" (val));
+# else
        asm("xchgb %b0,%h0\n\t" /* swap lower bytes     */
            "rorl $16,%0\n\t"   /* swap words           */
            "xchgb %b0,%h0"     /* swap higher bytes    */
-           : "=q" (x)
-           : "0" (x));
+           : "=q" (val)
+           : "0" (val));
+# endif
+
+#else /* __i386__ */
+       asm("bswapl %0"
+           : "=r" (val)
+           : "0" (val));
 #endif
-       return x;
+       return val;
 }
+#define __arch_swab32 __arch_swab32
 
-static inline __attribute_const__ __u64 ___arch__swab64(__u64 val)
+static inline __attribute_const__ __u64 __arch_swab64(__u64 val)
 {
+#ifdef __i386__
        union {
                struct {
                        __u32 a;
@@ -32,50 +39,27 @@ static inline __attribute_const__ __u64 ___arch__swab64(__u64 val)
                __u64 u;
        } v;
        v.u = val;
-#ifdef CONFIG_X86_BSWAP
+# ifdef CONFIG_X86_BSWAP
        asm("bswapl %0 ; bswapl %1 ; xchgl %0,%1"
            : "=r" (v.s.a), "=r" (v.s.b)
            : "0" (v.s.a), "1" (v.s.b));
-#else
-       v.s.a = ___arch__swab32(v.s.a);
-       v.s.b = ___arch__swab32(v.s.b);
+# else
+       v.s.a = __arch_swab32(v.s.a);
+       v.s.b = __arch_swab32(v.s.b);
        asm("xchgl %0,%1"
            : "=r" (v.s.a), "=r" (v.s.b)
            : "0" (v.s.a), "1" (v.s.b));
-#endif
+# endif
        return v.u;
-}
-
 #else /* __i386__ */
-
-static inline __attribute_const__ __u64 ___arch__swab64(__u64 x)
-{
        asm("bswapq %0"
-           : "=r" (x)
-           : "0" (x));
-       return x;
-}
-
-static inline __attribute_const__ __u32 ___arch__swab32(__u32 x)
-{
-       asm("bswapl %0"
-           : "=r" (x)
-           : "0" (x));
-       return x;
-}
-
+           : "=r" (val)
+           : "0" (val));
+       return val;
 #endif
+}
+#define __arch_swab64 __arch_swab64
 
-/* Do not define swab16.  Gcc is smart enough to recognize "C" version and
-   convert it into rotation or exhange.  */
-
-#define __arch__swab64(x) ___arch__swab64(x)
-#define __arch__swab32(x) ___arch__swab32(x)
-
-#define __BYTEORDER_HAS_U64__
-
-#endif /* __GNUC__ */
-
-#include <linux/byteorder/little_endian.h>
+#include <linux/byteorder.h>
 
 #endif /* _ASM_X86_BYTEORDER_H */
index bae0eda954864aa62e90b6ec438b82c8785129dc..28e409fc73f3df33e4c6b2cbde5e99e0433e0fa1 100644 (file)
@@ -31,10 +31,6 @@ static inline int irq_canonicalize(int irq)
 # endif
 #endif
 
-#ifdef CONFIG_IRQBALANCE
-extern int irqbalance_disable(char *str);
-#endif
-
 #ifdef CONFIG_HOTPLUG_CPU
 #include <linux/cpumask.h>
 extern void fixup_irqs(cpumask_t map);
index c483f424207938cc16ff3a2eb6b92eee5175e6b5..3ffed259883e2bd95c467222280be9fe8a770da2 100644 (file)
@@ -102,6 +102,8 @@ static pmd_t * __init one_md_table_init(pgd_t *pgd)
                set_pgd(pgd, __pgd(__pa(pmd_table) | _PAGE_PRESENT));
                pud = pud_offset(pgd, 0);
                BUG_ON(pmd_table != pmd_offset(pud, 0));
+
+               return pmd_table;
        }
 #endif
        pud = pud_offset(pgd, 0);