]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
drm/panel: raspberrypi-touchscreen: Prevent double-free
authorMaxime Ripard <maxime@cerno.tech>
Tue, 20 Jul 2021 13:45:23 +0000 (15:45 +0200)
committerMaxime Ripard <maxime@cerno.tech>
Thu, 22 Jul 2021 09:37:03 +0000 (11:37 +0200)
The mipi_dsi_device allocated by mipi_dsi_device_register_full() is
already free'd on release.

Fixes: 2f733d6194bd ("drm/panel: Add support for the Raspberry Pi 7" Touchscreen.")
Signed-off-by: Maxime Ripard <maxime@cerno.tech>
Reviewed-by: Sam Ravnborg <sam@ravnborg.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20210720134525.563936-9-maxime@cerno.tech
drivers/gpu/drm/panel/panel-raspberrypi-touchscreen.c

index 2229f1af2ca8cbe57fef6c988e794ddc0fe2f56d..46029c5610c80814682a7c7fc32d1e2bf08ff42b 100644 (file)
@@ -447,7 +447,6 @@ static int rpi_touchscreen_remove(struct i2c_client *i2c)
        drm_panel_remove(&ts->base);
 
        mipi_dsi_device_unregister(ts->dsi);
-       kfree(ts->dsi);
 
        return 0;
 }