Message ID | alpine.DEB.2.20.1701071042410.2029@hadrien (mailing list archive) |
---|---|
State | Not Applicable |
Delegated to: | Herbert Xu |
Headers | show |
On Sat, Jan 07, 2017 at 10:46:17AM +0100, Julia Lawall wrote: > The first argument to list_for_each_entry cannot be NULL. > > Generated by: scripts/coccinelle/iterators/itnull.cocci > > CC: Harsh Jain <harsh@chelsio.com> > Signed-off-by: Julia Lawall <julia.lawall@lip6.fr> > Signed-off-by: Fengguang Wu <fengguang.wu@intel.com> > --- > > This code comes from the following git tree: > > url: > https://github.com/0day-ci/linux/commits/Harsh-Jain/crypto-chcr-Bug-fixes/20170107-093356 > base: > https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git > master > In-Reply-To: > <8e0086b56d8fb61637d179c32a09a1bca03c4186.1483599449.git.harsh@chelsio.com> Harsh, please fold this patch into your series when you resubmit. Thanks,
--- a/drivers/crypto/chelsio/chcr_core.c +++ b/drivers/crypto/chelsio/chcr_core.c @@ -61,7 +61,7 @@ int assign_chcr_device(struct chcr_dev * */ mutex_lock(&dev_mutex); /* TODO ? */ list_for_each_entry(u_ctx, &uld_ctx_list, entry) - if (u_ctx && u_ctx->dev) { + if (u_ctx->dev) { *dev = u_ctx->dev; ret = 0; break;