drm: Protect fb_helper list manipulation with a mutex
authorChris Wilson <chris@chris-wilson.co.uk>
Tue, 29 Nov 2016 12:02:17 +0000 (12:02 +0000)
committerSean Paul <seanpaul@chromium.org>
Tue, 29 Nov 2016 20:52:32 +0000 (15:52 -0500)
commita53ca63502e62ca459de32821753c8227dc94197
tree215d63accb417972f11dc0f3654c6accd96c525e
parent64e94407fb5a4128636c2b15b38fa6e71a427228
drm: Protect fb_helper list manipulation with a mutex

Though we only walk the kernel_fb_helper_list inside a panic (or single
thread debugging), we still need to protect the list manipulation on
creating/removing a framebuffer device in order to prevent list
corruption.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Sean Paul <seanpaul@chromium.org>
Link: http://patchwork.freedesktop.org/patch/msgid/20161129120217.7344-3-chris@chris-wilson.co.uk
drivers/gpu/drm/drm_fb_helper.c