Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'tty-3.12-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty

Pull tty fixes from Greg KH:
"Here are two tty driver fixes for 3.12-rc4.

One fixes the reported regression in the n_tty code that a number of
people found recently, and the other one fixes an issue with xen
consoles that broke in 3.10"

* tag 'tty-3.12-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty:
xen/hvc: allow xenboot console to be used again
tty: Fix pty master read() after slave closes

+27 -20
+1
drivers/tty/hvc/hvc_xen.c
··· 636 636 .name = "xenboot", 637 637 .write = xenboot_write_console, 638 638 .flags = CON_PRINTBUFFER | CON_BOOT | CON_ANYTIME, 639 + .index = -1, 639 640 }; 640 641 #endif /* CONFIG_EARLY_PRINTK */ 641 642
+26 -20
drivers/tty/n_tty.c
··· 2183 2183 2184 2184 if (!input_available_p(tty, 0)) { 2185 2185 if (test_bit(TTY_OTHER_CLOSED, &tty->flags)) { 2186 - retval = -EIO; 2187 - break; 2188 - } 2189 - if (tty_hung_up_p(file)) 2190 - break; 2191 - if (!timeout) 2192 - break; 2193 - if (file->f_flags & O_NONBLOCK) { 2194 - retval = -EAGAIN; 2195 - break; 2196 - } 2197 - if (signal_pending(current)) { 2198 - retval = -ERESTARTSYS; 2199 - break; 2200 - } 2201 - n_tty_set_room(tty); 2202 - up_read(&tty->termios_rwsem); 2186 + up_read(&tty->termios_rwsem); 2187 + tty_flush_to_ldisc(tty); 2188 + down_read(&tty->termios_rwsem); 2189 + if (!input_available_p(tty, 0)) { 2190 + retval = -EIO; 2191 + break; 2192 + } 2193 + } else { 2194 + if (tty_hung_up_p(file)) 2195 + break; 2196 + if (!timeout) 2197 + break; 2198 + if (file->f_flags & O_NONBLOCK) { 2199 + retval = -EAGAIN; 2200 + break; 2201 + } 2202 + if (signal_pending(current)) { 2203 + retval = -ERESTARTSYS; 2204 + break; 2205 + } 2206 + n_tty_set_room(tty); 2207 + up_read(&tty->termios_rwsem); 2203 2208 2204 - timeout = schedule_timeout(timeout); 2209 + timeout = schedule_timeout(timeout); 2205 2210 2206 - down_read(&tty->termios_rwsem); 2207 - continue; 2211 + down_read(&tty->termios_rwsem); 2212 + continue; 2213 + } 2208 2214 } 2209 2215 __set_current_state(TASK_RUNNING); 2210 2216