From: Dave Jones Date: Mon, 24 Oct 2011 22:10:26 +0000 (-0400) Subject: [SCSI] pmcraid: pmcraid_chr_ioctl uses incorrect argument order to kmalloc() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=a63ec37629415848b5704eda5110fe8e750032ca;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git [SCSI] pmcraid: pmcraid_chr_ioctl uses incorrect argument order to kmalloc() Size is 1st arg, not second. Signed-off-by: Dave Jones Signed-off-by: James Bottomley --- diff --git a/drivers/scsi/pmcraid.c b/drivers/scsi/pmcraid.c index b86db84d6f32..5163edb925cb 100644 --- a/drivers/scsi/pmcraid.c +++ b/drivers/scsi/pmcraid.c @@ -4102,7 +4102,7 @@ static long pmcraid_chr_ioctl( struct pmcraid_ioctl_header *hdr = NULL; int retval = -ENOTTY; - hdr = kmalloc(GFP_KERNEL, sizeof(struct pmcraid_ioctl_header)); + hdr = kmalloc(sizeof(struct pmcraid_ioctl_header), GFP_KERNEL); if (!hdr) { pmcraid_err("faile to allocate memory for ioctl header\n");