]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
gpu: ipu-v3: image-convert: Fix input bytesperline for packed formats
authorSteve Longerbeam <slongerbeam@gmail.com>
Wed, 12 Jun 2019 01:16:56 +0000 (18:16 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 14 Jul 2019 06:09:42 +0000 (08:09 +0200)
commit858251f8dd6eb387470256a1d2ea7f78f82d2a9f
treeada8eb4df4bb5df7b0f3bc1d3d2ea7b613fd989e
parent955be60e0c2f3f4aae7b6e8819a5a8b234fbfa00
gpu: ipu-v3: image-convert: Fix input bytesperline for packed formats

[ Upstream commit bca4d70cf1b8f6478a711c448a3a1e47b794b162 ]

The input bytesperline calculation for packed pixel formats was
incorrect. The min/max clamping values must be multiplied by the
packed bits-per-pixel. This was causing corrupted converted images
when the input format was RGB4 (probably also other input packed
formats).

Fixes: d966e23d61a2c ("gpu: ipu-v3: image-convert: fix bytesperline
adjustment")

Reported-by: Harsha Manjula Mallikarjun <Harsha.ManjulaMallikarjun@in.bosch.com>
Suggested-by: Harsha Manjula Mallikarjun <Harsha.ManjulaMallikarjun@in.bosch.com>
Signed-off-by: Steve Longerbeam <slongerbeam@gmail.com>
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/ipu-v3/ipu-image-convert.c