mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] cpufreq: sun50i: Handle boards with the allwinner,sun50i-a133 compatible
@ 2026-11-05  4:07 Rajan Yadav via B4 Relay
  0 siblings, 0 replies; only message in thread
From: Rajan Yadav via B4 Relay @ 2026-11-05  4:07 UTC (permalink / raw)
  To: Rafael J. Wysocki, Viresh Kumar, Yangtao Li, Chen-Yu Tsai,
	Jernej Skrabec, Samuel Holland, Andre Przywara
  Cc: linux-pm, linux-kernel, linux-arm-kernel, linux-sunxi, Rajan Yadav

From: Rajan Yadav <rajanyadav0307@gmail.com>

The Teclast P80 uses "allwinner,sun50i-a133" as its only SoC
compatible, as documented in the arm/sunxi.yaml binding. Neither the
sun50i cpufreq driver nor the cpufreq-dt-platdev blocklist lists it.
cpufreq-dt then probes on its own, finds only opp-microvolt-speedN
properties and fails:

  cpu cpu0: opp_parse_microvolt: opp-microvolt missing although OPP managing regulators
  cpu cpu0: _of_add_opp_table_v2: Failed to add OPP, -22
  cpu cpu0: OPP table can't be empty

so the board runs without CPU frequency scaling.

Add the compatible to both lists.

Tested on a KickPi K5C (A133) with its root compatible changed to
"allwinner,sun50i-a133" only: on v7.4-rc1 cpufreq fails as above, with
this change the sun50i driver probes and the A100 speed1 OPPs are used.
v6.18 fails the same way, also with "kickpi,k5c" listed first.

Claude Code (Anthropic) drafted this change and its message from my test
logs; I reviewed and tested it.

Fixes: 60b064eb82e6 ("arm64: dts: allwinner: A133: add basic support for Teclast P80 tablet")
Signed-off-by: Rajan Yadav <rajanyadav0307@gmail.com>
---
This fixes the Teclast P80 support added in v7.4-rc1, so I think it can
go in as a fix for 7.4. I do not have a Teclast P80; I reproduced the
failure on a KickPi K5C as described above. A series with A133 speed
grade support, which Andre asked for, follows separately.
---
 drivers/cpufreq/cpufreq-dt-platdev.c   | 1 +
 drivers/cpufreq/sun50i-cpufreq-nvmem.c | 1 +
 2 files changed, 2 insertions(+)

diff --git a/drivers/cpufreq/cpufreq-dt-platdev.c b/drivers/cpufreq/cpufreq-dt-platdev.c
index bce4c87573a..6bdeba47749 100644
--- a/drivers/cpufreq/cpufreq-dt-platdev.c
+++ b/drivers/cpufreq/cpufreq-dt-platdev.c
@@ -110,6 +110,7 @@ static const struct of_device_id blocklist[] __initconst = {
 	{ .compatible = "airoha,en7581", },
 
 	{ .compatible = "allwinner,sun50i-a100" },
+	{ .compatible = "allwinner,sun50i-a133", },
 	{ .compatible = "allwinner,sun50i-h6", },
 	{ .compatible = "allwinner,sun50i-h616", },
 	{ .compatible = "allwinner,sun50i-h618", },
diff --git a/drivers/cpufreq/sun50i-cpufreq-nvmem.c b/drivers/cpufreq/sun50i-cpufreq-nvmem.c
index 9261d148a16..5d4ff192e99 100644
--- a/drivers/cpufreq/sun50i-cpufreq-nvmem.c
+++ b/drivers/cpufreq/sun50i-cpufreq-nvmem.c
@@ -324,6 +324,7 @@ static struct platform_driver sun50i_cpufreq_driver = {
 static const struct of_device_id sun50i_cpufreq_match_list[] = {
 	{ .compatible = "allwinner,sun50i-h6" },
 	{ .compatible = "allwinner,sun50i-a100" },
+	{ .compatible = "allwinner,sun50i-a133" },
 	{ .compatible = "allwinner,sun50i-h616" },
 	{ .compatible = "allwinner,sun50i-h618" },
 	{ .compatible = "allwinner,sun50i-h700" },

---
base-commit: 6628e7d4c6b25c8d18f1345e3a20d21829aae7e4
change-id: 20261104-a133-fix-e77378091de4

Best regards,
--  
Rajan Yadav <rajanyadav0307@gmail.com>



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2026-11-05  4:07 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-05  4:07 [PATCH] cpufreq: sun50i: Handle boards with the allwinner,sun50i-a133 compatible Rajan Yadav via B4 Relay

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®