staging: ks7010: remove unnecessary cast
authorTobin C. Harding <me@tobin.cc>
Mon, 13 Mar 2017 22:54:07 +0000 (09:54 +1100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 14 Mar 2017 00:08:15 +0000 (08:08 +0800)
Return value from kmalloc() does not require a cast.

Remove unnecessary cast.

Signed-off-by: Tobin C. Harding <me@tobin.cc>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/ks7010/ks_wlan_net.c

index d55b5e30c038ba0d315096156e148a17c6d1a99c..9fa1ee7255cae051c93434ecbf9e262f42a87cae 100644 (file)
@@ -2400,7 +2400,7 @@ static int ks_wlan_data_write(struct net_device *dev,
        if (priv->sleep_mode == SLP_SLEEP)
                return -EPERM;
        /* for SLEEP MODE */
-       wbuff = (unsigned char *)kmalloc(dwrq->length, GFP_ATOMIC);
+       wbuff = kmalloc(dwrq->length, GFP_ATOMIC);
        if (!wbuff)
                return -EFAULT;
        memcpy(wbuff, extra, dwrq->length);