Skip to content

Commit fa7d81b

Browse files
ickledanvet
authored andcommitted
drm/fb-helper: Reduce READ_ONCE(master) to lockless_dereference
We are only documenting that the read is outside of the lock, and do not require strict ordering on the operation. In this case the more relaxed lockless_dereference() will suffice. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Daniel Vetter <daniel.vetter@intel.com> Cc: Julia Lawall <julia.lawall@lip6.fr> Cc: Chris Wilson <chris@chris-wilson.co.uk> Cc: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1466581572-16608-1-git-send-email-chris@chris-wilson.co.uk
1 parent 366e292 commit fa7d81b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/gpu/drm/drm_fb_helper.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -464,7 +464,7 @@ static bool drm_fb_helper_is_bound(struct drm_fb_helper *fb_helper)
464464

465465
/* Sometimes user space wants everything disabled, so don't steal the
466466
* display if there's a master. */
467-
if (READ_ONCE(dev->master))
467+
if (lockless_dereference(dev->master))
468468
return false;
469469

470470
drm_for_each_crtc(crtc, dev) {

0 commit comments

Comments
 (0)