mirror of
https://github.com/freebsd/freebsd-src
synced 2024-09-30 05:36:10 +00:00
Merge from sio.c rev.1.163:
Don't call timeout() for DTR wakeup if the relevant timeout is already active. This fixes "timeout table full" panics when sufficiently many cyopen()s are interrupted while they are sleeping waiting for the timeout to expire.
This commit is contained in:
parent
23284b1756
commit
4635f7acc0
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=41385
|
@ -27,7 +27,7 @@
|
|||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* $Id: cy.c,v 1.73 1998/11/22 17:40:32 bde Exp $
|
||||
* $Id: cy.c,v 1.74 1998/11/23 13:58:55 bde Exp $
|
||||
*/
|
||||
|
||||
#include "opt_compat.h"
|
||||
|
@ -931,7 +931,7 @@ comhardclose(com)
|
|||
| CD1400_CCR_RCVDIS;
|
||||
cd1400_channel_cmd(com, com->channel_control);
|
||||
|
||||
if (com->dtr_wait != 0) {
|
||||
if (com->dtr_wait != 0 && !(com->state & CS_DTR_OFF)) {
|
||||
timeout(siodtrwakeup, com, com->dtr_wait);
|
||||
com->state |= CS_DTR_OFF;
|
||||
}
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* $Id: cy.c,v 1.73 1998/11/22 17:40:32 bde Exp $
|
||||
* $Id: cy.c,v 1.74 1998/11/23 13:58:55 bde Exp $
|
||||
*/
|
||||
|
||||
#include "opt_compat.h"
|
||||
|
@ -931,7 +931,7 @@ comhardclose(com)
|
|||
| CD1400_CCR_RCVDIS;
|
||||
cd1400_channel_cmd(com, com->channel_control);
|
||||
|
||||
if (com->dtr_wait != 0) {
|
||||
if (com->dtr_wait != 0 && !(com->state & CS_DTR_OFF)) {
|
||||
timeout(siodtrwakeup, com, com->dtr_wait);
|
||||
com->state |= CS_DTR_OFF;
|
||||
}
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* $Id: cy.c,v 1.73 1998/11/22 17:40:32 bde Exp $
|
||||
* $Id: cy.c,v 1.74 1998/11/23 13:58:55 bde Exp $
|
||||
*/
|
||||
|
||||
#include "opt_compat.h"
|
||||
|
@ -931,7 +931,7 @@ comhardclose(com)
|
|||
| CD1400_CCR_RCVDIS;
|
||||
cd1400_channel_cmd(com, com->channel_control);
|
||||
|
||||
if (com->dtr_wait != 0) {
|
||||
if (com->dtr_wait != 0 && !(com->state & CS_DTR_OFF)) {
|
||||
timeout(siodtrwakeup, com, com->dtr_wait);
|
||||
com->state |= CS_DTR_OFF;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue