linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rachita Kothiyal <rachita@in.ibm.com>
To: Jens Axboe <axboe@suse.de>
Cc: linux-kernel@vger.kernel.org, akpm@osdl.org
Subject: Re: [RFC] Patch to fix cdrom being confused on using kdump
Date: Wed, 19 Apr 2006 18:59:18 +0530	[thread overview]
Message-ID: <20060419132918.GA31705@in.ibm.com> (raw)
In-Reply-To: <20060412112933.GA6204@in.ibm.com>

On Wed, Apr 12, 2006 at 04:59:33PM +0530, Rachita Kothiyal wrote:
> 
> I actually tried just reading the status register and then returning
> ide_stopped. It seemed to be working fine, just that there appears 
> a 'status error' message while booting:
> 
> <snippet>
> ide0: start_request: current=0xffff8100035cba68
> hda: status error: status=0x58 { DriveReady SeekComplete DataRequest }
> ide: failed opcode was: unknown
> hda: drive not ready for command
> </snippet>

Hi Jens,

Instead of reading the status register and returning ide_stopped
from the handler, which was resulting in the 'status error', I 
tried ending the request and returning ide_stopped when the drive
is in a confused state. Using this I dont see the status error.

Following is the patch, kindly review.

Thanks
Rachita

Signed-off-by: Rachita Kothiyal <rachita@in.ibm.com>
---

 drivers/ide/ide-cd.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletion(-)

diff -puN drivers/ide/ide-cd.c~fix-confused-cdrom-with-kdump-end-req-ret drivers/ide/ide-cd.c
--- linux-2.6.17-rc1/drivers/ide/ide-cd.c~fix-confused-cdrom-with-kdump-end-req-ret	2006-04-19 18:01:44.000000000 +0530
+++ linux-2.6.17-rc1-rachita/drivers/ide/ide-cd.c	2006-04-19 18:55:06.000000000 +0530
@@ -1451,9 +1451,12 @@ static ide_startstop_t cdrom_pc_intr (id
 	} else {
 confused:
 		printk (KERN_ERR "%s: cdrom_pc_intr: The drive "
-			"appears confused (ireason = 0x%02x)\n",
+			"appears confused (ireason = 0x%02x). "
+			"Trying to recover by ending request.\n",
 			drive->name, ireason);
 		rq->flags |= REQ_FAILED;
+		cdrom_end_request(drive, 0);
+		return ide_stopped;
 	}
 
 	/* Now we wait for another interrupt. */
_

  reply	other threads:[~2006-04-19 13:28 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-04-07 13:57 [RFC] Patch to fix cdrom being confused on using kdump Rachita Kothiyal
2006-04-07 15:07 ` Dave Hansen
2006-04-09 10:29 ` Jens Axboe
2006-04-11 15:31   ` Rachita Kothiyal
2006-04-11 17:03     ` Jens Axboe
2006-04-12 11:29       ` Rachita Kothiyal
2006-04-19 13:29         ` Rachita Kothiyal [this message]
2006-04-19 13:52           ` Jens Axboe

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=20060419132918.GA31705@in.ibm.com \
    --to=rachita@in.ibm.com \
    --cc=akpm@osdl.org \
    --cc=axboe@suse.de \
    --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;
as well as URLs for NNTP newsgroup(s).