--- zzzz-none-000/linux-2.6.28.10/include/linux/hardirq.h 2009-05-02 18:54:43.000000000 +0000 +++ puma5-6360-529/linux-2.6.28.10/include/linux/hardirq.h 2009-10-15 12:29:26.000000000 +0000 @@ -72,6 +72,11 @@ #define in_softirq() (softirq_count()) #define in_interrupt() (irq_count()) +/*--- static inline int in_interrupt(void){ ---*/ + /*--- struct thread_info *t = (struct thread_info*)current_thread_info(); ---*/ + /*--- return (t->preempt_count) & (HARDIRQ_MASK | SOFTIRQ_MASK); ---*/ +/*--- } ---*/ + #if defined(CONFIG_PREEMPT) # define PREEMPT_INATOMIC_BASE kernel_locked() # define PREEMPT_CHECK_OFFSET 1 @@ -113,7 +118,7 @@ struct task_struct; #ifndef CONFIG_VIRT_CPU_ACCOUNTING -static inline void account_system_vtime(struct task_struct *tsk) +static inline void account_system_vtime(struct task_struct *tsk __attribute__ ((unused))) { } #endif