Merge branch 'for-2638/i2c/iop' into for-linus/i2c-2638
[firefly-linux-kernel-4.4.55.git] / mm / percpu.c
index 02ba91230b99269f45beea6387c165e042800347..3dd4984bdef849c4a172c5e2d5d6f2d230137f8b 100644 (file)
@@ -293,12 +293,8 @@ static void *pcpu_mem_alloc(size_t size)
 
        if (size <= PAGE_SIZE)
                return kzalloc(size, GFP_KERNEL);
-       else {
-               void *ptr = vmalloc(size);
-               if (ptr)
-                       memset(ptr, 0, size);
-               return ptr;
-       }
+       else
+               return vzalloc(size);
 }
 
 /**