linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: mgreer@animalcreek.com
Cc: linux-wireless@vger.kernel.org
Subject: re: NFC: trf7970a: Handle timeout values of zero
Date: Wed, 1 Oct 2014 17:20:48 +0300	[thread overview]
Message-ID: <20141001142048.GA32518@mwanda> (raw)

Hello Mark A. Greer,

The patch 1961843ceeca: "NFC: trf7970a: Handle timeout values of
zero" from Sep 2, 2014, leads to the following static checker warning:

	drivers/nfc/trf7970a.c:897 trf7970a_irq()
	warn: passing zero to 'ERR_PTR'

drivers/nfc/trf7970a.c
   892                          trf7970a_cmd(trf, TRF7970A_CMD_FIFO_RESET);
   893  
   894                          if (!trf->timeout) {
   895                                  trf->ignore_timeout = !cancel_delayed_work(
   896                                                  &trf->timeout_work);
   897                                  trf->rx_skb = ERR_PTR(0);
                                                      ^^^^^^^^^^
Why not just say "NULL"?

   898                                  trf7970a_send_upstream(trf);
   899                                  break;
   900                          }

regards,
dan carpenter

             reply	other threads:[~2014-10-01 14:21 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-01 14:20 Dan Carpenter [this message]
2014-10-01 16:11 ` NFC: trf7970a: Handle timeout values of zero Mark A. Greer

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=20141001142048.GA32518@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=linux-wireless@vger.kernel.org \
    --cc=mgreer@animalcreek.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).