aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c
diff options
context:
space:
mode:
authorJohn Stultz <[email protected]>2024-12-17 04:07:35 +0000
committerPeter Zijlstra <[email protected]>2024-12-20 14:31:21 +0000
commitabfdccd6af2b071951633e57d6322c46a1ea791f (patch)
treed852a162cbe01984b07795b714d31e39b6e85450 /drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c
parentMerge branch 'locking/urgent' (diff)
downloadkernel-abfdccd6af2b071951633e57d6322c46a1ea791f.tar.gz
kernel-abfdccd6af2b071951633e57d6322c46a1ea791f.zip
sched/wake_q: Add helper to call wake_up_q after unlock with preemption disabled
A common pattern seen when wake_qs are used to defer a wakeup until after a lock is released is something like: preempt_disable(); raw_spin_unlock(lock); wake_up_q(wake_q); preempt_enable(); So create some raw_spin_unlock*_wake() helper functions to clean this up. Applies on top of the fix I submitted here: https://lore.kernel.org/lkml/[email protected]/ NOTE: I recognise the unlock()/unlock_irq()/unlock_irqrestore() variants creates its own duplication, which we could use a macro to generate the similar functions, but I often dislike how those generation macros making finding the actual implementation harder, so I left the three functions as is. If folks would prefer otherwise, let me know and I'll switch it. Suggested-by: Peter Zijlstra <[email protected]> Signed-off-by: John Stultz <[email protected]> Signed-off-by: Peter Zijlstra (Intel) <[email protected]> Link: https://lkml.kernel.org/r/[email protected]
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c')
0 files changed, 0 insertions, 0 deletions