Skip to content

Commit 962f88b

Browse files
committed
drm/panthor: Drop the dev_enter/exit() sections in _irq_suspend/resume()
There's no reason for _irq_suspend/resume() to be called after the device has been unplugged, and keeping this dev_enter/exit() section in _irq_suspend() is turns _irq_suspend() into a NOP when called from the _unplug() functions, which we don't want. v3: - New patch Fixes: 5fe909c ("drm/panthor: Add the device logical block") Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com> Reviewed-by: Liviu Dudau <liviu.dudau@arm.com> Reviewed-by: Steven Price <steven.price@arm.com> Link: https://patchwork.freedesktop.org/patch/msgid/20240326111205.510019-3-boris.brezillon@collabora.com
1 parent 1de434e commit 962f88b

1 file changed

Lines changed: 4 additions & 13 deletions

File tree

drivers/gpu/drm/panthor/panthor_device.h

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -326,13 +326,8 @@ static inline void panthor_ ## __name ## _irq_suspend(struct panthor_irq *pirq)
326326
int cookie; \
327327
\
328328
pirq->mask = 0; \
329-
\
330-
if (drm_dev_enter(&pirq->ptdev->base, &cookie)) { \
331-
gpu_write(pirq->ptdev, __reg_prefix ## _INT_MASK, 0); \
332-
synchronize_irq(pirq->irq); \
333-
drm_dev_exit(cookie); \
334-
} \
335-
\
329+
gpu_write(pirq->ptdev, __reg_prefix ## _INT_MASK, 0); \
330+
synchronize_irq(pirq->irq); \
336331
atomic_set(&pirq->suspended, true); \
337332
} \
338333
\
@@ -342,12 +337,8 @@ static inline void panthor_ ## __name ## _irq_resume(struct panthor_irq *pirq, u
342337
\
343338
atomic_set(&pirq->suspended, false); \
344339
pirq->mask = mask; \
345-
\
346-
if (drm_dev_enter(&pirq->ptdev->base, &cookie)) { \
347-
gpu_write(pirq->ptdev, __reg_prefix ## _INT_CLEAR, mask); \
348-
gpu_write(pirq->ptdev, __reg_prefix ## _INT_MASK, mask); \
349-
drm_dev_exit(cookie); \
350-
} \
340+
gpu_write(pirq->ptdev, __reg_prefix ## _INT_CLEAR, mask); \
341+
gpu_write(pirq->ptdev, __reg_prefix ## _INT_MASK, mask); \
351342
} \
352343
\
353344
static int panthor_request_ ## __name ## _irq(struct panthor_device *ptdev, \

0 commit comments

Comments
 (0)