All of lore.kernel.org
 help / color / mirror / Atom feed
From: James Bottomley <James.Bottomley@SteelEye.com>
To: Anton Blanchard <anton@samba.org>
Cc: SCSI Mailing List <linux-scsi@vger.kernel.org>
Subject: Re: sym2 oops in 2.6.9-rc2-BK
Date: 28 Sep 2004 11:38:35 -0400	[thread overview]
Message-ID: <1096385921.2008.21.camel@mulgrave> (raw)
In-Reply-To: <20040928135826.GA3373@krispykreme.ozlabs.ibm.com>

On Tue, 2004-09-28 at 09:58, Anton Blanchard wrote:
> Ive got a 2.6.9-rc2-bk tree from about September 16 which exploded in
> sym_prepare_nego. It turns out sdev is NULL, and scsi_device_dt(sdev)
> causes the trouble.
> 
> A few lines above there is a check for sdev != NULL, so assuming it is
> valid to be NULL add a check before scsi_device_dt() too.
> 
> Anton
> 
> Signed-off-by: Anton Blanchard <anton@samba.org>
> 
> diff -puN drivers/scsi/sym53c8xx_2/sym_hipd.c~fix-sym2 drivers/scsi/sym53c8xx_2/sym_hipd.c
> --- gr_work/drivers/scsi/sym53c8xx_2/sym_hipd.c~fix-sym2	2004-09-28 03:03:26.493627814 -0500
> +++ gr_work-anton/drivers/scsi/sym53c8xx_2/sym_hipd.c	2004-09-28 03:03:50.247458823 -0500
> @@ -1550,7 +1550,7 @@ static int sym_prepare_nego(hcb_p np, cc
>  	/*
>  	 *  negotiate using PPR ?
>  	 */
> -	if (scsi_device_dt(sdev)) {
> +	if (sdev && scsi_device_dt(sdev)) {
>  		nego = NS_PPR;
>  	} else {
>  		/*

Actually, this patch can't be correct.  We should never be negotiating
with a NULL sdev.  Previously we negotated after slave_alloc, but I've
tried to change the driver to defer negotiation until slave_configure.

What were the messages in the log prior to the NULL deref?  What I'm
trying to understand is how we got to this point.

James



  parent reply	other threads:[~2004-09-28 15:38 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-09-28 13:58 sym2 oops in 2.6.9-rc2-BK Anton Blanchard
2004-09-28 14:21 ` Anton Blanchard
2004-09-28 15:17   ` Matthew Wilcox
2004-09-28 14:56 ` Matthew Wilcox
2004-09-28 15:25   ` Anton Blanchard
2004-09-28 15:38 ` James Bottomley [this message]
2004-09-30 13:05   ` Anton Blanchard
2004-09-30 13:52     ` James Bottomley
2004-09-30 14:05       ` Anton Blanchard

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=1096385921.2008.21.camel@mulgrave \
    --to=james.bottomley@steeleye.com \
    --cc=anton@samba.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.