public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: James Bottomley <James.Bottomley@HansenPartnership.com>
To: akpm@linux-foundation.org, linux-scsi <linux-scsi@vger.kernel.org>
Cc: mm-commits@vger.kernel.org, olel@ans.pl, Eric.Moore@lsi.com,
	fujita.tomonori@lab.ntt.co.jp, ole@ans.pl,
	sathya.prakash@lsi.com
Subject: Re: + mpt-fusion-dont-oops-if-numphys==0.patch added to -mm tree
Date: Tue, 19 Feb 2008 20:39:11 -0600	[thread overview]
Message-ID: <1203475151.3103.40.camel@localhost.localdomain> (raw)
In-Reply-To: <200802192335.m1JNZ7MV005426@imap1.linux-foundation.org>


On Tue, 2008-02-19 at 15:34 -0800, akpm@linux-foundation.org wrote:
> Subject: mpt fusion: don't oops if NumPhys==0
> From: Krzysztof Oledzki <olel@ans.pl>
> 
> Don't oops if NumPhys==0, instead return -ENODEV.
> This patch fixes http://bugzilla.kernel.org/show_bug.cgi?id=9909
> 
> Signed-off-by: Krzysztof Piotr Oledzki <ole@ans.pl>
> Cc: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
> Cc: James Bottomley <James.Bottomley@HansenPartnership.com>
> Cc: Eric Moore <Eric.Moore@lsi.com>
> Cc: Sathya Prakash <sathya.prakash@lsi.com>
> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
> ---
> 
>  drivers/message/fusion/mptsas.c |    5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff -puN drivers/message/fusion/mptsas.c~mpt-fusion-dont-oops-if-numphys==0 drivers/message/fusion/mptsas.c
> --- a/drivers/message/fusion/mptsas.c~mpt-fusion-dont-oops-if-numphys==0
> +++ a/drivers/message/fusion/mptsas.c
> @@ -1701,6 +1701,11 @@ mptsas_sas_expander_pg0(MPT_ADAPTER *ioc
>  	if (error)
>  		goto out_free_consistent;
>  
> +	if (!buffer->NumPhys) {
> +		error = -ENODEV;
> +		goto out_free_consistent;
> +	}
> +
>  	/* save config data */
>  	port_info->num_phys = buffer->NumPhys;
>  	port_info->phy_info = kcalloc(port_info->num_phys,
> _

This is a bit odd ... It looks like a work around for a fusion firmware
problem.  What's the topology this thing is connected to?

James





       reply	other threads:[~2008-02-20  2:39 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <200802192335.m1JNZ7MV005426@imap1.linux-foundation.org>
2008-02-20  2:39 ` James Bottomley [this message]
2008-02-20  3:06   ` + mpt-fusion-dont-oops-if-numphys==0.patch added to -mm tree Krzysztof Oledzki
2008-02-20  3:17     ` Maximilian Wilhelm
2008-02-20  3:28       ` James Bottomley
2008-02-20 18:14         ` Maximilian Wilhelm

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=1203475151.3103.40.camel@localhost.localdomain \
    --to=james.bottomley@hansenpartnership.com \
    --cc=Eric.Moore@lsi.com \
    --cc=akpm@linux-foundation.org \
    --cc=fujita.tomonori@lab.ntt.co.jp \
    --cc=linux-scsi@vger.kernel.org \
    --cc=mm-commits@vger.kernel.org \
    --cc=ole@ans.pl \
    --cc=olel@ans.pl \
    --cc=sathya.prakash@lsi.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox