regulator: Use container_of_const() when all types are const
authorKrzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
Wed, 26 Nov 2025 16:58:44 +0000 (17:58 +0100)
committerMark Brown <broonie@kernel.org>
Wed, 26 Nov 2025 18:44:26 +0000 (18:44 +0000)
commitac1530cdea9846c6bff31827c0c4dffcbc186e6a
tree235a890000114aadedaf68f65c8d858cb7c3f525
parenta7d6255a0bf302c028ac680564633a6aac5f611d
regulator: Use container_of_const() when all types are const

Use container_of_const(), which is preferred over container_of(), when
the argument 'ptr' and returned pointer are already const, for better
code safety and readability.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
Link: https://patch.msgid.link/20251126-container-of-const-regulator-v1-1-eeec378144d4@oss.qualcomm.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/regulator/hi6421-regulator.c
drivers/regulator/hi6421v530-regulator.c
drivers/regulator/hi6421v600-regulator.c
drivers/regulator/max77650-regulator.c
drivers/regulator/mt6315-regulator.c
drivers/regulator/pf1550-regulator.c