patch-2.4.22 linux-2.4.22/arch/ppc/kernel/smp.c
Next file: linux-2.4.22/arch/ppc/kernel/softemu8xx.c
Previous file: linux-2.4.22/arch/ppc/kernel/signal.c
Back to the patch index
Back to the overall index
- Lines: 113
- Date:
2003-08-25 04:44:40.000000000 -0700
- Orig file:
linux-2.4.21/arch/ppc/kernel/smp.c
- Orig date:
2003-06-13 07:51:31.000000000 -0700
diff -urN linux-2.4.21/arch/ppc/kernel/smp.c linux-2.4.22/arch/ppc/kernel/smp.c
@@ -67,7 +67,7 @@
extern void __save_cpu_setup(void);
/* Since OpenPIC has only 4 IPIs, we use slightly different message numbers.
- *
+ *
* Make sure this matches openpic_request_IPIs in open_pic.c, or what shows up
* in /proc/interrupts will be wrong!!! --Troy */
#define PPC_MSG_CALL_FUNCTION 0
@@ -75,7 +75,7 @@
#define PPC_MSG_INVALIDATE_TLB 2
#define PPC_MSG_XMON_BREAK 3
-static inline void
+static inline void
smp_message_pass(int target, int msg, unsigned long data, int wait)
{
if (smp_ops){
@@ -84,7 +84,7 @@
}
}
-/*
+/*
* Common functions
*/
void smp_local_timer_interrupt(struct pt_regs * regs)
@@ -100,12 +100,12 @@
void smp_message_recv(int msg, struct pt_regs *regs)
{
atomic_inc(&ipi_recv);
-
+
switch( msg ) {
case PPC_MSG_CALL_FUNCTION:
smp_call_function_interrupt();
break;
- case PPC_MSG_RESCHEDULE:
+ case PPC_MSG_RESCHEDULE:
current->need_resched = 1;
break;
case PPC_MSG_INVALIDATE_TLB:
@@ -332,7 +332,7 @@
/* Backup CPU 0 state */
__save_cpu_setup();
-
+
/*
* only check for cpus we know exist. We keep the callin map
* with cpus at the bottom -- Cort
@@ -342,7 +342,7 @@
for (i = 1; i < cpu_nr; i++) {
int c;
struct pt_regs regs;
-
+
/* create a process for the processor */
/* only regs.msr is actually used, and 0 is OK for it */
memset(®s, 0, sizeof(struct pt_regs));
@@ -368,7 +368,7 @@
/* wake up cpus */
smp_ops->kick_cpu(i);
-
+
/*
* wait to see if the cpu made a callin (is actually up).
* use this value that I found through experimentation.
@@ -376,7 +376,7 @@
*/
for ( c = 10000; c && !cpu_callin_map[i] ; c-- )
udelay(100);
-
+
if ( cpu_callin_map[i] )
{
char buf[32];
@@ -394,7 +394,7 @@
/* Setup CPU 0 last (important) */
smp_ops->setup_cpu(0);
-
+
if (smp_num_cpus < 2)
smp_tb_synchronized = 1;
}
@@ -497,7 +497,7 @@
*/
if (!smp_tb_synchronized && smp_num_cpus == 2) {
unsigned long flags;
- __save_and_cli(flags);
+ __save_and_cli(flags);
smp_software_tb_sync(0);
__restore_flags(flags);
}
@@ -506,14 +506,14 @@
void __init smp_callin(void)
{
int cpu = current->processor;
-
+
smp_store_cpu_info(cpu);
smp_ops->setup_cpu(cpu);
set_dec(tb_ticks_per_jiffy);
cpu_online_map |= 1UL << cpu;
mb();
cpu_callin_map[cpu] = 1;
-
+
while(!smp_commenced)
barrier();
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)