DESCRIPTION: ---------------------------------------------- ## lnxi-patch-6 ## src/include/smp/spinlock.h src/cpu/x86/tsc/delay_tsc.c cpu_relax() gets called unconditionally.
DIFFSTAT: ----------------------------------------------- cpu/x86/tsc/delay_tsc.c | 4 ---- include/smp/spinlock.h | 1 + 2 files changed, 1 insertion(+), 4 deletions(-)
PATCH: -----------------------------------------------
Index: lnxi-merge/src/include/smp/spinlock.h =================================================================== --- lnxi-merge/src/include/smp/spinlock.h (revision 1105) +++ lnxi-merge/src/include/smp/spinlock.h (working copy) @@ -19,6 +19,7 @@ #define spin_unlock_wait(lock) do {} while(0) #define spin_lock(lock) do {} while(0) #define spin_unlock(lock) do {} while(0) +#define cpu_relax() do {} while(0) #endif
#endif /* SMP_SPINLOCK_H */ Index: lnxi-merge/src/cpu/x86/tsc/delay_tsc.c =================================================================== --- lnxi-merge/src/cpu/x86/tsc/delay_tsc.c (revision 1105) +++ lnxi-merge/src/cpu/x86/tsc/delay_tsc.c (working copy) @@ -159,11 +159,7 @@ count = rdtscll(); stop = clocks + count; while(stop > count) { -#ifdef CONFIG_SMP -#if CONFIG_SMP == 1 cpu_relax(); -#endif -#endif count = rdtscll(); } }
-----------------------------------------------
--jason--
-- Jason W. Schildt LinuxBIOS Software Engineer Linux Networx