aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ppp_synctty.c
diff options
context:
space:
mode:
authorAndrea Bastoni <bastoni@cs.unc.edu>2010-05-30 19:16:45 -0400
committerAndrea Bastoni <bastoni@cs.unc.edu>2010-05-30 19:16:45 -0400
commitada47b5fe13d89735805b566185f4885f5a3f750 (patch)
tree644b88f8a71896307d71438e9b3af49126ffb22b /drivers/net/ppp_synctty.c
parent43e98717ad40a4ae64545b5ba047c7b86aa44f4f (diff)
parent3280f21d43ee541f97f8cda5792150d2dbec20d5 (diff)
Merge branch 'wip-2.6.34' into old-private-masterarchived-private-master
Diffstat (limited to 'drivers/net/ppp_synctty.c')
-rw-r--r--drivers/net/ppp_synctty.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/drivers/net/ppp_synctty.c b/drivers/net/ppp_synctty.c
index d2fa2db13586..52938da1e542 100644
--- a/drivers/net/ppp_synctty.c
+++ b/drivers/net/ppp_synctty.c
@@ -44,6 +44,7 @@
44#include <linux/spinlock.h> 44#include <linux/spinlock.h>
45#include <linux/completion.h> 45#include <linux/completion.h>
46#include <linux/init.h> 46#include <linux/init.h>
47#include <linux/slab.h>
47#include <asm/uaccess.h> 48#include <asm/uaccess.h>
48 49
49#define PPP_VERSION "2.4.2" 50#define PPP_VERSION "2.4.2"
@@ -378,10 +379,7 @@ ppp_sync_poll(struct tty_struct *tty, struct file *file, poll_table *wait)
378 return 0; 379 return 0;
379} 380}
380 381
381/* 382/* May sleep, don't call from interrupt level or with interrupts disabled */
382 * This can now be called from hard interrupt level as well
383 * as soft interrupt level or mainline.
384 */
385static void 383static void
386ppp_sync_receive(struct tty_struct *tty, const unsigned char *buf, 384ppp_sync_receive(struct tty_struct *tty, const unsigned char *buf,
387 char *cflags, int count) 385 char *cflags, int count)
@@ -665,8 +663,8 @@ ppp_sync_push(struct syncppp *ap)
665 } 663 }
666 /* haven't made any progress */ 664 /* haven't made any progress */
667 spin_unlock_bh(&ap->xmit_lock); 665 spin_unlock_bh(&ap->xmit_lock);
668 if (!(test_bit(XMIT_WAKEUP, &ap->xmit_flags) 666 if (!(test_bit(XMIT_WAKEUP, &ap->xmit_flags) ||
669 || (!tty_stuffed && ap->tpkt))) 667 (!tty_stuffed && ap->tpkt)))
670 break; 668 break;
671 if (!spin_trylock_bh(&ap->xmit_lock)) 669 if (!spin_trylock_bh(&ap->xmit_lock))
672 break; 670 break;