Re: sleeping in scsi EH

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

 



On Thu, May 26, 2005 at 10:26:40PM -0400, Jeff Garzik wrote:
> 
> What are the rules for sleeping (msleep, etc.) in the normal EH hooks?
> 
>         int (* eh_abort_handler)(struct scsi_cmnd *);
>         int (* eh_device_reset_handler)(struct scsi_cmnd *);
>         int (* eh_bus_reset_handler)(struct scsi_cmnd *);
>         int (* eh_host_reset_handler)(struct scsi_cmnd *);
> 
> If I could sleep in these functions, then I could eliminate libata's use 
> of ->eh_strategy_handler().

You can sleep in them.  You must however release the host lock and enable
irqs first and reverse that before returning.  The error handlers don't
need the host lock, but we're stuck with the unfortunate calling convention
for now.

-
: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux