summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSeth Forshee <seth.forshee@canonical.com>2012-11-29 07:36:00 -0600
committerJohn W. Linville <linville@tuxdriver.com>2012-11-30 14:00:39 -0500
commit55cec505559dade9e7776de8f3d23fc3e54e091d (patch)
tree52f2d9ef31ec25bdaacfde9e9163076cdc3837fa
parent697978383e94fff79fc72d9dbf1a03db8ac9784a (diff)
brcmsmac: Fix possible NULL pointer dereference in _dma_ctrlflags()master-2012-11-30
There's a debug message to warn if this function is passed a NULL pointer, but in order to print the message we have to dereference the pointer. Obviously this isn't a good idea, so remove the message. Reported-by: Fengguang Wu <fengguang.wu@intel.com> Signed-off-by: Seth Forshee <seth.forshee@canonical.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r--drivers/net/wireless/brcm80211/brcmsmac/dma.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/net/wireless/brcm80211/brcmsmac/dma.c b/drivers/net/wireless/brcm80211/brcmsmac/dma.c
index 511e45775c33..1860c572b3c4 100644
--- a/drivers/net/wireless/brcm80211/brcmsmac/dma.c
+++ b/drivers/net/wireless/brcm80211/brcmsmac/dma.c
@@ -349,10 +349,8 @@ static uint _dma_ctrlflags(struct dma_info *di, uint mask, uint flags)
{
uint dmactrlflags;
- if (di == NULL) {
- brcms_dbg_dma(di->core, "NULL dma handle\n");
+ if (di == NULL)
return 0;
- }
dmactrlflags = di->dma.dmactrlflags;
dmactrlflags &= ~mask;