Skip to content

Commit 06f2f68

Browse files
committed
genirq/generic-chip: Make locking unconditional
The SMP conditional wrappers around raw_spin_[un]lock() have no real value. On !SMP kernels the lock operations are NOOPs except for a preempt_disable/enable() pair on PREEMPT enabled kernels, which are not really worth to optimize for. Aside of that this evades lockdep on !SMP kernels. Remove the !SMP stubs and make it unconditional. No functional change. Signed-off-by: Thomas Gleixner <[email protected]> Link: https://lore.kernel.org/all/[email protected]
1 parent 1902a59 commit 06f2f68

File tree

1 file changed

+0
-5
lines changed

1 file changed

+0
-5
lines changed

include/linux/irq.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1222,7 +1222,6 @@ static inline struct irq_chip_type *irq_data_get_chip_type(struct irq_data *d)
12221222

12231223
#define IRQ_MSK(n) (u32)((n) < 32 ? ((1 << (n)) - 1) : UINT_MAX)
12241224

1225-
#ifdef CONFIG_SMP
12261225
static inline void irq_gc_lock(struct irq_chip_generic *gc)
12271226
{
12281227
raw_spin_lock(&gc->lock);
@@ -1232,10 +1231,6 @@ static inline void irq_gc_unlock(struct irq_chip_generic *gc)
12321231
{
12331232
raw_spin_unlock(&gc->lock);
12341233
}
1235-
#else
1236-
static inline void irq_gc_lock(struct irq_chip_generic *gc) { }
1237-
static inline void irq_gc_unlock(struct irq_chip_generic *gc) { }
1238-
#endif
12391234

12401235
/*
12411236
* The irqsave variants are for usage in non interrupt code. Do not use

0 commit comments

Comments
 (0)