summaryrefslogtreecommitdiffstats
path: root/drivers/power
diff options
context:
space:
mode:
authorLuca Weiss <luca@z3ntu.xyz>2021-11-18 22:02:05 +0100
committerSebastian Reichel <sebastian.reichel@collabora.com>2021-11-30 11:34:27 +0100
commit0838a3bfcd1b0c8d2ce38afcc94b81920486dabd (patch)
tree63835059f581d85e6e53aae63fde38c4a0389b78 /drivers/power
parent502ce10704d7fb53e8d41bbadbbdd4814d7c9b52 (diff)
downloadlinux-0838a3bfcd1b0c8d2ce38afcc94b81920486dabd.tar.bz2
power: supply: qcom_smbb: support pm8226
PM8226 (used in MSM8226) has v1 smbb hardware and works fine with the current driver. Signed-off-by: Luca Weiss <luca@z3ntu.xyz> Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Diffstat (limited to 'drivers/power')
-rw-r--r--drivers/power/supply/qcom_smbb.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/power/supply/qcom_smbb.c b/drivers/power/supply/qcom_smbb.c
index 84cc9fba029d..bd50124eef9f 100644
--- a/drivers/power/supply/qcom_smbb.c
+++ b/drivers/power/supply/qcom_smbb.c
@@ -863,8 +863,8 @@ static int smbb_charger_probe(struct platform_device *pdev)
}
chg->revision += 1;
- if (chg->revision != 2 && chg->revision != 3) {
- dev_err(&pdev->dev, "v1 hardware not supported\n");
+ if (chg->revision != 1 && chg->revision != 2 && chg->revision != 3) {
+ dev_err(&pdev->dev, "v%d hardware not supported\n", chg->revision);
return -ENODEV;
}
dev_info(&pdev->dev, "Initializing SMBB rev %u", chg->revision);
@@ -1012,6 +1012,7 @@ static int smbb_charger_remove(struct platform_device *pdev)
}
static const struct of_device_id smbb_charger_id_table[] = {
+ { .compatible = "qcom,pm8226-charger" },
{ .compatible = "qcom,pm8941-charger" },
{ }
};