Message ID | 20220117014158.GA3685@07889aeafbfc (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | power: supply_core: fix noderef.cocci warnings | expand |
--- a/drivers/power/supply/cw2015_battery.c +++ b/drivers/power/supply/cw2015_battery.c @@ -689,7 +689,7 @@ static int cw_bat_probe(struct i2c_clien if (ret) { /* Allocate an empty battery */ cw_bat->battery = devm_kzalloc(&client->dev, - sizeof(cw_bat->battery), + sizeof(*cw_bat->battery), GFP_KERNEL); if (!cw_bat->battery) return -ENOMEM;