treewide: Use array_size() in vmalloc()
[linux-2.6-block.git] / arch / powerpc / kernel / rtasd.c
index f915db93cd429d4405089c7f4eb5de1ba708d746..44d66c33d59d5a2d9e38c0138cb0749927eebd6f 100644 (file)
@@ -559,7 +559,8 @@ static int __init rtas_event_scan_init(void)
        rtas_error_log_max = rtas_get_error_log_max();
        rtas_error_log_buffer_max = rtas_error_log_max + sizeof(int);
 
-       rtas_log_buf = vmalloc(rtas_error_log_buffer_max*LOG_NUMBER);
+       rtas_log_buf = vmalloc(array_size(LOG_NUMBER,
+                                         rtas_error_log_buffer_max));
        if (!rtas_log_buf) {
                printk(KERN_ERR "rtasd: no memory\n");
                return -ENOMEM;