From 53207aa1a73e3e52b14c432b04d342c2b3af2e1c Mon Sep 17 00:00:00 2001 From: Linus Walleij Date: Fri, 12 Mar 2021 09:36:01 +0100 Subject: power: ab8500: Require device tree The core AB8500 driver and the whole platform is completely dependent on being probed from device tree so remove the non-DT probe paths. Signed-off-by: Linus Walleij Acked-by: Sebastian Reichel Signed-off-by: Lee Jones --- drivers/power/supply/ab8500_fg.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'drivers/power/supply/ab8500_fg.c') diff --git a/drivers/power/supply/ab8500_fg.c b/drivers/power/supply/ab8500_fg.c index 06ff42c71f24..079e11325a81 100644 --- a/drivers/power/supply/ab8500_fg.c +++ b/drivers/power/supply/ab8500_fg.c @@ -3043,12 +3043,10 @@ static int ab8500_fg_probe(struct platform_device *pdev) } di->bm = plat; - if (np) { - ret = ab8500_bm_of_probe(dev, np, di->bm); - if (ret) { - dev_err(dev, "failed to get battery information\n"); - return ret; - } + ret = ab8500_bm_of_probe(dev, np, di->bm); + if (ret) { + dev_err(dev, "failed to get battery information\n"); + return ret; } mutex_init(&di->cc_lock); -- cgit v1.2.3