diff options
| author | 2024-04-05 17:29:49 +0200 | |
|---|---|---|
| committer | 2024-04-15 09:05:38 +0800 | |
| commit | 49c13b4d2dd4a831225746e758893673f6ae961c (patch) | |
| tree | 0224fab4f5fcdd8749e917de8c680937db25ea19 /drivers/gpu/drm/lima/lima_gp.c | |
| parent | accel/qaic: mark debugfs stub functions as static inline (diff) | |
| download | wireguard-linux-49c13b4d2dd4a831225746e758893673f6ae961c.tar.xz wireguard-linux-49c13b4d2dd4a831225746e758893673f6ae961c.zip | |
drm/lima: add mask irq callback to gp and pp
This is needed because we want to reset those devices in device-agnostic
code such as lima_sched.
In particular, masking irqs will be useful before a hard reset to
prevent race conditions.
Signed-off-by: Erico Nunes <nunes.erico@gmail.com>
Signed-off-by: Qiang Yu <yuq825@gmail.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240405152951.1531555-2-nunes.erico@gmail.com
Diffstat (limited to 'drivers/gpu/drm/lima/lima_gp.c')
| -rw-r--r-- | drivers/gpu/drm/lima/lima_gp.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/gpu/drm/lima/lima_gp.c b/drivers/gpu/drm/lima/lima_gp.c index 6b354e2fb61d..e15295071533 100644 --- a/drivers/gpu/drm/lima/lima_gp.c +++ b/drivers/gpu/drm/lima/lima_gp.c @@ -233,6 +233,13 @@ static void lima_gp_task_mmu_error(struct lima_sched_pipe *pipe) lima_sched_pipe_task_done(pipe); } +static void lima_gp_task_mask_irq(struct lima_sched_pipe *pipe) +{ + struct lima_ip *ip = pipe->processor[0]; + + gp_write(LIMA_GP_INT_MASK, 0); +} + static int lima_gp_task_recover(struct lima_sched_pipe *pipe) { struct lima_ip *ip = pipe->processor[0]; @@ -365,6 +372,7 @@ int lima_gp_pipe_init(struct lima_device *dev) pipe->task_error = lima_gp_task_error; pipe->task_mmu_error = lima_gp_task_mmu_error; pipe->task_recover = lima_gp_task_recover; + pipe->task_mask_irq = lima_gp_task_mask_irq; return 0; } |
