mirror of
https://github.com/raspberrypi/linux.git
synced 2025-12-06 10:00:17 +00:00
vcsm: Fix "Prefer kcalloc over kzalloc with multiply"
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
This commit is contained in:
committed by
popcornmix
parent
2616cca572
commit
b51a9b42bc
@@ -2984,7 +2984,9 @@ static long vc_sm_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
|
||||
ret = -EFAULT;
|
||||
goto out;
|
||||
}
|
||||
block = kzalloc(ioparam.op_count * sizeof(struct vmcs_sm_ioctl_clean_invalid_block), GFP_KERNEL);
|
||||
block = kcalloc(ioparam.op_count,
|
||||
sizeof(struct vmcs_sm_ioctl_clean_invalid_block),
|
||||
GFP_KERNEL);
|
||||
if (!block) {
|
||||
ret = -EFAULT;
|
||||
goto out;
|
||||
|
||||
Reference in New Issue
Block a user