diff options
author | Steve Wilkins <steve.wilkins@raymarine.com> | 2024-07-15 12:13:54 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2024-07-15 19:08:17 +0100 |
commit | de9850b5c606b754dd7861678d6e2874b96b04f8 (patch) | |
tree | 6839a9ac1fd45e9dc3d911ceeb1d3e4ae1cc234e /drivers/cdx | |
parent | 22fd98c107c792e35db7abe45298bc3a29bf4723 (diff) | |
download | linux-de9850b5c606b754dd7861678d6e2874b96b04f8.tar.gz linux-de9850b5c606b754dd7861678d6e2874b96b04f8.tar.bz2 linux-de9850b5c606b754dd7861678d6e2874b96b04f8.zip |
spi: microchip-core: only disable SPI controller when register value change requires it
Setting up many of the registers for a new SPI transfer involves
unconditionally disabling the SPI controller, writing the register
value and re-enabling the controller. This is being done for registers
even when the value is unchanged and is also done for registers that
don't require the controller to be disabled for the change to take
effect. Make an effort to detect changes to the register values, and
only disables the controller if the new register value is different
and disabling the controller is required. This stops the controller
being repeated disabled and the bus going tristate before every
transfer.
Fixes: 9ac8d17694b6 ("spi: add support for microchip fpga spi controllers")
Signed-off-by: Steve Wilkins <steve.wilkins@raymarine.com>
Co-developed-by: Conor Dooley <conor.dooley@microchip.com>
Signed-off-by: Conor Dooley <conor.dooley@microchip.com>
Link: https://patch.msgid.link/20240715-depict-twirl-7e592eeabaad@wendy
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/cdx')
0 files changed, 0 insertions, 0 deletions