Re: [RFC] Patch to fix cdrom being confused on using kdump

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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 <[email protected]>
---

 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. */
_
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux