Messages in this thread Patch in this message | | | Date | Sun, 01 Aug 1999 15:59:51 +0200 | From | Artur Skawina <> | Subject | [PATCH] asm-i386/bugs.h HZ=100 and __init cleanup |
| |
diff -urNp --exclude-from /usr/src/lkdontdiff /img/linux-2.3.12/include/asm-i386/bugs.h linux-2.3.12as/include/asm-i386/bugs.h --- /img/linux-2.3.12/include/asm-i386/bugs.h Fri Jul 30 21:14:23 1999 +++ linux-2.3.12as/include/asm-i386/bugs.h Sun Aug 1 13:50:13 1999 @@ -23,17 +23,17 @@ #define CONFIG_BUGi386 -__initfunc(static void no_halt(char *s, int *ints)) +static void __init no_halt(char *s, int *ints) { boot_cpu_data.hlt_works_ok = 0; } -__initfunc(static void mca_pentium(char *s, int *ints)) +static void __init mca_pentium(char *s, int *ints) { mca_pentium_flag = 1; } -__initfunc(static void no_387(char *s, int *ints)) +static void __init no_387(char *s, int *ints) { boot_cpu_data.hard_math = 0; write_cr0(0xE | read_cr0()); @@ -41,10 +41,10 @@ __initfunc(static void no_387(char *s, i static char __initdata fpu_error = 0; -__initfunc(static void copro_timeout(void)) +static void __init copro_timeout(void) { fpu_error = 1; - timer_table[COPRO_TIMER].expires = jiffies+100; + timer_table[COPRO_TIMER].expires = jiffies+HZ; timer_active |= 1<<COPRO_TIMER; printk(KERN_ERR "387 failed: trying to reset\n"); send_sig(SIGFPE, current, 1); @@ -55,7 +55,7 @@ __initfunc(static void copro_timeout(voi static double __initdata x = 4195835.0; static double __initdata y = 3145727.0; -__initfunc(static void check_fpu(void)) +static void __init check_fpu(void) { unsigned short control_word; @@ -102,7 +102,7 @@ __initfunc(static void check_fpu(void)) * should get there first.. */ printk(KERN_INFO "Checking 386/387 coupling... "); - timer_table[COPRO_TIMER].expires = jiffies+50; + timer_table[COPRO_TIMER].expires = jiffies+HZ/2; timer_table[COPRO_TIMER].fn = copro_timeout; timer_active |= 1<<COPRO_TIMER; __asm__("clts ; fninit ; fnstcw %0 ; fwait":"=m" (*&control_word)); @@ -134,7 +134,7 @@ __initfunc(static void check_fpu(void)) printk("Hmm, FPU using exception 16 error reporting with FDIV bug.\n"); } -__initfunc(static void check_hlt(void)) +static void __init check_hlt(void) { printk(KERN_INFO "Checking 'hlt' instruction... "); if (!boot_cpu_data.hlt_works_ok) { @@ -150,7 +150,7 @@ __initfunc(static void check_hlt(void)) * machine even from user space. */ -__initfunc(static void check_popad(void)) +static void __init check_popad(void) { #ifndef CONFIG_X86_POPAD_OK int res, inp = (int) &res; @@ -183,7 +183,7 @@ __initfunc(static void check_popad(void) extern void vide(void); __asm__(".align 4\nvide: ret"); -__initfunc(static void check_amd_k6(void)) +static void __init check_amd_k6(void) { if (boot_cpu_data.x86_vendor == X86_VENDOR_AMD && boot_cpu_data.x86_model == 6 && @@ -229,7 +229,7 @@ __initfunc(static void check_amd_k6(void extern void trap_init_f00f_bug(void); -__initfunc(static void check_pentium_f00f(void)) +static void __init check_pentium_f00f(void) { /* * Pentium and Pentium MMX @@ -271,7 +271,7 @@ static inline int test_cyrix_52div(void) extern unsigned char Cx86_dir0_msb; /* exported HACK from cyrix_model() */ -__initfunc(static void check_cx686_cpuid(void)) +static void __init check_cx686_cpuid(void) { if (boot_cpu_data.cpuid_level == -1 && ((Cx86_dir0_msb == 5) || (Cx86_dir0_msb == 3))) { @@ -311,7 +311,7 @@ __initfunc(static void check_cx686_cpuid extern void calibrate_delay(void) __init; -__initfunc(static void check_cx686_slop(void)) +static void __init check_cx686_slop(void) { if (Cx86_dir0_msb == 3) { unsigned char ccr3, ccr5; @@ -339,7 +339,7 @@ __initfunc(static void check_cx686_slop( * PII and PPro exhibit this behavior too, but they have cpuid available. */ -__initfunc(static void check_cyrix_cpu(void)) +static void __init check_cyrix_cpu(void) { if ((boot_cpu_data.cpuid_level == -1) && (boot_cpu_data.x86 == 4) && test_cyrix_52div()) { @@ -354,7 +354,7 @@ __initfunc(static void check_cyrix_cpu(v * enable the workaround for it. */ -__initfunc(static void check_cyrix_coma(void)) +static void __init check_cyrix_coma(void) { } @@ -371,7 +371,7 @@ __initfunc(static void check_cyrix_coma( * reads from the APIC. */ -__initfunc(static void check_config(void)) +static void __init check_config(void) { /* * We'd better not be a i386 if we're configured to use some @@ -400,7 +400,7 @@ __initfunc(static void check_config(void #endif } -__initfunc(static void check_bugs(void)) +static void __init check_bugs(void) { check_cyrix_cpu(); identify_cpu(&boot_cpu_data);
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |