Greg, here are a couple of old patches that seem to have gotten lost in the shuffle. Please apply.
Matt ----- Forwarded message from Alan Stern <[EMAIL PROTECTED]> ----- Date: Mon, 15 Dec 2003 14:28:06 -0500 (EST) From: Alan Stern <[EMAIL PROTECTED]> Subject: Old patches (as129 and as141) To: Matthew Dharm <[EMAIL PROTECTED]> cc: USB Storage List <[EMAIL PROTECTED]> X-Spam-Status: No, hits=-1.6 required=5.0 tests=AWL,PATCH_UNIFIED_DIFF,SPAM_PHRASE_02_03,USER_AGENT_PINE version=2.44 Matt: There's a couple of old patches floating around still that you might want to apply. I have reproduced them below. as129 handles the situation where a command error causes us to do a device reset, but the SCSI layer times out and aborts the command during the reset delay. It clears a flag that otherwise will prevent us from sending the clear-halt messages following the reset. as141 is the DMA buffer alignment patch. You asked me to remind you about it eventually. There shouldn't be any harm at all in applying it without waiting for the corresponding SCSI part of the patch to be applied. Without that other part, this will essentially do nothing. Alan Stern ===== transport.c 1.112 vs edited ===== --- 1.112/drivers/usb/storage/transport.c Fri Sep 26 12:37:45 2003 +++ edited/drivers/usb/storage/transport.c Tue Nov 4 10:48:15 2003 @@ -1080,6 +1080,9 @@ return FAILED; } + /* permit the clear-halt transfers to take place */ + clear_bit(US_FLIDX_ABORTING, &us->flags); + US_DEBUGP("Soft reset: clearing bulk-in endpoint halt\n"); result = usb_stor_clear_halt(us, us->recv_bulk_pipe); ===== scsiglue.c 1.60 vs edited ===== --- 1.60/drivers/usb/storage/scsiglue.c Fri Oct 24 14:53:38 2003 +++ edited/drivers/usb/storage/scsiglue.c Fri Nov 21 12:45:21 2003 @@ -65,6 +65,16 @@ static int slave_configure (struct scsi_device *sdev) { + /* Scatter-gather buffers (all but the last) must have a length + * divisible by the bulk maxpacket size. Otherwise a data packet + * would end up being short, causing a premature end to the data + * transfer. Since high-speed bulk pipes have a maxpacket size + * of 512, we'll use that as the scsi device queue's DMA alignment + * mask. Guaranteeing proper alignment of the first buffer will + * have the desired effect because, except at the beginning and + * the end, scatter-gather buffers follow page boundaries. */ + blk_queue_dma_alignment(sdev->request_queue, (512 - 1)); + /* this is to satisify the compiler, tho I don't think the * return code is ever checked anywhere. */ return 0; ----- End forwarded message ----- -- Matthew Dharm Home: [EMAIL PROTECTED] Maintainer, Linux USB Mass Storage Driver Okay, this isn't funny anymore! Let me down! I'll tell Bill on you!! -- Microsoft Salesman User Friendly, 4/1/1998
pgp00000.pgp
Description: PGP signature