summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/exynos/exynos_hdmi.c
diff options
context:
space:
mode:
authorSeung-Woo Kim2014-07-28 10:15:22 +0200
committerInki Dae2014-08-04 06:39:27 +0200
commit9d1e25c9982b97f5f3f2b9c885e823ee58a9fb3d (patch)
treebb93f2c888e88cb7ddd6952a94a39b47b09e518b /drivers/gpu/drm/exynos/exynos_hdmi.c
parentdrm/exynos: control blending of mixer graphic layer 0 (diff)
downloadkernel-qcow2-linux-9d1e25c9982b97f5f3f2b9c885e823ee58a9fb3d.tar.gz
kernel-qcow2-linux-9d1e25c9982b97f5f3f2b9c885e823ee58a9fb3d.tar.xz
kernel-qcow2-linux-9d1e25c9982b97f5f3f2b9c885e823ee58a9fb3d.zip
drm/exynos: hdmi: add null check for hdmiphy_port
The hdmiphy can be apb and hdmiphy_port can be null. So before accessing hdmiphy_port, it should be checked. Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com>
Diffstat (limited to 'drivers/gpu/drm/exynos/exynos_hdmi.c')
-rw-r--r--drivers/gpu/drm/exynos/exynos_hdmi.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/gpu/drm/exynos/exynos_hdmi.c b/drivers/gpu/drm/exynos/exynos_hdmi.c
index d08e00d1f4ed..562966db2aa1 100644
--- a/drivers/gpu/drm/exynos/exynos_hdmi.c
+++ b/drivers/gpu/drm/exynos/exynos_hdmi.c
@@ -2521,7 +2521,8 @@ static int hdmi_remove(struct platform_device *pdev)
if (hdata->res.reg_hdmi_en)
regulator_disable(hdata->res.reg_hdmi_en);
- put_device(&hdata->hdmiphy_port->dev);
+ if (hdata->hdmiphy_port)
+ put_device(&hdata->hdmiphy_port->dev);
put_device(&hdata->ddc_adpt->dev);
pm_runtime_disable(&pdev->dev);