patch-2.4.19 linux-2.4.19/include/asm-mips64/smp.h
Next file: linux-2.4.19/include/asm-mips64/sn/addrs.h
Previous file: linux-2.4.19/include/asm-mips64/siginfo.h
Back to the patch index
Back to the overall index
- Lines: 66
- Date:
Fri Aug 2 17:39:45 2002
- Orig file:
linux-2.4.18/include/asm-mips64/smp.h
- Orig date:
Wed Jul 4 11:50:39 2001
diff -urN linux-2.4.18/include/asm-mips64/smp.h linux-2.4.19/include/asm-mips64/smp.h
@@ -6,7 +6,6 @@
* Copyright (C) 2000 - 2001 by Kanoj Sarcar (kanoj@sgi.com)
* Copyright (C) 2000 - 2001 by Silicon Graphics, Inc.
*/
-
#ifndef __ASM_SMP_H
#define __ASM_SMP_H
@@ -17,23 +16,6 @@
#include <linux/threads.h>
#include <linux/irq.h>
-#if 0
-struct cpuinfo_mips { /* XXX */
- unsigned long loops_per_sec;
- unsigned long last_asn;
- unsigned long *pgd_cache;
- unsigned long *pte_cache;
- unsigned long pgtable_cache_sz;
- unsigned long ipi_count;
- unsigned long irq_attempt[NR_IRQS];
- unsigned long smp_local_irq_count;
- unsigned long prof_multiplier;
- unsigned long prof_counter;
-} __attribute__((aligned(64)));
-
-extern struct cpuinfo_mips cpu_data[NR_CPUS];
-#endif
-
#define smp_processor_id() (current->processor)
#define PROC_CHANGE_PENALTY 20
@@ -51,12 +33,15 @@
#define NO_PROC_ID (-1)
+#define SMP_RESCHEDULE_YOURSELF 0x1 /* XXX braindead */
+#define SMP_CALL_FUNCTION 0x2
+
#if (NR_CPUS <= _MIPS_SZLONG)
typedef unsigned long cpumask_t;
#define CPUMASK_CLRALL(p) (p) = 0
-#define CPUMASK_SETB(p, bit) (p) |= 1 << (bit)
+#define CPUMASK_SETB(p, bit) (p) |= 1UL << (bit)
#define CPUMASK_CLRB(p, bit) (p) &= ~(1ULL << (bit))
#define CPUMASK_TSTB(p, bit) ((p) & (1ULL << (bit)))
@@ -85,4 +70,16 @@
#error cpumask macros only defined for 128p kernels
#endif
+struct call_data_struct {
+ void (*func)(void *);
+ void *info;
+ atomic_t started;
+ atomic_t finished;
+ int wait;
+};
+
+extern struct call_data_struct *call_data;
+
+extern cpumask_t cpu_online_map;
+
#endif /* __ASM_SMP_H */
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)