diff options
author | Mike Christie <michaelc@cs.wisc.edu> | 2008-07-11 19:50:35 -0500 |
---|---|---|
committer | James Bottomley <James.Bottomley@HansenPartnership.com> | 2008-07-26 15:14:50 -0400 |
commit | ecefe8a97577d6c1a68d14ab6fb19bce99448af2 (patch) | |
tree | 966860cc4ac9069b98f1b441f3d8b12675b9087a /drivers/serial/ucc_uart.c | |
parent | 5d90027fb579eee41ec1b61f23195ed2fdd51da2 (diff) |
[SCSI] fix shared tag map tag allocation
When drivers use a shared tag map we can end up with more requests
than tags, because the tag map is shost->can_queue tags and there
can be sdevs * sdev->queue_depth requests. In scsi_request_fn
if tag allocation fails we just drop down to just dequeueing the
tag without a tag. The problem is that drivers using the shared tag
map rely on a valid tag always being set, because it will use the
tag number to lookup commands later.
This patch has us check if we got a valid tag when the host lock
is held right before we check if the host queue is ready. We do the
check here because to allocate the tag we need the q lock, but
if the tag is bad we want to add the device/q onto the starved list
which requires the host lock.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers/serial/ucc_uart.c')
0 files changed, 0 insertions, 0 deletions