All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: t-kristo@ti.com
Cc: linux-crypto@vger.kernel.org
Subject: [bug report] crypto: omap-sham - add support functions for sg based data handling
Date: Thu, 13 Oct 2016 12:31:47 +0300	[thread overview]
Message-ID: <20161013093147.GA25189@mwanda> (raw)

Hello Tero Kristo,

This is a semi-automatic email about new static checker warnings.

The patch f19de1bc67a0: "crypto: omap-sham - add support functions 
for sg based data handling" from Sep 19, 2016, leads to the following 
Smatch complaint:

drivers/crypto/omap-sham.c:808 omap_sham_prepare_request()
	 warn: variable dereferenced before check 'req' (see line 801)

drivers/crypto/omap-sham.c
   800	{
   801		struct omap_sham_reqctx *rctx = ahash_request_ctx(req);
                                                                  ^^^
New dereference inside function.

   802		int bs;
   803		int ret;
   804		int nbytes;
   805		bool final = rctx->flags & BIT(FLAGS_FINUP);
   806		int xmit_len, hash_later;
   807	
   808		if (!req)
                    ^^^^
New check is too late.

   809			return 0;
   810	

regards,
dan carpenter

                 reply	other threads:[~2016-10-13  9:32 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20161013093147.GA25189@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=linux-crypto@vger.kernel.org \
    --cc=t-kristo@ti.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.