mirror of
https://github.com/tbsdtv/linux_media.git
synced 2025-07-23 12:43:29 +02:00
irq_work: Optimize irq_work_single()
Trade one atomic op for a full memory barrier. Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Reviewed-by: Frederic Weisbecker <frederic@kernel.org>
This commit is contained in:
@@ -107,14 +107,14 @@ do { \
|
||||
current->irq_config = 0; \
|
||||
} while (0)
|
||||
|
||||
# define lockdep_irq_work_enter(__work) \
|
||||
# define lockdep_irq_work_enter(_flags) \
|
||||
do { \
|
||||
if (!(atomic_read(&__work->node.a_flags) & IRQ_WORK_HARD_IRQ))\
|
||||
if (!((_flags) & IRQ_WORK_HARD_IRQ)) \
|
||||
current->irq_config = 1; \
|
||||
} while (0)
|
||||
# define lockdep_irq_work_exit(__work) \
|
||||
# define lockdep_irq_work_exit(_flags) \
|
||||
do { \
|
||||
if (!(atomic_read(&__work->node.a_flags) & IRQ_WORK_HARD_IRQ))\
|
||||
if (!((_flags) & IRQ_WORK_HARD_IRQ)) \
|
||||
current->irq_config = 0; \
|
||||
} while (0)
|
||||
|
||||
|
Reference in New Issue
Block a user