diff -urN linux-2.4.19-pre5-preempt/arch/i386/kernel/entry.S linux-2.4.19-pre5-preempt-multi-arch/arch/i386/kernel/entry.S --- linux-2.4.19-pre5-preempt/arch/i386/kernel/entry.S Mon Apr 1 01:00:33 2002 +++ linux-2.4.19-pre5-preempt-multi-arch/arch/i386/kernel/entry.S Mon Apr 1 01:05:04 2002 @@ -71,7 +71,8 @@ * these are offsets into the task-struct. */ state = 0 -preempt_count = 4 +/* flags = 4 when CONFIG_PREEMPT is not set, but is not used here */ +preempt_count = 4 /* only used if CONFIG_PREEMPT is set */ sigpending = 8 addr_limit = 12 exec_domain = 16 diff -urN linux-2.4.19-pre5-preempt/arch/sh/kernel/entry.S linux-2.4.19-pre5-preempt-multi-arch/arch/sh/kernel/entry.S --- linux-2.4.19-pre5-preempt/arch/sh/kernel/entry.S Mon Apr 1 01:00:33 2002 +++ linux-2.4.19-pre5-preempt-multi-arch/arch/sh/kernel/entry.S Mon Apr 1 01:06:45 2002 @@ -60,11 +60,15 @@ /* * These are offsets into the task-struct. */ -preempt_count = 4 +#ifdef CONFIG_PREEMPT +preempt_count = 4 /* preempt_count replaces flags */ +flags = 84 +#else +flags = 4 +#endif sigpending = 8 need_resched = 20 tsk_ptrace = 24 -flags = 84 /* * These offsets are into irq_stat. diff -urN linux-2.4.19-pre5-preempt/include/linux/sched.h linux-2.4.19-pre5-preempt-multi-arch/include/linux/sched.h --- linux-2.4.19-pre5-preempt/include/linux/sched.h Mon Apr 1 01:00:33 2002 +++ linux-2.4.19-pre5-preempt-multi-arch/include/linux/sched.h Mon Apr 1 01:01:44 2002 @@ -289,7 +289,11 @@ * offsets of these are hardcoded elsewhere - touch with care */ volatile long state; /* -1 unrunnable, 0 runnable, >0 stopped */ +#ifdef CONFIG_PREEMPT int preempt_count; /* 0 => preemptable, <0 => BUG */ +#else + unsigned long flags; +#endif int sigpending; mm_segment_t addr_limit; /* thread address space: 0-0xBFFFFFFF for user-thead @@ -331,7 +335,9 @@ struct mm_struct *active_mm; struct list_head local_pages; unsigned int allocation_order, nr_local_pages; +#ifdef CONFIG_PREEMPT unsigned long flags; +#endif /* task state */ struct linux_binfmt *binfmt;