summaryrefslogtreecommitdiff
path: root/mm/percpu-stats.c
diff options
context:
space:
mode:
Diffstat (limited to 'mm/percpu-stats.c')
-rw-r--r--mm/percpu-stats.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/percpu-stats.c b/mm/percpu-stats.c
index 063ff60ecd90..b5fdd43b60c9 100644
--- a/mm/percpu-stats.c
+++ b/mm/percpu-stats.c
@@ -144,7 +144,7 @@ alloc_buffer:
spin_unlock_irq(&pcpu_lock);
/* there can be at most this many free and allocated fragments */
- buffer = vmalloc((2 * max_nr_alloc + 1) * sizeof(int));
+ buffer = vmalloc(array_size(sizeof(int), (2 * max_nr_alloc + 1)));
if (!buffer)
return -ENOMEM;