diff options
| author | Thomas Petazzoni <thomas.petazzoni@bootlin.com> | 2018-08-02 10:56:25 +0200 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-11-20 18:45:54 +0100 |
| commit | 6ae8c86ee4581d8a990f83b28363f7c6b8c927d6 (patch) | |
| tree | b40a1195856c4aa6d07c4d84f68bdde5a1842fe9 /include/linux | |
| parent | 6c7644ad22ae80398e86132ba9d4caa5fd71be88 (diff) | |
mtd: rawnand: marvell: use regmap_update_bits() for syscon access
[ Upstream commit 88aa3bbfc020d14b13d67af3f5c08aa992d82cd8 ]
The marvell_nfc_init() function fiddles with some bits of a system
controller on Armada 7K/8K. However, it does a read/modify/write
sequence on GENCONF_CLK_GATING_CTRL and GENCONF_ND_CLK_CTRL, which
isn't safe from a concurrency point of view, as the regmap lock isn't
taken accross the read/modify/write sequence. To solve this issue, use
regmap_update_bits().
While at it, since the "reg" variable is no longer needed for the
read/modify/write sequences, get rid of it for the regmap_write() to
GENCONF_SOC_DEVICE_MUX, and directly pass the value to be written as
argument.
Fixes: 02f26ecf8c772 ("mtd: nand: add reworked Marvell NAND controller driver")
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'include/linux')
0 files changed, 0 insertions, 0 deletions
