mbox series

[v2,0/2] thermal: rcar_gen3: Improve reading calibration fuses

Message ID 20241120120336.1063979-1-niklas.soderlund+renesas@ragnatech.se (mailing list archive)
Headers show
Series thermal: rcar_gen3: Improve reading calibration fuses | expand

Message

Niklas Söderlund Nov. 20, 2024, 12:03 p.m. UTC
Hello,

This small series aims to remove the code duplication that was added
when adding support for Gen4 devices. The logic to read the calibration
fuses are identical for Gen3 and Gen4, but the registers are at
different offsets.

Patch 1/2 is a small drive-by patch which fixes a style issue of the
constants found when working on the fuses code. While patch 2/2 is the
real work removing the code duplication.

It is tested on both Gen3 and Gen4 boards, but as not all boards have
the fused calibration values and the driver fallback to hardcoded values
only Gen4 have really been tested as I don't have access to a Gen3 board
with fused calibration values.

See individual patches for changelog.

Niklas Söderlund (2):
  thermal: rcar_gen3: Use lowercase hex constants
  thermal: rcar_gen3: Reuse logic to read fuses on Gen3 and Gen4

 drivers/thermal/renesas/rcar_gen3_thermal.c | 95 +++++++++------------
 1 file changed, 39 insertions(+), 56 deletions(-)