Commit 2809648f authored by David Mosberger's avatar David Mosberger

ia64: Move irq_enter()/irq_exit() from hardirq.h to irq_ia64.c. The work

	done by these routines is very special and needs to be done
	at exactly the right time.  Removing it from the header-file
	reduces the risk of accidental misuse.  Other arch maintainers agree
	that this is the Right Thing to do.
parent 62bd4756
...@@ -57,6 +57,21 @@ __u8 isa_irq_to_vector_map[16] = { ...@@ -57,6 +57,21 @@ __u8 isa_irq_to_vector_map[16] = {
}; };
EXPORT_SYMBOL(isa_irq_to_vector_map); EXPORT_SYMBOL(isa_irq_to_vector_map);
static inline void
irq_enter (void)
{
preempt_count() += HARDIRQ_OFFSET;
}
static inline void
irq_exit (void)
{
preempt_count() -= IRQ_EXIT_OFFSET;
if (!in_interrupt() && local_softirq_pending())
do_softirq();
preempt_enable_no_resched();
}
int int
ia64_alloc_vector (void) ia64_alloc_vector (void)
{ {
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
#define _ASM_IA64_HARDIRQ_H #define _ASM_IA64_HARDIRQ_H
/* /*
* Copyright (C) 1998-2002 Hewlett-Packard Co * Modified 1998-2002, 2004 Hewlett-Packard Co
* David Mosberger-Tang <davidm@hpl.hp.com> * David Mosberger-Tang <davidm@hpl.hp.com>
*/ */
...@@ -86,8 +86,6 @@ ...@@ -86,8 +86,6 @@
#define hardirq_trylock() (!in_interrupt()) #define hardirq_trylock() (!in_interrupt())
#define hardirq_endlock() do { } while (0) #define hardirq_endlock() do { } while (0)
#define irq_enter() (preempt_count() += HARDIRQ_OFFSET)
#ifdef CONFIG_PREEMPT #ifdef CONFIG_PREEMPT
# include <linux/smp_lock.h> # include <linux/smp_lock.h>
# define in_atomic() ((preempt_count() & ~PREEMPT_ACTIVE) != kernel_locked()) # define in_atomic() ((preempt_count() & ~PREEMPT_ACTIVE) != kernel_locked())
...@@ -97,14 +95,6 @@ ...@@ -97,14 +95,6 @@
# define IRQ_EXIT_OFFSET HARDIRQ_OFFSET # define IRQ_EXIT_OFFSET HARDIRQ_OFFSET
#endif #endif
#define irq_exit() \
do { \
preempt_count() -= IRQ_EXIT_OFFSET; \
if (!in_interrupt() && local_softirq_pending()) \
do_softirq(); \
preempt_enable_no_resched(); \
} while (0)
#ifdef CONFIG_SMP #ifdef CONFIG_SMP
extern void synchronize_irq (unsigned int irq); extern void synchronize_irq (unsigned int irq);
#else #else
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment