Skip to content

Commit c5098b3

Browse files
committed
drm/vc4: Correct arithmetic for shifting between columns of SAND images
Commit 69dbba7 ("drm/vc4: Add algorithmic handling for SAND") lost a multiplication by the tile width when doing the pointer arithmetic for cropping off columns for vc6. Correct that computation. Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
1 parent 121c2c3 commit c5098b3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/gpu/drm/vc4/vc4_plane.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1992,7 +1992,7 @@ static int vc6_plane_mode_set(struct drm_plane *plane,
19921992

19931993
tile = src_x / pix_per_tile;
19941994

1995-
offsets[i] += pitch[i] * tile;
1995+
offsets[i] += pitch[i] * tile * tile_width;
19961996
offsets[i] += src_y / (i ? v_subsample : 1) * tile_width;
19971997
offsets[i] += x_off & ~(i ? 1 : 0);
19981998

0 commit comments

Comments
 (0)