[lkml]   [2008]   [Sep]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH] USB: g_file_storage: fix handling zero-length packet
On Saturday 06 September 2008, Alan Stern wrote:
> Secondly, the patch is not needed.  g_file_storage doesn't have to
> check whether the data size is a multiple of MaxPacketSize because the
> device controller driver already is supposed to make that check.


The only fuzziness here is what to do if the host misbehaves and
sends another IN packet when all its data has been sent, instead
of the OUT/STATUS packet. (Host error...)

Most peripheral controller hardware is well enough designed that
it can detect this and send a zero length packet rather than STALL
the transfer. It's polite to do so, because that host bug isn't
exactly unknown. (Some old versions of Linux did that...)
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2008-09-07 06:37    [W:0.055 / U:2.580 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site