diff mbox series

[v3,1/8] firmware: smccc: Export revision soc_id function

Message ID 20240326114743.712167-2-andre.przywara@arm.com (mailing list archive)
State New
Delegated to: viresh kumar
Headers show
Series cpufreq: sun50i: Add Allwinner H616 support | expand

Commit Message

Andre Przywara March 26, 2024, 11:47 a.m. UTC
From: Martin Botka <martin.botka@somainline.org>

The "SoC ID revision" as provided via the SMCCC SOCID interface can be
valuable information for drivers, when certain functionality depends
on a die revision, for instance.
One example is the sun50i-cpufreq-nvmem driver, which needs this
information to determine the speed bin of the SoC.

Export the arm_smccc_get_soc_id_revision() function so that it can be
called by any driver.

Signed-off-by: Martin Botka <martin.botka@somainline.org>
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
---
 drivers/firmware/smccc/smccc.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Sudeep Holla March 26, 2024, 1:18 p.m. UTC | #1
On Tue, Mar 26, 2024 at 11:47:36AM +0000, Andre Przywara wrote:
> From: Martin Botka <martin.botka@somainline.org>
> 
> The "SoC ID revision" as provided via the SMCCC SOCID interface can be
> valuable information for drivers, when certain functionality depends
> on a die revision, for instance.
> One example is the sun50i-cpufreq-nvmem driver, which needs this
> information to determine the speed bin of the SoC.
> 
> Export the arm_smccc_get_soc_id_revision() function so that it can be
> called by any driver.
> 

Assuming sun50i cpufreq driver can be built as module,

Acked-by: Sudeep Holla <sudeep.holla@arm.com>
diff mbox series

Patch

diff --git a/drivers/firmware/smccc/smccc.c b/drivers/firmware/smccc/smccc.c
index db818f9dcb8ee..d670635914ecb 100644
--- a/drivers/firmware/smccc/smccc.c
+++ b/drivers/firmware/smccc/smccc.c
@@ -69,6 +69,7 @@  s32 arm_smccc_get_soc_id_revision(void)
 {
 	return smccc_soc_id_revision;
 }
+EXPORT_SYMBOL_GPL(arm_smccc_get_soc_id_revision);
 
 static int __init smccc_devices_init(void)
 {