power: supply: sbs-battery: use dev_err_probe
authorSebastian Reichel <sebastian.reichel@collabora.com>
Tue, 9 Mar 2021 18:04:01 +0000 (19:04 +0100)
committerSebastian Reichel <sebastian.reichel@collabora.com>
Fri, 2 Apr 2021 12:19:25 +0000 (14:19 +0200)
commit166767ab913dbf79129cf5f36b15b581513b501a
tree49d60d60bb9a14b66601eaa2ce6ebf579dd700ca
parent33ae8b03462e6cab130b505f97633feacf1743d0
power: supply: sbs-battery: use dev_err_probe

Introduce usage of dev_err_probe in probe routine, which
makes the code slightly more readable and removes some
lines of code. It also removes PROBE_DEFER errors being
logged by default, which are common when the battery is
waiting for the charger driver to be registered.

This also cleans up a useless goto and instead returns
directly.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
drivers/power/supply/sbs-battery.c