Commit 79517e8f authored by zhong jiang's avatar zhong jiang Committed by Herbert Xu

crypto: cavium - remove redundant null pointer check before kfree

kfree has taken the null pointer into account. hence it is safe
to remove the redundant null pointer check before kfree.
Signed-off-by: default avatarzhong jiang <zhongjiang@huawei.com>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent 2a8780be
......@@ -308,21 +308,11 @@ void do_request_cleanup(struct cpt_vf *cptvf,
}
}
if (info->scatter_components)
kzfree(info->scatter_components);
if (info->gather_components)
kzfree(info->gather_components);
if (info->out_buffer)
kzfree(info->out_buffer);
if (info->in_buffer)
kzfree(info->in_buffer);
if (info->completion_addr)
kzfree((void *)info->completion_addr);
kzfree(info->scatter_components);
kzfree(info->gather_components);
kzfree(info->out_buffer);
kzfree(info->in_buffer);
kzfree((void *)info->completion_addr);
kzfree(info);
}
......
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