]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
iio: filter: admv8818: Force initialization of SDO
authorSam Winchenbach <swinchenbach@arka.org>
Mon, 3 Feb 2025 13:34:34 +0000 (13:34 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 13 Mar 2025 12:02:16 +0000 (13:02 +0100)
commitaffe7249f9c17bb922415ea94e0bed68d3a3bbc1
tree5d09184aa81377f31a9d9614557ee6acf2e79eec
parent1b8f7a2caa7f9cdfd135e3f78eb9d7e36fb95083
iio: filter: admv8818: Force initialization of SDO

commit cc2c3540d9477a9931fb0fd851fcaeba524a5b35 upstream.

When a weak pull-up is present on the SDO line, regmap_update_bits fails
to write both the SOFTRESET and SDOACTIVE bits because it incorrectly
reads them as already set.

Since the soft reset disables the SDO line, performing a
read-modify-write operation on ADI_SPI_CONFIG_A to enable the SDO line
doesn't make sense. This change directly writes to the register instead
of using regmap_update_bits.

Fixes: f34fe888ad05 ("iio:filter:admv8818: add support for ADMV8818")
Signed-off-by: Sam Winchenbach <swinchenbach@arka.org>
Link: https://patch.msgid.link/SA1P110MB106904C961B0F3FAFFED74C0BCF5A@SA1P110MB1069.NAMP110.PROD.OUTLOOK.COM
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/iio/filter/admv8818.c