diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/asm-mips/bugs.h | 5 | ||||
-rw-r--r-- | include/asm-mips/delay.h | 6 |
2 files changed, 5 insertions, 6 deletions
diff --git a/include/asm-mips/bugs.h b/include/asm-mips/bugs.h index b14b961c210..9247c1b4ce0 100644 --- a/include/asm-mips/bugs.h +++ b/include/asm-mips/bugs.h @@ -8,12 +8,17 @@ #define _ASM_BUGS_H #include <linux/config.h> +#include <asm/cpu.h> +#include <asm/cpu-info.h> extern void check_bugs32(void); extern void check_bugs64(void); static inline void check_bugs(void) { + unsigned int cpu = smp_processor_id(); + + cpu_data[cpu].udelay_val = loops_per_jiffy; check_bugs32(); #ifdef CONFIG_64BIT check_bugs64(); diff --git a/include/asm-mips/delay.h b/include/asm-mips/delay.h index a606dbee041..e906382576e 100644 --- a/include/asm-mips/delay.h +++ b/include/asm-mips/delay.h @@ -15,8 +15,6 @@ #include <asm/compiler.h> -extern unsigned long loops_per_jiffy; - static inline void __delay(unsigned long loops) { if (sizeof(long) == 4) @@ -82,11 +80,7 @@ static inline void __udelay(unsigned long usecs, unsigned long lpj) __delay(usecs); } -#ifdef CONFIG_SMP #define __udelay_val cpu_data[smp_processor_id()].udelay_val -#else -#define __udelay_val loops_per_jiffy -#endif #define udelay(usecs) __udelay((usecs),__udelay_val) |