All of lore.kernel.org
 help / color / mirror / Atom feed
From: Joe Perches <joe@perches.com>
To: Jesper Juhl <jj@chaosbits.net>
Cc: linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org,
	"James E.J. Bottomley" <JBottomley@parallels.com>,
	Anil Ravindranath <anil_ravindranath@pmc-sierra.com>
Subject: Re: [PATCH] SCSI, pmcraid: Fix kmalloc() argument order in pmcraid_chr_ioctl()
Date: Mon, 24 Oct 2011 15:42:29 -0700	[thread overview]
Message-ID: <1319496149.2094.3.camel@Joe-Laptop> (raw)
In-Reply-To: <alpine.LNX.2.00.1110250036370.19795@swampdragon.chaosbits.net>

On Tue, 2011-10-25 at 00:38 +0200, Jesper Juhl wrote:
> The first argument to kmalloc() is the size, the second is
> flags. pmcraid_chr_ioctl() gets this wrong and swaps the
> arguments. This patch corrects the mistake.
> 
> Signed-off-by: Jesper Juhl <jj@chaosbits.net>
> ---
>  drivers/scsi/pmcraid.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
>  compile tested only.
> 
> diff --git a/drivers/scsi/pmcraid.c b/drivers/scsi/pmcraid.c
> index d079f9a..da19bdf 100644
> --- a/drivers/scsi/pmcraid.c
> +++ b/drivers/scsi/pmcraid.c
> @@ -4103,7 +4103,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");
> -- 
> 1.7.7
> 
> 

James seems to be uninterested in picking up
obvious and trivially correct patches.

>From a year ago...

https://lkml.org/lkml/2010/10/31/123

James?

  reply	other threads:[~2011-10-24 22:42 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-24 22:38 [PATCH] SCSI, pmcraid: Fix kmalloc() argument order in pmcraid_chr_ioctl() Jesper Juhl
2011-10-24 22:42 ` Joe Perches [this message]
2011-10-24 22:50   ` richard -rw- weinberger
2011-10-24 22:54     ` Dave Jones
2011-10-24 23:03       ` richard -rw- weinberger
2011-10-24 23:03         ` richard -rw- weinberger
2011-10-24 23:13         ` Jesper Juhl
2011-10-24 23:06       ` Jesper Juhl
2011-10-24 22:57     ` Jesper Juhl
2011-10-24 23:07       ` Joe Perches
2011-10-24 22:51   ` Jesper Juhl
2011-10-24 23:17     ` Joe Perches
2011-10-24 23:18   ` Dave Jones
2011-10-24 23:24     ` richard -rw- weinberger
2011-10-24 23:24       ` richard -rw- weinberger
2011-10-25  1:10       ` Joe Perches

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1319496149.2094.3.camel@Joe-Laptop \
    --to=joe@perches.com \
    --cc=JBottomley@parallels.com \
    --cc=anil_ravindranath@pmc-sierra.com \
    --cc=jj@chaosbits.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.