/SPARTAN/trunk/include/smp/ipi.h |
---|
31,9 → 31,6 |
#ifdef __SMP__ |
extern void ipi_broadcast(int ipi); |
extern void ipi_broadcast_arch(int ipi); |
#else |
#define ipi_broadcast(x) ; |
#endif /* __SMP__ */ |
#endif |
/SPARTAN/trunk/src/smp/ipi.c |
---|
File deleted |
/SPARTAN/trunk/src/proc/thread.c |
---|
46,8 → 46,11 |
#include <time/clock.h> |
#include <list.h> |
#include <config.h> |
#ifdef __SMP__ |
#include <arch/interrupt.h> |
#include <smp/ipi.h> |
#include <arch/apic.h> |
#endif /* __SMP__ */ |
char *thread_states[] = {"Invalid", "Running", "Sleeping", "Ready", "Entering", "Exiting"}; |
119,11 → 122,13 |
spinlock_unlock(&nrdylock); |
spinlock_lock(&cpu->lock); |
if ((++cpu->nrdy) > avg) { |
if ((++cpu->nrdy) > avg && (config.cpu_active == config.cpu_count)) { |
/* |
* If there are idle halted CPU's, this will wake them up. |
*/ |
#ifdef __SMP__ |
ipi_broadcast(VECTOR_WAKEUP_IPI); |
#endif /* __SMP__ */ |
} |
spinlock_unlock(&cpu->lock); |
/SPARTAN/trunk/src/Makefile |
---|
24,8 → 24,7 |
synch/rwlock.c \ |
synch/mutex.c \ |
synch/semaphore.c \ |
synch/waitq.c \ |
smp/ipi.c |
synch/waitq.c |
ifdef DEBUG_SPINLOCK |
CFLAGS+=-D$(DEBUG_SPINLOCK) |
/SPARTAN/trunk/arch/ia32/src/smp/ipi.c |
---|
31,7 → 31,7 |
#include <smp/ipi.h> |
#include <arch/apic.h> |
void ipi_broadcast_arch(int ipi) |
void ipi_broadcast(int ipi) |
{ |
(void) l_apic_broadcast_custom_ipi((__u8) ipi); |
} |