]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
spi: rzv2h-rspi: avoid recomputing transfer frequency
authorCosmin Tanislav <cosmin-gabriel.tanislav.xa@renesas.com>
Wed, 19 Nov 2025 16:14:26 +0000 (18:14 +0200)
committerMark Brown <broonie@kernel.org>
Mon, 24 Nov 2025 14:10:42 +0000 (14:10 +0000)
commit88782493204512fcf4e020e2385bca3e3c5bd4c0
tree5a30e5153809282ad5c6d330a1b8d72e6d4cf0f4
parent1b7ce968ab2579702ea9dbc2fb599e540bbd8c88
spi: rzv2h-rspi: avoid recomputing transfer frequency

Renesas RZ/T2H (R9A09G077) and RZ/N2H (R9A09G087) SoCs have a more
complicated algorithm for calculating the optimal SPI transfer frequency
compared to RZ/V2H, as the clock from which the SPI frequency is
generated supports multiple dividers.

Cache the requested transfer frequency and skip calling
rzv2h_rspi_setup_clock() if it matches the last used one to prepare for
adding support for variable clock frequency handling.

Signed-off-by: Cosmin Tanislav <cosmin-gabriel.tanislav.xa@renesas.com>
Link: https://patch.msgid.link/20251119161434.595677-6-cosmin-gabriel.tanislav.xa@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi-rzv2h-rspi.c