]> www.infradead.org Git - users/jedix/linux-maple.git/commit
memory: ti-aemif: Create aemif_check_cs_timings()
authorBastien Curutchet <bastien.curutchet@bootlin.com>
Wed, 4 Dec 2024 09:43:14 +0000 (10:43 +0100)
committerKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Mon, 9 Dec 2024 19:37:02 +0000 (20:37 +0100)
commit2c7b585d19cc1a7185a3a0b58cb643d28fd19cc1
treecc59ccbd164626a24f71d6c21bf814a1d40914f0
parent30b4da67655469bf8d4b8ba7c001096a1e10c7bf
memory: ti-aemif: Create aemif_check_cs_timings()

aemif_calc_rate() checks the validity of a new computed timing against a
'max' value given as input. This isn't convenient if we want to check
the CS timing configuration somewhere else in the code.

Wrap the verification of all the chip select's timing configuration into a
single function to ease its exportation in upcoming patches.
Remove the validity check from aemif_calc_rate(). Also remove the no
longer used 'max' input and change the return type to u32.
Remove the check of the aemif_calc_rate()'s return value during
device-tree parsing as aemif_calc_rate() can't fail anymore.

Signed-off-by: Bastien Curutchet <bastien.curutchet@bootlin.com>
Reviewed-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/r/20241204094319.1050826-5-bastien.curutchet@bootlin.com
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
drivers/memory/ti-aemif.c