Commit 816aacd5 authored by Yang Li's avatar Yang Li Committed by Sebastian Reichel

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: default avatarAbaci Robot <abaci@linux.alibaba.com>
Signed-off-by: default avatarYang Li <yang.lee@linux.alibaba.com>
Signed-off-by: default avatarSebastian Reichel <sebastian.reichel@collabora.com>
parent 751faedf
......@@ -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);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment