More about STALL
http://fx.damasgate.com/more-about-stall/
In other USB classes, a sender can indicate the end of a transfer
by transmitting a short packet, which is a data packet that contains
zero data bytes or any quantity fewer than wMaxPacketSize.
The mass-storage class is unique in its use of the STALL handshake
to end bulk transfers. In contrast, mass-storage devices
use STALL for this purpose and to respond to other error conditions.
After a bulk endpoint returns STALL, the endpoint is in the halt condition.
To resume communications with the endpoint, the host must issue a Clear
Feature(ENDPOINT_HALT) control request with the endpoint’s address
in the Setup transaction’s wIndex field.
Endpoint zero can also use the STALL handshake. On receiving a
Get Max LUN request, a device with a single LUN may return a STALL
to indicate that the device doesn’t support the command.
The endpoint resumes normal operation on receiving a new Setup transaction.
A mass-storage device must stall one or both bulk endpoints in these situations:
If a device sends less than the requested amount of data in the data-transport phase,
the device must stall the bulk IN endpoint.
If a received CBW isn’t valid, the device must stall the bulk IN endpoint and must
either stall the bulk OUT endpoint
or accept and discard any received data on the endpoint.
On experiencing an internal error that requires a reset, a device must
either stall the endpoint being used in any data transfer in progress and set bCSWStatus = 02h
or stall the bulk IN and bulk OUT endpoints until a reset recovery.
A mass-storage device may stall a bulk endpoints in these situations:
If a device expects to send more data than the host specified in the CBW,
after sending the requested quantity of data,
the device may stall the bulk IN endpoint.
If a device expects to receive a different quantity of
data than the host specified in the CBW,
the device may stall the bulk OUT endpoint.
If a device determinines that it can’t complete a command
during the data-transport phase, the device may stall
the bulk IN or bulk OUT endpoint as appropriate.
The thirteen cases described below have more about
the use of STALL with mass-storage commands.
Thirteen Cases for Any Situation
The mass-storage bulk-only transport specification spells out
how the host and device should behave after the host sends a command
in each of thirteen cases.
Cases 1, 6, and 12 (in bold) are the normal cases,
where the host and device each expect the same quantity
and direction of data transfer in the data-transport phase.
The other cases are situations where the host and device have differing expectations.
More about STALL的更多相关文章
- POJ1274 The Perfect Stall[二分图最大匹配]
The Perfect Stall Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 23911 Accepted: 106 ...
- POJ 1274 The Perfect Stall、HDU 2063 过山车(最大流做二分匹配)
The Perfect Stall Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 24081 Accepted: 106 ...
- poj 3190 Stall Reservations
http://poj.org/problem?id=3190 Stall Reservations Time Limit: 1000MS Memory Limit: 65536K Total Su ...
- [题解]poj 1274 The Prefect Stall
Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 22736 Accepted: 10144 Description Far ...
- poj1274 The Perfect Stall (二分最大匹配)
Description Farmer John completed his new barn just last week, complete with all the latest milking ...
- Greedy:Stall Reservations(POJ 3190)
牛挤奶 题目大意:一群牛很挑剔,他们仅在一个时间段内挤奶,而且只能在一个棚里面挤,不能与其他牛共享地方,现在给你一群牛,问你如果要全部牛都挤奶,至少需要多少牛棚? 这一题如果把时间区间去掉,那就变成装 ...
- poj 1247 The Perfect Stall 裸的二分匹配,但可以用最大流来水一下
The Perfect Stall Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 16396 Accepted: 750 ...
- poj3190 stall revertation
Stall Re ...
- poj 1274 The Perfect Stall【匈牙利算法模板题】
The Perfect Stall Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 20874 Accepted: 942 ...
- BZOJ1651: [Usaco2006 Feb]Stall Reservations 专用牛棚
1651: [Usaco2006 Feb]Stall Reservations 专用牛棚 Time Limit: 10 Sec Memory Limit: 64 MBSubmit: 509 Sol ...
随机推荐
- No.16 selenium学习之路之异常处理
一.常见的几种异常: SyntaxError:语法错误 NameError:试图访问的变量名不存在 IndexError:索引错误,使用的索引不存在,超出序列范围 KeyError:使用了不存在的关键 ...
- Mat结构
主要是记录一下大牛的博客,再次感谢这些无私的博主. 这篇博客http://blog.csdn.net/yang_xian521/article/details/7107786中,我觉得要注意的是Mat ...
- luoguP2735 电网 Electric Fences
一道校内模拟赛遇见的题 ** 不会正解就真的很麻烦的 数学题 ** 有一种东西叫 皮克定理 发现的千古神犇: 姓名:George Alexander Pick(所以叫皮克定理呀 国籍:奥地利(蛤!竟然 ...
- 【笔记】jQuery插件开发指南
原文链接:http://www.cnblogs.com/Wayou/p/jquery_plugin_tutorial.html (有部分增删和修改) jQuery插件开发模式 软件开发过程中是需要一定 ...
- python_docx制作word文档
一.docx模块 Python可以利用python-docx模块处理word文档,处理方式是面向对象的.也就是说python-docx模块会把word文档,文档中的段落.文本.字体等都看做对象,对对象 ...
- 减小VirtualBox虚拟硬盘文件的大小
虚拟机使用久了就会发现虚拟硬盘越来越大,但是进入虚拟机里的系统用命令看了下,实际占用的空间远没有虚拟硬盘大小那么大,这个让人很不爽,而且在分享虚拟机镜像的时候也很不方便.VirtualBox似乎没有提 ...
- CCF CSP 201709-2 公共钥匙盒
CCF计算机职业资格认证考试题解系列文章为meelo原创,请务必以链接形式注明本文地址 CCF CSP 201709-2 公共钥匙盒 问题描述 有一个学校的老师共用N个教室,按照规定,所有的钥匙都必须 ...
- centos6编译安装zabbix3.0和中文支持整理文档
编者按: 最近公司部分业务迁移机房,为了更方便的监控管理主机资源,决定上线zabbix监控平台.运维人员使用2.4版本的进行部署,个人在业余时间尝鲜,使用zabbix3.0进行部署,整理文档如下,仅供 ...
- Haproxy 开启日志记录
CentOS 7上yum安装的Haproxy,默认没有记录日志.需要做一下配置才能记录日志.(不知道其他版本是否需要,已经忘记了)主要是用到了Haproxy,以前貌似没有这么麻烦,今天配置出了一些问题 ...
- ECSHOP中 {insert name='ads' id=$ads_id num=$ads_num}含义
<div class="smallban"> <ul> <!-- TemplateBeginEditabl ...