mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-29 23:53:55 +08:00
drm/exynos: fix wrong return check for platform_device_register_simple
platform_device_register_simple() never returns NULL, but IS_ERR_OR_NULL macro is used for checking return value in exynos drm driver. Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com>
This commit is contained in:
parent
5186fc5e8e
commit
1055f49e99
@ -388,7 +388,7 @@ static int __init exynos_drm_init(void)
|
|||||||
|
|
||||||
exynos_drm_pdev = platform_device_register_simple("exynos-drm", -1,
|
exynos_drm_pdev = platform_device_register_simple("exynos-drm", -1,
|
||||||
NULL, 0);
|
NULL, 0);
|
||||||
if (IS_ERR_OR_NULL(exynos_drm_pdev)) {
|
if (IS_ERR(exynos_drm_pdev)) {
|
||||||
ret = PTR_ERR(exynos_drm_pdev);
|
ret = PTR_ERR(exynos_drm_pdev);
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
@ -56,7 +56,7 @@ int exynos_platform_device_hdmi_register(void)
|
|||||||
|
|
||||||
exynos_drm_hdmi_pdev = platform_device_register_simple(
|
exynos_drm_hdmi_pdev = platform_device_register_simple(
|
||||||
"exynos-drm-hdmi", -1, NULL, 0);
|
"exynos-drm-hdmi", -1, NULL, 0);
|
||||||
if (IS_ERR_OR_NULL(exynos_drm_hdmi_pdev))
|
if (IS_ERR(exynos_drm_hdmi_pdev))
|
||||||
return PTR_ERR(exynos_drm_hdmi_pdev);
|
return PTR_ERR(exynos_drm_hdmi_pdev);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user