diff options
author | Bernard Zhao <bernard@vivo.com> | 2020-08-01 14:02:13 +0200 |
---|---|---|
committer | Sam Ravnborg <sam@ravnborg.org> | 2020-08-02 08:59:06 +0200 |
commit | c3ee8c65f63799b02e1fb828bac99fd5008fb565 (patch) | |
tree | 98d499bd08fe087dcd695457fb9ec22e4880912b /drivers/gpu/drm/panel/panel-samsung-ld9040.c | |
parent | drm/ttm: remove the init_mem_type callback (diff) | |
download | linux-c3ee8c65f63799b02e1fb828bac99fd5008fb565.tar.xz linux-c3ee8c65f63799b02e1fb828bac99fd5008fb565.zip |
drm/panel: remove return value of function drm_panel_add
The function "int drm_panel_add(struct drm_panel *panel)"
always returns 0, this return value is meaningless.
Also, there is no need to check return value which calls
"drm_panel_add and", error branch code will never run.
Signed-off-by: Bernard Zhao <bernard@vivo.com>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20200801120216.8488-1-bernard@vivo.com
Diffstat (limited to 'drivers/gpu/drm/panel/panel-samsung-ld9040.c')
-rw-r--r-- | drivers/gpu/drm/panel/panel-samsung-ld9040.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/gpu/drm/panel/panel-samsung-ld9040.c b/drivers/gpu/drm/panel/panel-samsung-ld9040.c index 9bb2e8c7934a..358168ed8355 100644 --- a/drivers/gpu/drm/panel/panel-samsung-ld9040.c +++ b/drivers/gpu/drm/panel/panel-samsung-ld9040.c @@ -354,7 +354,9 @@ static int ld9040_probe(struct spi_device *spi) drm_panel_init(&ctx->panel, dev, &ld9040_drm_funcs, DRM_MODE_CONNECTOR_DPI); - return drm_panel_add(&ctx->panel); + drm_panel_add(&ctx->panel); + + return 0; } static int ld9040_remove(struct spi_device *spi) |