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 ...
随机推荐
- RStdio常用快捷键
掌握常用快捷键的使用, 可以让我们的效率加倍! 下面只列举了一些最常见的快捷键, RStdio的快捷键远不止这些, 具体的可以参照这里. 无论是在控制台还是在编辑区, Tab都可以帮助我们对代码进行补 ...
- ubuntu下将程序挂后台命令
ubuntu下将程序挂后台命令 nohup python -u main.py > test.out 2>&1 & ubunut下查看后台进程 jobs -l
- 从源码层次分析asterisk如何产生呼叫
老规矩,看别人是怎么搞的 http://blog.chinaunix.net/uid-14723273-id-1739552.html over...
- 基于docker 搭建Prometheus+Grafana
一.介绍Prometheus Prometheus(普罗米修斯)是一套开源的监控&报警&时间序列数据库的组合,起始是由SoundCloud公司开发的.随着发展,越来越多公司和组织接受采 ...
- gtk+学习笔记(五)
今天继续做的是昨天那个界面对的优化,直接贴下代码, void click_radio(GtkWidget *widget,gpointer *data) { 3 GtkWidget *dialog; ...
- SQL Server操作实例
创建数据库 create database accountInfo/*创建账户信息数据库*/ 创建数据表 /*定义主码.外码.和人数.余额的取值范围.*/ /*创建储蓄所表*/ create tabl ...
- https页面打不开
https://blog.csdn.net/leedaning/article/details/71552625
- CROC 2016 - Elimination Round (Rated Unofficial Edition) F - Cowslip Collections 数论 + 容斥
F - Cowslip Collections http://codeforces.com/blog/entry/43868 这个题解讲的很好... #include<bits/stdc++.h ...
- 安卓逆向之基于Xposed-ZjDroid脱壳
http://bbs.pediy.com/thread-218798.htm 前言 之前介绍了普通常见的反编译模式 但对于使用了 360加固 棒棒 爱加密 等等的加固应用就没办法了. 你会发现 ...
- 20169211《Linux内核原理与分析》课程总结
第一周作业:linux入门学习:熟悉操作linux的基础命令 第二周作业:实验反汇编一个简答的C程序,学习汇编代码的工作过程 第三周作业:学习linux内核的启动过程 第四周作业:学习linux内核进 ...