regulator: mtk-dvfsrc: Add support for MediaTek MT8196 DVFSRC

The MediaTek MT8196 Chromebook SoC features one DVFSRC regulator
with 6 voltage steps.

Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Link: https://patch.msgid.link/20250623120144.109359-5-angelogioacchino.delregno@collabora.com
Signed-off-by: Mark Brown <broonie@kernel.org>
pull/1279/head
AngeloGioacchino Del Regno 2025-06-23 14:01:44 +02:00 committed by Mark Brown
parent ae77b8e8b0
commit 024f39fff6
No known key found for this signature in database
GPG Key ID: 24D68B725D5487D0
1 changed files with 19 additions and 0 deletions

View File

@ -166,6 +166,24 @@ static const struct dvfsrc_regulator_pdata mt8195_data = {
.size = ARRAY_SIZE(mt8195_regulators),
};
static const unsigned int mt8196_voltages[] = {
575000,
600000,
650000,
725000,
825000,
875000,
};
static const struct regulator_desc mt8196_regulators[] = {
MTK_DVFSRC_VREG("dvfsrc-vcore", VCORE, mt8196_voltages),
};
static const struct dvfsrc_regulator_pdata mt8196_data = {
.descs = mt8196_regulators,
.size = ARRAY_SIZE(mt8196_regulators),
};
static int dvfsrc_vcore_regulator_probe(struct platform_device *pdev)
{
struct regulator_config config = { .dev = &pdev->dev };
@ -195,6 +213,7 @@ static const struct of_device_id mtk_dvfsrc_regulator_match[] = {
{ .compatible = "mediatek,mt8183-dvfsrc-regulator", .data = &mt8183_data },
{ .compatible = "mediatek,mt8192-dvfsrc-regulator", .data = &mt6873_data },
{ .compatible = "mediatek,mt8195-dvfsrc-regulator", .data = &mt8195_data },
{ .compatible = "mediatek,mt8196-dvfsrc-regulator", .data = &mt8196_data },
{ /* sentinel */ }
};
MODULE_DEVICE_TABLE(of, mtk_dvfsrc_regulator_match);