mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-07 20:33:58 -04:00
Merge "soc: qcom: qti_battery_debug: Add NULL check"
This commit is contained in:
commit
f23a376aa5
1 changed files with 2 additions and 0 deletions
|
|
@ -615,6 +615,8 @@ static int battery_dbg_create_votables(struct battery_dbg_dev *bd,
|
|||
|
||||
bd->votable = devm_kcalloc(bd->dev, num_votables,
|
||||
sizeof(struct votable), GFP_KERNEL);
|
||||
if (!bd->votable)
|
||||
return -ENOMEM;
|
||||
|
||||
for (id = 0; id < num_votables; id++) {
|
||||
bd->votable[id].bd = bd;
|
||||
|
|
|
|||
Loading…
Reference in a new issue