]> git.baikalelectronics.ru Git - kernel.git/commit
media: imx-jpeg: Leave a blank space before the configuration data
authorMing Qian <ming.qian@nxp.com>
Mon, 30 May 2022 07:48:37 +0000 (08:48 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 Aug 2022 12:23:20 +0000 (14:23 +0200)
commit5dd53c209ff1753a54648ba635a2d5023638ba16
treed9be85a1d9f360e316095886d141e49d9689725f
parente73fcbb31d47a45031e043cab0c08dc4f6d5fb34
media: imx-jpeg: Leave a blank space before the configuration data

[ Upstream commit 1a37be01ad9c796aca2d476b8b5cf491064179eb ]

There is a hardware bug that it will load
the first 128 bytes of configuration data twice,
it will led to some configure error.
so shift the configuration data 128 bytes,
and make the first 128 bytes all zero,
then hardware will load the 128 zero twice,
and ignore them as garbage.
then the configuration data can be loaded correctly

Fixes: d07d57ca19d16 ("media: imx-jpeg: Add V4L2 driver for i.MX8 JPEG Encoder/Decoder")
Signed-off-by: Ming Qian <ming.qian@nxp.com>
Reviewed-by: Mirela Rabulea <mirela.rabulea@nxp.com>
Reviewed-by: Tommaso Merciai <tommaso.merciai@amarulasolutions.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/media/platform/imx-jpeg/mxc-jpeg.c