All of lore.kernel.org
 help / color / mirror / Atom feed
From: Fengguang Wu <fengguang.wu@intel.com>
To: Seth Forshee <seth.forshee@canonical.com>
Cc: kbuild@01.org, Julia Lawall <julia.lawall@lip6.fr>,
	"John W. Linville" <linville@tuxdriver.com>,
	linux-wireless@vger.kernel.org
Subject: [wireless-next:master 207/237] drivers/net/wireless/brcm80211/brcmsmac/dma.c:352:20-24: ERROR: di is NULL but dereferenced.
Date: Thu, 29 Nov 2012 09:13:37 +0800	[thread overview]
Message-ID: <20121129011337.GA5785@localhost> (raw)
In-Reply-To: <50b6477a.KNKuUJi++FBSGGYg%fengguang.wu@intel.com>

Hi Seth,

FYI, there are coccinelle warnings in

tree:   git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next.git master
head:   0751f8654602e4255f0b9c17784d8100d5896010
commit: 90123e045cac4ce8ec13e266f030c618fa674554 [207/237] brcmsmac: Add brcms_dbg_dma() debug macro

+ drivers/net/wireless/brcm80211/brcmsmac/dma.c:352:20-24: ERROR: di is NULL but dereferenced.

vim +352 drivers/net/wireless/brcm80211/brcmsmac/dma.c

5b435de0 Arend van Spriel 2011-10-05  336  
5b435de0 Arend van Spriel 2011-10-05  337  static uint ntxdactive(struct dma_info *di, uint h, uint t)
5b435de0 Arend van Spriel 2011-10-05  338  {
5b435de0 Arend van Spriel 2011-10-05  339  	return txd(di, t-h);
5b435de0 Arend van Spriel 2011-10-05  340  }
5b435de0 Arend van Spriel 2011-10-05  341  
5b435de0 Arend van Spriel 2011-10-05  342  static uint nrxdactive(struct dma_info *di, uint h, uint t)
5b435de0 Arend van Spriel 2011-10-05  343  {
5b435de0 Arend van Spriel 2011-10-05  344  	return rxd(di, t-h);
5b435de0 Arend van Spriel 2011-10-05  345  }
5b435de0 Arend van Spriel 2011-10-05  346  
5b435de0 Arend van Spriel 2011-10-05  347  static uint _dma_ctrlflags(struct dma_info *di, uint mask, uint flags)
5b435de0 Arend van Spriel 2011-10-05  348  {
ae8e4672 Arend van Spriel 2011-10-29  349  	uint dmactrlflags;
5b435de0 Arend van Spriel 2011-10-05  350  
5b435de0 Arend van Spriel 2011-10-05  351  	if (di == NULL) {
90123e04 Seth Forshee     2012-11-15 @352  		brcms_dbg_dma(di->core, "NULL dma handle\n");
5b435de0 Arend van Spriel 2011-10-05  353  		return 0;
5b435de0 Arend van Spriel 2011-10-05  354  	}
5b435de0 Arend van Spriel 2011-10-05  355  
ae8e4672 Arend van Spriel 2011-10-29  356  	dmactrlflags = di->dma.dmactrlflags;
5b435de0 Arend van Spriel 2011-10-05  357  	dmactrlflags &= ~mask;
5b435de0 Arend van Spriel 2011-10-05  358  	dmactrlflags |= flags;
5b435de0 Arend van Spriel 2011-10-05  359  
5b435de0 Arend van Spriel 2011-10-05  360  	/* If trying to enable parity, check if parity is actually supported */

---
0-DAY kernel build testing backend         Open Source Technology Center
Fengguang Wu, Yuanhan Liu                              Intel Corporation

       reply	other threads:[~2012-11-29  1:14 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <50b6477a.KNKuUJi++FBSGGYg%fengguang.wu@intel.com>
2012-11-29  1:13 ` Fengguang Wu [this message]
2012-11-29 13:51   ` [wireless-next:master 207/237] drivers/net/wireless/brcm80211/brcmsmac/dma.c:352:20-24: ERROR: di is NULL but dereferenced Seth Forshee

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=20121129011337.GA5785@localhost \
    --to=fengguang.wu@intel.com \
    --cc=julia.lawall@lip6.fr \
    --cc=kbuild@01.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=linville@tuxdriver.com \
    --cc=seth.forshee@canonical.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.