ttyclose() increments t_gen. Remove redundant increments in drivers.
This commit is contained in:
parent
92c9a57d01
commit
d4a4e27cd4
@ -586,7 +586,6 @@ dcons_detach(int port)
|
||||
if (tp->t_state & TS_ISOPEN) {
|
||||
printf("dcons: still opened\n");
|
||||
(*linesw[tp->t_line].l_close)(tp, 0);
|
||||
tp->t_gen++;
|
||||
ttyclose(tp);
|
||||
ttwakeup(tp);
|
||||
ttwwakeup(tp);
|
||||
|
@ -455,7 +455,6 @@ siodetach(dev)
|
||||
if (com->tp && (com->tp->t_state & TS_ISOPEN)) {
|
||||
device_printf(dev, "still open, forcing close\n");
|
||||
(*linesw[com->tp->t_line].l_close)(com->tp, 0);
|
||||
com->tp->t_gen++;
|
||||
ttyclose(com->tp);
|
||||
ttwakeup(com->tp);
|
||||
ttwwakeup(com->tp);
|
||||
|
@ -441,7 +441,6 @@ USB_ATTACH(ubser)
|
||||
if (tp != NULL) {
|
||||
if (tp->t_state & TS_ISOPEN) {
|
||||
(*linesw[tp->t_line].l_close)(tp, 0);
|
||||
tp->t_gen++;
|
||||
ttyclose(tp);
|
||||
ttwakeup(tp);
|
||||
ttwwakeup(tp);
|
||||
@ -478,7 +477,6 @@ USB_DETACH(ubser)
|
||||
if (tp != NULL) {
|
||||
if (tp->t_state & TS_ISOPEN) {
|
||||
(*linesw[tp->t_line].l_close)(tp, 0);
|
||||
tp->t_gen++;
|
||||
ttyclose(tp);
|
||||
ttwakeup(tp);
|
||||
ttwwakeup(tp);
|
||||
|
@ -214,7 +214,6 @@ ucom_detach(struct ucom_softc *sc)
|
||||
device_printf(sc->sc_dev,
|
||||
"still open, forcing close\n");
|
||||
(*linesw[tp->t_line].l_close)(tp, 0);
|
||||
tp->t_gen++;
|
||||
ttyclose(tp);
|
||||
ttwakeup(tp);
|
||||
ttwwakeup(tp);
|
||||
|
@ -783,7 +783,6 @@ siodetach(dev)
|
||||
if (com->tp && (com->tp->t_state & TS_ISOPEN)) {
|
||||
device_printf(dev, "still open, forcing close\n");
|
||||
(*linesw[com->tp->t_line].l_close)(com->tp, 0);
|
||||
com->tp->t_gen++;
|
||||
ttyclose(com->tp);
|
||||
ttwakeup(com->tp);
|
||||
ttwwakeup(com->tp);
|
||||
|
@ -783,7 +783,6 @@ siodetach(dev)
|
||||
if (com->tp && (com->tp->t_state & TS_ISOPEN)) {
|
||||
device_printf(dev, "still open, forcing close\n");
|
||||
(*linesw[com->tp->t_line].l_close)(com->tp, 0);
|
||||
com->tp->t_gen++;
|
||||
ttyclose(com->tp);
|
||||
ttwakeup(com->tp);
|
||||
ttwwakeup(com->tp);
|
||||
|
Loading…
Reference in New Issue
Block a user