summaryrefslogtreecommitdiff
path: root/drivers/regulator
diff options
context:
space:
mode:
authorMark Brown <broonie@kernel.org>2026-09-25 18:44:47 +0100
committerMark Brown <broonie@kernel.org>2026-09-25 18:44:47 +0100
commit9048d2416b0923e88c07db585fd47034c6b95dad (patch)
tree0e67e482ea6dad8d47bbe40f8ca06e343fb08301 /drivers/regulator
parentb9205f0837ca91a0bbe6aa9002207656840c1406 (diff)
parent59951bd9c6b63d4d98539db96becef729ad60b4a (diff)
downloadlinux-next-9048d2416b0923e88c07db585fd47034c6b95dad.tar.gz
linux-next-9048d2416b0923e88c07db585fd47034c6b95dad.zip
regulator: Allow mtk-regulator-coupler to be built as a module
Justin Yeh <justin.yeh@mediatek.com> says: MTK_REGULATOR_COUPLER can currently only be built into the kernel: it is a bool, and its prompt is hidden unless COMPILE_TEST is set, so on real MediaTek configurations the symbol has no prompt and is forced to its "default ARCH_MEDIATEK" value. Kernels that ship nearly everything as a module (Android GKI style kernels, but distro kernels have the same shape) cannot use it that way. Two things are in the way: - the four helpers the coupler calls are declared in include/linux/regulator/coupler.h for coupler implementations to use, but none of them is exported (patch 1); - the Kconfig symbol is a bool without a usable prompt (patch 2). Link: https://patch.msgid.link/20260903062056.1024263-1-justin.yeh@mediatek.com
Diffstat (limited to 'drivers/regulator')
-rw-r--r--drivers/regulator/core.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c
index 50fe91b6f267..14422cfe80e2 100644
--- a/drivers/regulator/core.c
+++ b/drivers/regulator/core.c
@@ -462,6 +462,7 @@ int regulator_check_voltage(struct regulator_dev *rdev,
return 0;
}
+EXPORT_SYMBOL_GPL(regulator_check_voltage);
/* return 0 if the state is valid */
static int regulator_check_states(suspend_state_t state)
@@ -502,6 +503,7 @@ int regulator_check_consumers(struct regulator_dev *rdev,
return 0;
}
+EXPORT_SYMBOL_GPL(regulator_check_consumers);
/* current constraint check */
static int regulator_check_current_limit(struct regulator_dev *rdev,
@@ -4469,6 +4471,7 @@ int regulator_do_balance_voltage(struct regulator_dev *rdev,
out:
return ret;
}
+EXPORT_SYMBOL_GPL(regulator_do_balance_voltage);
static int regulator_balance_voltage(struct regulator_dev *rdev,
suspend_state_t state)
@@ -5798,6 +5801,7 @@ int regulator_coupler_register(struct regulator_coupler *coupler)
return 0;
}
+EXPORT_SYMBOL_GPL(regulator_coupler_register);
static struct regulator_coupler *
regulator_find_coupler(struct regulator_dev *rdev)