mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-01-19 20:12:32 +00:00
Two fixups
- Fix a potential error pointer dereference by checking the return value of exynos_drm_crtc_get_by_type() function before accessing to crtc object. - Fix a wrong error checking in exynos_drm_dma.c modules, which was reported by Dan[1] [1] https://lore.kernel.org/all/33e52277-1349-472b-a55b-ab5c3462bfcf@moroto.mountain/ -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEENRKOoF7NhdPGpscnVzg0iQxDErgFAmVxRrkACgkQVzg0iQxD Erh+6A//flOVFtqI8xPWpiFqGzKCqvK7qWPwGeaCgyzeu9AJialfchCnqqDNUTKB SnyqMHLDUaYAAml4765ApjVzPSv+QHzGbRGrTOfARg6WggiReoqvVLm9+FajE97T QLBiHunH6D7WxKUZZ9V2fjKB1DU3qqU+Xpxn0yV0z0UMD2UjjQ/WnJB9142TBphl QK5qfSTG7zynWz/vPxIEe/cxZfEyVO9lUArp9DpX70VL4ptGcd3qjNTDisV1U2NF ArT3Ou/68qN4tITPzymORikU6b7Wfgim52Eewtz2AI/S7g4rR+2rhEB2ayp0OlRK gU8iRQDp1EJEysk/WuBg7VPaXeG9dbSjEkj0JgLPoSxMvKh1zvo83z9yu8nQimmY zHolHF+m95eFPQH2UINvz6QTMcPBWQnolafQDGAU9KDDyuZ9c8pXLWPtNBdTXiig HQTctfYWCEVOBastjj5srblLHPSDiGViE0lFbxKnX9RoxCXgvMaka3XoXqk6wKwl svyGJlHzDyTZO5Fpe52qwivOythcqqX7JsMSPuTSo/AotUH/9zEkINqURNJlwEgb KwUJ+QnZESb01nEWFVtPdqtyclXEI2oQGx13AHsMTVdOQXWYhV6bg7FucMUTurzC rgFJ/jJPx74SLbwKBbbdmmdKlfK7v3bmEIaJPOsGpQTPgn037Sk= =Abe4 -----END PGP SIGNATURE----- Merge tag 'exynos-drm-next-for-v6.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/daeinki/drm-exynos into drm-fixes Two fixups - Fix a potential error pointer dereference by checking the return value of exynos_drm_crtc_get_by_type() function before accessing to crtc object. - Fix a wrong error checking in exynos_drm_dma.c modules, which was reported by Dan[1] [1] https://lore.kernel.org/all/33e52277-1349-472b-a55b-ab5c3462bfcf@moroto.mountain/ Signed-off-by: Dave Airlie <airlied@redhat.com> From: Inki Dae <inki.dae@samsung.com> Link: https://patchwork.freedesktop.org/patch/msgid/20231207042223.2473706-1-inki.dae@samsung.com
This commit is contained in:
commit
b7b5a56ace
@ -107,18 +107,16 @@ int exynos_drm_register_dma(struct drm_device *drm, struct device *dev,
|
||||
return 0;
|
||||
|
||||
if (!priv->mapping) {
|
||||
void *mapping;
|
||||
void *mapping = NULL;
|
||||
|
||||
if (IS_ENABLED(CONFIG_ARM_DMA_USE_IOMMU))
|
||||
mapping = arm_iommu_create_mapping(&platform_bus_type,
|
||||
EXYNOS_DEV_ADDR_START, EXYNOS_DEV_ADDR_SIZE);
|
||||
else if (IS_ENABLED(CONFIG_IOMMU_DMA))
|
||||
mapping = iommu_get_domain_for_dev(priv->dma_dev);
|
||||
else
|
||||
mapping = ERR_PTR(-ENODEV);
|
||||
|
||||
if (IS_ERR(mapping))
|
||||
return PTR_ERR(mapping);
|
||||
if (!mapping)
|
||||
return -ENODEV;
|
||||
priv->mapping = mapping;
|
||||
}
|
||||
|
||||
|
@ -1861,6 +1861,8 @@ static int hdmi_bind(struct device *dev, struct device *master, void *data)
|
||||
return ret;
|
||||
|
||||
crtc = exynos_drm_crtc_get_by_type(drm_dev, EXYNOS_DISPLAY_TYPE_HDMI);
|
||||
if (IS_ERR(crtc))
|
||||
return PTR_ERR(crtc);
|
||||
crtc->pipe_clk = &hdata->phy_clk;
|
||||
|
||||
ret = hdmi_create_connector(encoder);
|
||||
|
Loading…
x
Reference in New Issue
Block a user