Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=b0fed3140f57c435d2783b698c5090f325c22bad
Commit:     b0fed3140f57c435d2783b698c5090f325c22bad
Parent:     c2aef333c98b41eeb0f0d55b7faa7d4625a6160b
Author:     Jiri Slaby <[EMAIL PROTECTED]>
AuthorDate: Sun Jul 15 23:40:12 2007 -0700
Committer:  Linus Torvalds <[EMAIL PROTECTED]>
CommitDate: Mon Jul 16 09:05:43 2007 -0700

    Char: n_hdlc, allow RESTARTSYS retval of tty write
    
    Acked-by: Paul Fulghum <[EMAIL PROTECTED]>
    Signed-off-by: Jiri Slaby <[EMAIL PROTECTED]>
    Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
    Signed-off-by: Linus Torvalds <[EMAIL PROTECTED]>
---
 drivers/char/n_hdlc.c |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/drivers/char/n_hdlc.c b/drivers/char/n_hdlc.c
index 37f7d34..e8332f3 100644
--- a/drivers/char/n_hdlc.c
+++ b/drivers/char/n_hdlc.c
@@ -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 */
                tty->flags |= (1 << TTY_DO_WRITE_WAKEUP);
                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 */
                /* pretending it was accepted by driver */
                if (actual < 0)
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to