mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Willem Riede <wrlk@riede.org>
To: Andries.Brouwer@cwi.nl, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] fix for ide-scsi crash
Date: Mon, 19 Jan 2004 17:35:43 -0500	[thread overview]
Message-ID: <pan.2004.01.19.22.35.42.365482@riede.org> (raw)
In-Reply-To: <UTC200401190435.i0J4Zwp26577.aeb@smtp.cwi.nl>

On Mon, 19 Jan 2004 05:35:58 +0100, Andries.Brouwer wrote:

> -	spin_unlock_irq(cmd->device->host->host_lock);
> -	(void) ide_do_drive_cmd (drive, rq, ide_end);
> -	spin_lock_irq(cmd->device->host->host_lock);
> +	{
> +		struct Scsi_Host *host = cmd->device->host;
> +		spin_unlock_irq(host->host_lock);
> +		(void) ide_do_drive_cmd(drive, rq, ide_end);
> +		spin_lock_irq(host->host_lock);
> +	}

Interesting. So cmd->device->host changed after ide_do_drive_cmd?

That may be a problem if the scsi error handler has to spring 
into action for this command, as it uses that field extensively...

> -	if (pc) kfree (pc);
> -	if (rq) kfree (rq);
> +	kfree (pc);
> +	kfree (rq);

So it is OK to rely on the NULL check in kfree?

Thanks, Willem Riede.


  reply	other threads:[~2004-01-19 22:35 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-01-19  4:35 Andries.Brouwer
2004-01-19 22:35 ` Willem Riede [this message]
2004-01-19 18:51 Pascal Schmidt
2004-01-20  7:32 ` Linus Torvalds
2004-01-20 13:54   ` Jens Axboe
2004-01-19 22:56 Andries.Brouwer
2004-01-20  9:44 Andries.Brouwer
2004-01-20 12:04 ` Pascal Schmidt
2004-01-20 13:56   ` Jens Axboe
2004-01-20 17:56 ` Linus Torvalds
2004-01-20 18:46 ` Ben Pfaff
     [not found] <1fMNb-6UA-15@gated-at.bofh.it>
     [not found] ` <1fYEB-pz-23@gated-at.bofh.it>
     [not found]   ` <1g4Ao-60b-25@gated-at.bofh.it>
2004-01-20 14:59     ` Pascal Schmidt
2004-01-20 19:04       ` bill davidsen
2004-01-20 17:08 Pascal Schmidt
2004-01-20 20:01 ` Andries Brouwer
2004-01-20 20:58   ` Pascal Schmidt

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=pan.2004.01.19.22.35.42.365482@riede.org \
    --to=wrlk@riede.org \
    --cc=Andries.Brouwer@cwi.nl \
    --cc=linux-kernel@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome