]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
staging: rtl8188eu: os_dep: remove unnecessary alloc fail message
authorPierre-Yves Kerbrat <pkerbrat@free.fr>
Wed, 19 Oct 2016 18:49:53 +0000 (20:49 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 25 Oct 2016 08:57:13 +0000 (10:57 +0200)
Remove redundant alloc fail message
This patch fixes the warning found by checkpatch

Signed-off-by: Pierre-Yves Kerbrat <pkerbrat@free.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8188eu/os_dep/osdep_service.c

index c036fe7d1df805f4dc04b0e9e66465933f944f2b..6ff836f481daca9f935bb2903bdbcff05158378f 100644 (file)
@@ -43,14 +43,12 @@ void *rtw_malloc2d(int h, int w, int size)
        int j;
 
        void **a = kzalloc(h * sizeof(void *) + h * w * size, GFP_KERNEL);
-       if (!a) {
-               pr_info("%s: alloc memory fail!\n", __func__);
-               return NULL;
-       }
+       if (!a)
+               goto out;
 
        for (j = 0; j < h; j++)
                a[j] = ((char *)(a + h)) + j * w * size;
-
+out:
        return a;
 }