• Alan Stern's avatar
    [PATCH] USB Storage: Handle excess 0-length data packets · 933d87fc
    Alan Stern authored
    This patch is an attempt to cope with Genesys Logic's, shall we say,
    creative approach to implementing the USB protocols.  Their high-speed
    mass storage devices sometimes add an excess 0-length packet to the end of
    a data phase transmission.  Of course we don't read that packet as part of
    the data phase; we see it as a 0-length CSW message.  The real CSW follows
    immediately after.  (Or sometimes a STALL follows immediately after, with
    the real CSW coming after that!)
    
    The patch checks the results of the first attempt to read the CSW.  If it
    sees a normal packet (not a STALL) with length 0, it retries the read.
    Reports from two users indicate that it improves the performance of their
    USB-2 DVD drives.
    933d87fc
transport.c 35.7 KB