diff options
author | Rob Clark <robdclark@chromium.org> | 2020-10-23 19:51:16 +0300 |
---|---|---|
committer | Rob Clark <robdclark@chromium.org> | 2020-11-05 03:00:56 +0300 |
commit | 77d205290aa944895cf7e8bea500b8fd95a6b05b (patch) | |
tree | b2cc8fd3c7501168fc7a0ce2077af832dc9b8b19 /drivers/gpu/drm/msm/msm_ringbuffer.h | |
parent | 77c406038e830a4b6219b14a116cd2a6ac9f4908 (diff) | |
download | linux-77d205290aa944895cf7e8bea500b8fd95a6b05b.tar.xz |
drm/msm: Protect ring->submits with it's own lock
One less place to rely on dev->struct_mutex.
Signed-off-by: Rob Clark <robdclark@chromium.org>
Reviewed-by: Jordan Crouse <jcrouse@codeaurora.org>
Reviewed-by: Kristian H. Kristensen <hoegsberg@google.com>
Signed-off-by: Rob Clark <robdclark@chromium.org>
Diffstat (limited to 'drivers/gpu/drm/msm/msm_ringbuffer.h')
-rw-r--r-- | drivers/gpu/drm/msm/msm_ringbuffer.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/gpu/drm/msm/msm_ringbuffer.h b/drivers/gpu/drm/msm/msm_ringbuffer.h index 4956d1bc5d0e..fe55d4a1aa16 100644 --- a/drivers/gpu/drm/msm/msm_ringbuffer.h +++ b/drivers/gpu/drm/msm/msm_ringbuffer.h @@ -39,7 +39,13 @@ struct msm_ringbuffer { int id; struct drm_gem_object *bo; uint32_t *start, *end, *cur, *next; + + /* + * List of in-flight submits on this ring. Protected by submit_lock. + */ struct list_head submits; + spinlock_t submit_lock; + uint64_t iova; uint32_t seqno; uint32_t hangcheck_fence; |