diff options
author | yt.shen@mediatek.com <yt.shen@mediatek.com> | 2017-06-16 22:02:16 +0800 |
---|---|---|
committer | CK Hu <ck.hu@mediatek.com> | 2017-06-27 17:34:53 +0800 |
commit | 5ac5895a84d92bd2b3db490f8ee242ccb4d77e96 (patch) | |
tree | 2331ee44a20c02678a3eb2f3ec88a98d67edccd8 /drivers/gpu/drm/mediatek/mtk_drm_drv.h | |
parent | 4a3bfb5c24306aa129c0de32e5d1ffb553a60a7c (diff) | |
download | linux-5ac5895a84d92bd2b3db490f8ee242ccb4d77e96.tar.gz linux-5ac5895a84d92bd2b3db490f8ee242ccb4d77e96.tar.bz2 linux-5ac5895a84d92bd2b3db490f8ee242ccb4d77e96.zip |
drm/mediatek: separate color module to fixup error memory reallocation
Previous patch (c5f228ef6c drm/mediatek: add *driver_data for different
hardware settings) calls devm_kfree() and then devm_kzalloc() to
reallocate color module data structure. But this reallocation cannnot
guarantee the new address is unchanged, but the caller will use the
old address, which is wrong.
Fix it by separate color module from general components, this patch
separate color module to independent files, like mtk_disp_ovl.c and
mtk_disp_rdma.c do
Fixes: c5f228ef6ccd ("drm/mediatek: add *driver_data for different hardware settings")
Signed-off-by: YT Shen <yt.shen@mediatek.com>
Tested-by: Bibby Hsieh <bibby.hsieh@mediatek.com>
Signed-off-by: CK Hu <ck.hu@mediatek>
Diffstat (limited to 'drivers/gpu/drm/mediatek/mtk_drm_drv.h')
-rw-r--r-- | drivers/gpu/drm/mediatek/mtk_drm_drv.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/drm/mediatek/mtk_drm_drv.h b/drivers/gpu/drm/mediatek/mtk_drm_drv.h index aef8747d810b..c3378c452c0a 100644 --- a/drivers/gpu/drm/mediatek/mtk_drm_drv.h +++ b/drivers/gpu/drm/mediatek/mtk_drm_drv.h @@ -59,6 +59,7 @@ struct mtk_drm_private { }; extern struct platform_driver mtk_ddp_driver; +extern struct platform_driver mtk_disp_color_driver; extern struct platform_driver mtk_disp_ovl_driver; extern struct platform_driver mtk_disp_rdma_driver; extern struct platform_driver mtk_dpi_driver; |