Re: [PATCH v2 22/36] atari_scsi: Fix atari_scsi deadlocks on Falcon

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

 



On 10/27/2014 06:26 AM, Finn Thain wrote:
> Don't disable irqs when waiting for the ST DMA "lock"; its release may
> require an interrupt.
> 
> Introduce stdma_try_lock() for use in soft irq context. atari_scsi now tells
> the SCSI mid-layer to defer queueing a command if the ST DMA lock is not
> available, as per Michael's patch:
> http://marc.info/?l=linux-m68k&m=139095335824863&w=2
> 
> The falcon_got_lock variable is race prone: we can't disable IRQs while
> waiting to acquire the lock, so after acquiring it there must be some
> interval during which falcon_got_lock remains false. Introduce
> stdma_is_locked_by() to replace falcon_got_lock.
> 
> The falcon_got_lock tests in the EH handlers are incorrect these days. It
> can happen that an EH handler is called after a command completes normally.
> Remove these checks along with falcon_got_lock.
> 
> Also remove the complicated and racy fairness wait queues. If fairness is an
> issue (when SCSI competes with IDE for the ST DMA interrupt), the solution
> is likely to be a lower value for host->can_queue.
> 
> Signed-off-by: Finn Thain <fthain@xxxxxxxxxxxxxxxxxxx>
Reviewed-by: Hannes Reinecke <hare@xxxxxxx>

Cheers,

Hannes
-- 
Dr. Hannes Reinecke		      zSeries & Storage
hare@xxxxxxx			      +49 911 74053 688
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg
GF: J. Hawn, J. Guild, F. Imendörffer, HRB 16746 (AG Nürnberg)
--
To unsubscribe from this list: 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