On Thu, 4 Jan 2007, Oliver Neukum wrote:

> Hi,
> 
> quoting from the WCM spec:
> -
> The firmware shall interpret GET_ENCAPSULATED_RESPONSE as a request to read
> response bytes. The firmware shall send the next wLength bytes from the
> response. The firmware shall allow the host to retrieve data using any
> number of GET_ENCAPSULATED_RESPONSES. The firmware shall return a zero-length
> reply if there are no data bytes available.
> The firmware shall send RESPONSE_AVAILABLE notifications periodically, using
> any appropriate algorithm, to inform the host that there is data available
> in the reply buffer. The firmware is allowed to send RESPONSE_AVAILABLE
> notifications even if there is no data available, but this will obviously
> reduce overall performance.
> -
> 
> Do I read this correctly to mean that I must not treat zero bytes from
> GET_ENCAPSULATED_RESPONSE as an error, because RESPONSE_AVAILABLE
> is reliable in one direction only?

The spec certainly says that 0 bytes from GET_ENCAPSULATED_RESPONSE is not 
an error.

I don't know what you mean by "RESPONSE_AVAILABLE is reliable in one 
direction only".  The message should be treated as a hint that data may be 
available so the host should attempt to start a transfer -- but it's still 
possible that no data bytes are available.

Alan Stern


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
linux-usb-devel@lists.sourceforge.net
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to