mirror of
https://github.com/raspberrypi/linux.git
synced 2025-12-06 10:00:17 +00:00
drm/vc4: plane: Use return variable in atomic_check
The vc4_plane_atomic_check() directly returns the result of the final function it calls. Using the already defined ret variable to check its content on error, and a separate return 0 on success, makes it easier to extend. Signed-off-by: Maxime Ripard <maxime@cerno.tech>
This commit is contained in:
committed by
Dom Cobley
parent
10c85da3ad
commit
b511944a24
@@ -1378,7 +1378,11 @@ static int vc4_plane_atomic_check(struct drm_plane *plane,
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
return vc4_plane_allocate_lbm(new_plane_state);
|
||||
ret = vc4_plane_allocate_lbm(new_plane_state);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void vc4_plane_atomic_update(struct drm_plane *plane,
|
||||
|
||||
Reference in New Issue
Block a user