mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 19:51:31 -04:00
xen-scsifront: don't deadlock if the ring becomes full
scsifront_action_handler() will deadlock on host->host_lock, if the ring is full and it has to wait for entries to become available. Signed-off-by: David Vrabel <[email protected]> Reviewed-by: Juergen Gross <[email protected]>
This commit is contained in:
parent
f955371ca9
commit
7921a11c7b
1 changed files with 2 additions and 1 deletions
|
|
@ -541,8 +541,9 @@ static int scsifront_action_handler(struct scsi_cmnd *sc, uint8_t act)
|
|||
if (!shadow)
|
||||
return FAILED;
|
||||
|
||||
spin_lock_irq(host->host_lock);
|
||||
|
||||
for (;;) {
|
||||
spin_lock_irq(host->host_lock);
|
||||
if (!RING_FULL(&info->ring)) {
|
||||
ring_req = scsifront_command2ring(info, sc, shadow);
|
||||
if (ring_req)
|
||||
|
|
|
|||
Loading…
Reference in a new issue