diff options
author | Seung-Woo Kim <sw0312.kim@samsung.com> | 2014-07-28 04:15:22 -0400 |
---|---|---|
committer | Inki Dae <inki.dae@samsung.com> | 2014-08-04 00:39:27 -0400 |
commit | 9d1e25c9982b97f5f3f2b9c885e823ee58a9fb3d (patch) | |
tree | bb93f2c888e88cb7ddd6952a94a39b47b09e518b | |
parent | f1e716d8f89b5e4bfde73e50b59694c421173015 (diff) |
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>
-rw-r--r-- | drivers/gpu/drm/exynos/exynos_hdmi.c | 3 |
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) | |||
2521 | if (hdata->res.reg_hdmi_en) | 2521 | if (hdata->res.reg_hdmi_en) |
2522 | regulator_disable(hdata->res.reg_hdmi_en); | 2522 | regulator_disable(hdata->res.reg_hdmi_en); |
2523 | 2523 | ||
2524 | put_device(&hdata->hdmiphy_port->dev); | 2524 | if (hdata->hdmiphy_port) |
2525 | put_device(&hdata->hdmiphy_port->dev); | ||
2525 | put_device(&hdata->ddc_adpt->dev); | 2526 | put_device(&hdata->ddc_adpt->dev); |
2526 | 2527 | ||
2527 | pm_runtime_disable(&pdev->dev); | 2528 | pm_runtime_disable(&pdev->dev); |