Skip to content
Snippets Groups Projects
Commit b0fed314 authored by Jiri Slaby's avatar Jiri Slaby Committed by Linus Torvalds
Browse files

Char: n_hdlc, allow RESTARTSYS retval of tty write

parent c2aef333
No related branches found
No related tags found
No related merge requests found
...@@ -400,7 +400,12 @@ static void n_hdlc_send_frames(struct n_hdlc *n_hdlc, struct tty_struct *tty) ...@@ -400,7 +400,12 @@ static void n_hdlc_send_frames(struct n_hdlc *n_hdlc, struct tty_struct *tty)
/* Send the next block of data to device */ /* Send the next block of data to device */
tty->flags |= (1 << TTY_DO_WRITE_WAKEUP); tty->flags |= (1 << TTY_DO_WRITE_WAKEUP);
actual = tty->driver->write(tty, tbuf->buf, tbuf->count); actual = tty->driver->write(tty, tbuf->buf, tbuf->count);
/* rollback was possible and has been done */
if (actual == -ERESTARTSYS) {
n_hdlc->tbuf = tbuf;
break;
}
/* if transmit error, throw frame away by */ /* if transmit error, throw frame away by */
/* pretending it was accepted by driver */ /* pretending it was accepted by driver */
if (actual < 0) if (actual < 0)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment