Staging: wilc1000: Unnecessary 'out of memory' message
authorMihaela Muraru <mihaela.muraru21@gmail.com>
Mon, 10 Oct 2016 08:13:14 +0000 (11:13 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 16 Oct 2016 08:26:06 +0000 (10:26 +0200)
This patch fixes checkpatch.pl warning in file host_interface.c
WARNING : possible unecessary 'out of memory' message.

Signed-off-by: Mihaela Muraru <mihaela.muraru21@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/wilc1000/host_interface.c

index 0d16e49a965678d8b2130a4018f43034518e1011..ff3d267c2eb0830ea3248fbf63aeef1f53d4b8a9 100644 (file)
@@ -1722,10 +1722,8 @@ _WPAPtk_end_case_:
 
        case PMKSA:
                pu8keybuf = kmalloc((pstrHostIFkeyAttr->attr.pmkid.numpmkid * PMKSA_KEY_LEN) + 1, GFP_KERNEL);
-               if (!pu8keybuf) {
-                       netdev_err(vif->ndev, "No buffer to send PMKSA Key\n");
+               if (!pu8keybuf)
                        return -ENOMEM;
-               }
 
                pu8keybuf[0] = pstrHostIFkeyAttr->attr.pmkid.numpmkid;