Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 12b05566 authored by Jacek Anaszewski's avatar Jacek Anaszewski Committed by Mauro Carvalho Chehab
Browse files

[media] s5p-jpeg: Initialize jpeg_addr fields to zero



JPEG codecs on Exynos4 and Exynos3250 SoCs utilize different number
of planes for storing the raw image data, depending on the format
of the image being processed. For the unused planes a random data
was being written to the related registers. Regardless of the fact
that this seemed not to be harmful, fix the issue for clarity reasons.

Reported-by: default avatarAndrzej Pietrasiewicz <andrzej.p@samsung.com>
Signed-off-by: default avatarJacek Anaszewski <j.anaszewski@samsung.com>
Signed-off-by: default avatarSylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@osg.samsung.com>
parent 7c15fd4b
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -1844,7 +1844,7 @@ static void exynos4_jpeg_set_img_addr(struct s5p_jpeg_ctx *ctx)
	struct s5p_jpeg *jpeg = ctx->jpeg;
	struct s5p_jpeg_fmt *fmt;
	struct vb2_buffer *vb;
	struct s5p_jpeg_addr jpeg_addr;
	struct s5p_jpeg_addr jpeg_addr = {};
	u32 pix_size, padding_bytes = 0;

	pix_size = ctx->cap_q.w * ctx->cap_q.h;
@@ -1945,7 +1945,7 @@ static void exynos3250_jpeg_set_img_addr(struct s5p_jpeg_ctx *ctx)
	struct s5p_jpeg *jpeg = ctx->jpeg;
	struct s5p_jpeg_fmt *fmt;
	struct vb2_buffer *vb;
	struct s5p_jpeg_addr jpeg_addr;
	struct s5p_jpeg_addr jpeg_addr = {};
	u32 pix_size;

	pix_size = ctx->cap_q.w * ctx->cap_q.h;