]> www.infradead.org Git - users/willy/pagecache.git/commit
regulator: core: let dt properties override driver init_data
authorJerome Brunet <jbrunet@baylibre.com>
Tue, 11 Feb 2025 15:48:06 +0000 (16:48 +0100)
committerMark Brown <broonie@kernel.org>
Tue, 11 Feb 2025 16:29:01 +0000 (16:29 +0000)
commit35e21de48e693af1dcfdbf2dc3d73dcfa3c8f2d9
tree49af6f3bb09526c8be7b2ac67050cc95fd074944
parentb0eddc21900fb44f8c5db95710479865e3700fbd
regulator: core: let dt properties override driver init_data

This reverts commit cd7a38c40b231350a3cd0fd774f4e6bb68c4b411.

When submitting the change above, it was thought that the origin of the
init_data should be a clear choice, from the driver or from DT but not
both.

It turns out some devices, such as qcom-msm8974-lge-nexus5-hammerhead,
relied on the old behaviour to override the init_data provided by the
driver, making it some kind of default if none is provided by the platform.

Using the init_data provided by the driver when it is present broke these
devices so revert the change to fixup the situation and add a comment
to make things a bit more clear

Reported-by: Luca Weiss <luca@lucaweiss.eu>
Closes: https://lore.kernel.org/lkml/5857103.DvuYhMxLoT@lucaweiss.eu
Fixes: cd7a38c40b23 ("regulator: core: do not silently ignore provided init_data")
Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>
Link: https://patch.msgid.link/20250211-regulator-init-data-fixup-v1-1-5ce1c6cff990@baylibre.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/regulator/core.c