lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20141110154621.3adab2e4@canb.auug.org.au>
Date:	Mon, 10 Nov 2014 15:46:21 +1100
From:	Stephen Rothwell <sfr@...b.auug.org.au>
To:	Greg KH <greg@...ah.com>, Thomas Gleixner <tglx@...utronix.de>,
	Ingo Molnar <mingo@...e.hu>, "H. Peter Anvin" <hpa@...or.com>,
	Peter Zijlstra <peterz@...radead.org>
Cc:	linux-next@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: linux-next: manual merge of the tty tree with the tip tree

Hi Greg,

Today's linux-next merge of the tty tree got a conflict in
drivers/tty/n_tty.c between commit 97d9e28d1a27 ("sched, tty: Deal with
nested sleeps") from the tip tree and commits 1aa1bf111527 ("tty: Fix
missed wakeup from packet mode status update") and 52bce7f8d4fc ("pty,
n_tty: Simplify input processing on final close") from the tty tree.

I fixed it up (I hope - see below) and can carry the fix as necessary
(no action is required).

-- 
Cheers,
Stephen Rothwell                    sfr@...b.auug.org.au

diff --cc drivers/tty/n_tty.c
index 26f097f60b10,112eda7c56bc..000000000000
--- a/drivers/tty/n_tty.c
+++ b/drivers/tty/n_tty.c
@@@ -2193,46 -2197,30 +2192,30 @@@ static ssize_t n_tty_read(struct tty_st
  
  		if (!input_available_p(tty, 0)) {
  			if (test_bit(TTY_OTHER_CLOSED, &tty->flags)) {
- 				up_read(&tty->termios_rwsem);
- 				tty_flush_to_ldisc(tty);
- 				down_read(&tty->termios_rwsem);
- 				if (!input_available_p(tty, 0)) {
- 					retval = -EIO;
- 					break;
- 				}
- 			} else {
- 				if (tty_hung_up_p(file))
- 					break;
- 				if (!timeout)
- 					break;
- 				if (file->f_flags & O_NONBLOCK) {
- 					retval = -EAGAIN;
- 					break;
- 				}
- 				if (signal_pending(current)) {
- 					retval = -ERESTARTSYS;
- 					break;
- 				}
- 				n_tty_set_room(tty);
- 				up_read(&tty->termios_rwsem);
- 
- 				timeout = wait_woken(&wait, TASK_INTERRUPTIBLE,
- 						     timeout);
- 
- 				down_read(&tty->termios_rwsem);
- 				continue;
+ 				retval = -EIO;
+ 				break;
  			}
- 		}
- 
- 		/* Deal with packet mode. */
- 		if (packet && b == buf) {
- 			if (tty_put_user(tty, TIOCPKT_DATA, b++)) {
- 				retval = -EFAULT;
- 				b--;
+ 			if (tty_hung_up_p(file))
+ 				break;
+ 			if (!timeout)
+ 				break;
+ 			if (file->f_flags & O_NONBLOCK) {
+ 				retval = -EAGAIN;
  				break;
  			}
- 			nr--;
+ 			if (signal_pending(current)) {
+ 				retval = -ERESTARTSYS;
+ 				break;
+ 			}
+ 			n_tty_set_room(tty);
+ 			up_read(&tty->termios_rwsem);
+ 
 -			timeout = schedule_timeout(timeout);
++			timeout = wait_woken(&wait, TASK_INTERRUPTIBLE,
++					     timeout);
+ 
+ 			down_read(&tty->termios_rwsem);
+ 			continue;
  		}
 -		__set_current_state(TASK_RUNNING);
  
  		if (ldata->icanon && !L_EXTPROC(tty)) {
  			retval = canon_copy_from_read_buf(tty, &b, &nr);

Content of type "application/pgp-signature" skipped

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ