power: supply: cpcap-charger: Simplify bool conversion

Fix the following coccicheck warning:
./drivers/power/supply/cpcap-charger.c:416:31-36: WARNING: conversion to
bool not needed here

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Yang Li <yang.lee@linux.alibaba.com>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
This commit is contained in:
Yang Li 2021-01-29 16:10:12 +08:00 committed by Sebastian Reichel
parent 751faedf06
commit 816aacd541

View File

@ -465,7 +465,7 @@ static bool cpcap_charger_vbus_valid(struct cpcap_charger_ddata *ddata)
error = iio_read_channel_processed(channel, &value);
if (error >= 0)
return value > 3900 ? true : false;
return value > 3900;
dev_err(ddata->dev, "error reading VBUS: %i\n", error);