drm/vc4: simplify the return expression of vc4_prepare_fb()
Simplify the return expression. Reported-by: Zeal Robot <zealci@zte.com.cn> Signed-off-by: Minghao Chi <chi.minghao@zte.com.cn> Signed-off-by: Maxime Ripard <maxime@cerno.tech> Link: https://patchwork.freedesktop.org/patch/msgid/20220429054945.3852039-1-chi.minghao@zte.com.cn
This commit is contained in:
parent
37f67d390d
commit
f2a28a83f6
1 changed files with 1 additions and 6 deletions
|
@ -1350,7 +1350,6 @@ static int vc4_prepare_fb(struct drm_plane *plane,
|
||||||
struct drm_plane_state *state)
|
struct drm_plane_state *state)
|
||||||
{
|
{
|
||||||
struct vc4_bo *bo;
|
struct vc4_bo *bo;
|
||||||
int ret;
|
|
||||||
|
|
||||||
if (!state->fb)
|
if (!state->fb)
|
||||||
return 0;
|
return 0;
|
||||||
|
@ -1362,11 +1361,7 @@ static int vc4_prepare_fb(struct drm_plane *plane,
|
||||||
if (plane->state->fb == state->fb)
|
if (plane->state->fb == state->fb)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
ret = vc4_bo_inc_usecnt(bo);
|
return vc4_bo_inc_usecnt(bo);
|
||||||
if (ret)
|
|
||||||
return ret;
|
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void vc4_cleanup_fb(struct drm_plane *plane,
|
static void vc4_cleanup_fb(struct drm_plane *plane,
|
||||||
|
|
Loading…
Add table
Reference in a new issue