All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 8/10] st must check phys and hw segments limits now
@ 2005-11-08 10:06 Mike Christie
  0 siblings, 0 replies; only message in thread
From: Mike Christie @ 2005-11-08 10:06 UTC (permalink / raw)
  To: axboe, linux-scsi

We have two segments limitations. Previously
st made its own scatterlists that got sent to LLDs
so it could ignore max_phys_segments.

Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>

diff --git a/drivers/scsi/st.c b/drivers/scsi/st.c
index 2d8592d..5e61e48 100644
--- a/drivers/scsi/st.c
+++ b/drivers/scsi/st.c
@@ -3889,7 +3889,8 @@ static int st_probe(struct device *dev)
 		return -ENODEV;
 	}
 
-	i = SDp->host->sg_tablesize;
+	i = min(SDp->request_queue->max_hw_segments,
+		SDp->request_queue->max_phys_segments);
 	if (st_max_sg_segs < i)
 		i = st_max_sg_segs;
 	buffer = new_tape_buffer(1, (SDp->host)->unchecked_isa_dma, i);



^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2005-11-08 10:07 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-11-08 10:06 [PATCH 8/10] st must check phys and hw segments limits now Mike Christie

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.