staging: brcm80211: replace 0 integer with NULL pointer
authorArend van Spriel <arend@broadcom.com>
Fri, 2 Sep 2011 14:00:29 +0000 (16:00 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 6 Sep 2011 23:46:26 +0000 (16:46 -0700)
Running sparse showed following warning: Using plain integer as NULL
pointer. This has been fixed.

Reported-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Reviewed-by: Roland Vossen <rvossen@broadcom.com>
Signed-off-by: Roland Vossen <rvossen@broadcom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/brcm80211/brcmfmac/dhd_common.c

index 3abd434ba526ca8322cf3414c37b542fdf688915..cb7393c64ba4c40612a2c21ea32f8dd694a11394 100644 (file)
@@ -840,7 +840,7 @@ brcmf_c_pktfilter_offload_enable(struct brcmf_pub *drvr, char *arg, int enable,
        const char *str;
        int buf_len;
        int str_len;
-       char *arg_save = 0, *arg_org = 0;
+       char *arg_save = NULL, *arg_org = NULL;
        int rc;
        char buf[128];
        struct brcmf_pkt_filter_enable enable_parm;
@@ -915,9 +915,9 @@ void brcmf_c_pktfilter_offload_set(struct brcmf_pub *drvr, char *arg)
        int rc;
        u32 mask_size;
        u32 pattern_size;
-       char *argv[8], *buf = 0;
+       char *argv[8], *buf = NULL;
        int i = 0;
-       char *arg_save = 0, *arg_org = 0;
+       char *arg_save = NULL, *arg_org = NULL;
 
        arg_save = kstrdup(arg, GFP_ATOMIC);
        if (!arg_save) {
@@ -1099,7 +1099,7 @@ int brcmf_c_preinit_ioctls(struct brcmf_pub *drvr)
        /* query for 'ver' to get version info from firmware */
        memset(buf, 0, sizeof(buf));
        ptr = buf;
-       brcmu_mkiovar("ver", 0, 0, buf, sizeof(buf));
+       brcmu_mkiovar("ver", NULL, 0, buf, sizeof(buf));
        brcmf_proto_cdc_query_ioctl(drvr, 0, BRCMF_C_GET_VAR, buf, sizeof(buf));
        strsep(&ptr, "\n");
        /* Print fw version info */