]> git.baikalelectronics.ru Git - kernel.git/commit
drm/sun4i: dsi: Avoid hotplug race with DRM driver bind
authorSamuel Holland <samuel@sholland.org>
Mon, 17 Feb 2020 06:09:06 +0000 (00:09 -0600)
committerMaxime Ripard <maxime@cerno.tech>
Wed, 19 Feb 2020 15:56:57 +0000 (16:56 +0100)
commitff4b3e1da7d7a1f36cd28b8d6f3a84ba51d2cd91
tree4b6c8229d0153acc3955d27553f6803b81d37fe9
parent753fd3d9d6f190273223b855d39764018b3b5beb
drm/sun4i: dsi: Avoid hotplug race with DRM driver bind

We need to make sure that the DRM driver is fully registered before
allowing the panel to be attached. Otherwise, we may trigger a hotplug
event before sun4i_framebuffer_init() sets up drm->mode_config.funcs,
causing a NULL pointer dereference.

Fixes: e7a7c6b86dd7 ("drm/sun4i: dsi: Allow binding the host without a panel")
Signed-off-by: Samuel Holland <samuel@sholland.org>
Signed-off-by: Maxime Ripard <maxime@cerno.tech>
Link: https://patchwork.freedesktop.org/patch/msgid/20200217060906.15152-1-samuel@sholland.org
drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c