revert mm/vmalloc.c: emit the failure message before return
authorWanpeng Li <[email protected]>
Tue, 12 Nov 2013 23:07:33 +0000 (15:07 -0800)
committerLinus Torvalds <[email protected]>
Wed, 13 Nov 2013 03:09:05 +0000 (12:09 +0900)
Don't warn twice in __vmalloc_area_node and __vmalloc_node_range if
__vmalloc_area_node allocation failure.  This patch reverts commit
46c001a2753f ("mm/vmalloc.c: emit the failure message before return").

Signed-off-by: Wanpeng Li <[email protected]>
Reviewed-by: Zhang Yanfei <[email protected]>
Cc: Joonsoo Kim <[email protected]>
Cc: KOSAKI Motohiro <[email protected]>
Cc: Mitsuo Hayasaka <[email protected]>
Cc: David Rientjes <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
mm/vmalloc.c

index 67535f87846c38694eb576f8c19fc051bc99acb4..745fa9567475cddbca9b905df35984ad972e33bc 100644 (file)
@@ -1635,7 +1635,7 @@ void *__vmalloc_node_range(unsigned long size, unsigned long align,
 
        addr = __vmalloc_area_node(area, gfp_mask, prot, node);
        if (!addr)
-               goto fail;
+               return NULL;
 
        /*
         * In this function, newly allocated vm_struct has VM_UNINITIALIZED