From 264312241b72d424e629f6e98e25cd9193d14cc4 Mon Sep 17 00:00:00 2001 From: Samuel Ortiz Date: Fri, 16 Oct 2009 13:18:55 +0800 Subject: [PATCH] --- yaml --- r: 171012 b: refs/heads/master c: 708567e0723f3a217286c2b60805af6de360ec50 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/drivers/net/wireless/iwmc3200wifi/rx.c | 10 ++++++++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/[refs] b/[refs] index c6b816e34fb2..a5cb4d74bf43 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: f96cca8483c1b0bcc8002dc466159bf8fd53ca47 +refs/heads/master: 708567e0723f3a217286c2b60805af6de360ec50 diff --git a/trunk/drivers/net/wireless/iwmc3200wifi/rx.c b/trunk/drivers/net/wireless/iwmc3200wifi/rx.c index 225b1d3b2735..648f84a83705 100644 --- a/trunk/drivers/net/wireless/iwmc3200wifi/rx.c +++ b/trunk/drivers/net/wireless/iwmc3200wifi/rx.c @@ -1057,8 +1057,14 @@ static int iwm_ntf_wifi_if_wrapper(struct iwm_priv *iwm, u8 *buf, unsigned long buf_size, struct iwm_wifi_cmd *cmd) { - struct iwm_umac_wifi_if *hdr = - (struct iwm_umac_wifi_if *)cmd->buf.payload; + struct iwm_umac_wifi_if *hdr; + + if (cmd == NULL) { + IWM_ERR(iwm, "Couldn't find expected wifi command\n"); + return -EINVAL; + } + + hdr = (struct iwm_umac_wifi_if *)cmd->buf.payload; IWM_DBG_NTF(iwm, DBG, "WIFI_IF_WRAPPER cmd is delivered to UMAC: " "oid is 0x%x\n", hdr->oid);