diff options
author | Boris Brezillon <boris.brezillon@collabora.com> | 2024-04-25 13:39:20 +0300 |
---|---|---|
committer | Boris Brezillon <boris.brezillon@collabora.com> | 2024-05-02 18:54:05 +0300 |
commit | be2d3e9d061552af6c50220ee7b7e76458a3080f (patch) | |
tree | 0a505aecbc1060626bb13eade83a7e9d3ce6e130 /drivers/gpu/drm/panthor | |
parent | 4a56c0ed5aa0bcbe1f5f7d755fb1fe1ebf48ae9c (diff) | |
download | linux-be2d3e9d061552af6c50220ee7b7e76458a3080f.tar.xz |
drm/panthor: Kill the faulty_slots variable in panthor_sched_suspend()
We can use upd_ctx.timedout_mask directly, and the faulty_slots update
in the flush_caches_failed situation is never used.
Suggested-by: Suggested-by: Steven Price <steven.price@arm.com>
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Steven Price <steven.price@arm.com>
Reviewed-by: Liviu Dudau <liviu.dudau@arm.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240425103920.826458-1-boris.brezillon@collabora.com
Diffstat (limited to 'drivers/gpu/drm/panthor')
-rw-r--r-- | drivers/gpu/drm/panthor/panthor_sched.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/drivers/gpu/drm/panthor/panthor_sched.c b/drivers/gpu/drm/panthor/panthor_sched.c index b3a51a6de523..8ec66dd47db3 100644 --- a/drivers/gpu/drm/panthor/panthor_sched.c +++ b/drivers/gpu/drm/panthor/panthor_sched.c @@ -2546,8 +2546,8 @@ void panthor_sched_suspend(struct panthor_device *ptdev) { struct panthor_scheduler *sched = ptdev->scheduler; struct panthor_csg_slots_upd_ctx upd_ctx; - u32 suspended_slots, faulty_slots; struct panthor_group *group; + u32 suspended_slots; u32 i; mutex_lock(&sched->lock); @@ -2566,10 +2566,9 @@ void panthor_sched_suspend(struct panthor_device *ptdev) csgs_upd_ctx_apply_locked(ptdev, &upd_ctx); suspended_slots &= ~upd_ctx.timedout_mask; - faulty_slots = upd_ctx.timedout_mask; - if (faulty_slots) { - u32 slot_mask = faulty_slots; + if (upd_ctx.timedout_mask) { + u32 slot_mask = upd_ctx.timedout_mask; drm_err(&ptdev->base, "CSG suspend failed, escalating to termination"); csgs_upd_ctx_init(&upd_ctx); @@ -2620,9 +2619,6 @@ void panthor_sched_suspend(struct panthor_device *ptdev) slot_mask &= ~BIT(csg_id); } - - if (flush_caches_failed) - faulty_slots |= suspended_slots; } for (i = 0; i < sched->csg_slot_count; i++) { |