diff options
| author | Andrew Morton <akpm@digeo.com> | 2002-10-29 23:23:34 -0800 |
|---|---|---|
| committer | Linus Torvalds <torvalds@penguin.transmeta.com> | 2002-10-29 23:23:34 -0800 |
| commit | 706489d8a6f1187875ebdb86a751b6d77d1911e4 (patch) | |
| tree | 97879c4cdcbc8bd68c4f4345d3c918c1a1a7ce98 /include | |
| parent | c51fcfae69efd3af4df2f87c37409521ae69b3db (diff) | |
[PATCH] slab: extended cpu notifiers
Patch from Dipankar Sarma <dipankar@in.ibm.com>
This is Manfred's patch which provides a CPU_UP_PREPARE cpu notifier to
allow initialization of per_cpu data just before the cpu becomes fully
functional.
It also provides a facility for the CPU_UP_PREPARE handler to return
NOTIFY_BAD to signify that the CPU is not permitted to come up. If
that happens, a CPU_UP_CANCELLED message is passed to all the handlers.
The patch also fixes a bogus NOFITY_BAD return from the softirq setup
code.
Patch has been acked by Rusty.
We need this mechanism in slab for starting per-cpu timers and for
allocating the per-cpu slab hgead arrays *before* the CPU has come up
and started using slab.
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/notifier.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/include/linux/notifier.h b/include/linux/notifier.h index 05d2e7968646..f9638ff66bb9 100644 --- a/include/linux/notifier.h +++ b/include/linux/notifier.h @@ -60,7 +60,11 @@ extern int notifier_call_chain(struct notifier_block **n, unsigned long val, voi #define NETLINK_URELEASE 0x0001 /* Unicast netlink socket released */ -#define CPU_ONLINE 0x0002 /* CPU (unsigned)v coming up */ +#define CPU_ONLINE 0x0002 /* CPU (unsigned)v is up */ +#define CPU_UP_PREPARE 0x0003 /* CPU (unsigned)v coming up */ +#define CPU_UP_CANCELED 0x0004 /* CPU (unsigned)v NOT coming up */ +#define CPU_OFFLINE 0x0005 /* CPU (unsigned)v offline (still scheduling) */ +#define CPU_DEAD 0x0006 /* CPU (unsigned)v dead */ #endif /* __KERNEL__ */ #endif /* _LINUX_NOTIFIER_H */ |
