power: bq27xxx_battery: fix signedness bug in bq27xxx_battery_read_health()
[firefly-linux-kernel-4.4.55.git] / drivers / power / bq27xxx_battery.c
index 473aa2f9488244a1dc462cb73dce3ce95cecffac..994c78d9f42675b47c7883e9314d3a465f9496b9 100644 (file)
@@ -691,7 +691,7 @@ static bool bq27xxx_battery_dead(struct bq27xxx_device_info *di, u16 flags)
  */
 static int bq27xxx_battery_read_health(struct bq27xxx_device_info *di)
 {
-       u16 flags;
+       int flags;
 
        flags = bq27xxx_read(di, BQ27XXX_REG_FLAGS, false);
        if (flags < 0) {