mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-09 21:59:12 -04:00
liquidio: remove unnecessary NULL check before kfree in delete_glists
NULL check before freeing functions like kfree is not needed. This issue was detected with the help of Coccinelle. Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com> Acked-by: Felix Manlunas <felix.manlunas@cavium.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
ac79a512b6
commit
b14bec8904
1 changed files with 1 additions and 2 deletions
|
|
@ -435,8 +435,7 @@ static void delete_glists(struct lio *lio)
|
|||
do {
|
||||
g = (struct octnic_gather *)
|
||||
list_delete_head(&lio->glist[i]);
|
||||
if (g)
|
||||
kfree(g);
|
||||
kfree(g);
|
||||
} while (g);
|
||||
|
||||
if (lio->glists_virt_base && lio->glists_virt_base[i] &&
|
||||
|
|
|
|||
Loading…
Reference in a new issue