* Re: [PATCH] ide-scsi 2.5.10-dj1 compilation failure
2002-04-27 22:14 [PATCH] ide-scsi 2.5.10-dj1 compilation failure Douglas Gilbert
@ 2002-04-27 21:41 ` Martin Dalecki
0 siblings, 0 replies; 2+ messages in thread
From: Martin Dalecki @ 2002-04-27 21:41 UTC (permalink / raw)
To: Douglas Gilbert; +Cc: linux-kernel, axboe, Dave Jones, linux-scsi
Uz.ytkownik Douglas Gilbert napisa?:
> Christoph Lameter <christoph@lameter.com> reported this
> compile error in lk 2.5.10-dj1:
>
>>ide-scsi.c:837: unknown field `abort' specified in initializer
>>ide-scsi.c:837: warning: initialization from incompatible pointer type
>>ide-scsi.c:838: unknown field `reset' specified in initializer
>>ide-scsi.c:838: warning: initialization from incompatible pointer type
>
>
> Below is a patch which attempts to do the right thing:
> it wires up the scsi new eh handling and attempts to do
> a device reset.
>
> It has been tested and oopses in start_request() inside
> ide.c when a device reset is issued :-) Since the previous
> ide-scsi logic just ignored scsi error handling, it isn't
> really a whole lot worse. There is a "fix me" at the
> appropriate point.
>
> Doug Gilbert
Well the "hidden" queueing of some commands on the
device request queue is what is getting you here. It's subject
to be gone, so this problem will be resolved.
^ permalink raw reply [flat|nested] 2+ messages in thread
* [PATCH] ide-scsi 2.5.10-dj1 compilation failure
@ 2002-04-27 22:14 Douglas Gilbert
2002-04-27 21:41 ` Martin Dalecki
0 siblings, 1 reply; 2+ messages in thread
From: Douglas Gilbert @ 2002-04-27 22:14 UTC (permalink / raw)
To: linux-kernel; +Cc: axboe, Dave Jones, linux-scsi
Christoph Lameter <christoph@lameter.com> reported this
compile error in lk 2.5.10-dj1:
> ide-scsi.c:837: unknown field `abort' specified in initializer
> ide-scsi.c:837: warning: initialization from incompatible pointer type
> ide-scsi.c:838: unknown field `reset' specified in initializer
> ide-scsi.c:838: warning: initialization from incompatible pointer type
Below is a patch which attempts to do the right thing:
it wires up the scsi new eh handling and attempts to do
a device reset.
It has been tested and oopses in start_request() inside
ide.c when a device reset is issued :-) Since the previous
ide-scsi logic just ignored scsi error handling, it isn't
really a whole lot worse. There is a "fix me" at the
appropriate point.
Doug Gilbert
--- linux/drivers/scsi/ide-scsi.c Sat Apr 27 14:52:08 2002
+++ linux/drivers/scsi/ide-scsi.c2510dj1hack Sat Apr 27 17:36:07 2002
@@ -804,14 +804,20 @@
return 0;
}
-int idescsi_abort (Scsi_Cmnd *cmd)
+/* try to do correct thing for scsi subsystem's new eh */
+int idescsi_device_reset (Scsi_Cmnd *cmd)
{
- return SCSI_ABORT_SNOOZE;
-}
+ ide_drive_t *drive = idescsi_drives[cmd->target];
+ struct request req;
-int idescsi_reset (Scsi_Cmnd *cmd, unsigned int resetflags)
-{
- return SCSI_RESET_SUCCESS;
+ ide_init_drive_cmd(&req);
+ req.flags = REQ_SPECIAL;
+/* FIX ME, the next executable line causes on oops in lk 2.5.10-dj1
+ * [code copied from ide-cd's ide_cdrom_reset(), does it work?]
+ */
+ ide_do_drive_cmd(drive, &req, ide_wait);
+
+ return SUCCESS;
}
int idescsi_bios (Disk *disk, kdev_t dev, int *parm)
@@ -834,8 +840,8 @@
info: idescsi_info,
ioctl: idescsi_ioctl,
queuecommand: idescsi_queue,
- abort: idescsi_abort,
- reset: idescsi_reset,
+ eh_device_reset_handler:
+ idescsi_device_reset,
bios_param: idescsi_bios,
can_queue: 10,
this_id: -1,
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2002-04-27 22:44 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-04-27 22:14 [PATCH] ide-scsi 2.5.10-dj1 compilation failure Douglas Gilbert
2002-04-27 21:41 ` Martin Dalecki
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox