mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git/
synced 2026-05-02 18:15:03 -04:00
tty: Combine SIGTTOU/SIGTTIN handling
The job_control() check in n_tty_read() has nearly identical purpose and results as tty_check_change(). Both functions' purpose is to determine if the current task's pgrp is the foreground pgrp for the tty, and if not, to signal the current pgrp. Introduce __tty_check_change() which takes the signal to send and performs the shared operations for job control() and tty_check_change(). Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
71a5cd8a4a
commit
2812d9e9fd
@@ -423,6 +423,7 @@ extern int tty_paranoia_check(struct tty_struct *tty, struct inode *inode,
|
||||
const char *routine);
|
||||
extern const char *tty_name(const struct tty_struct *tty);
|
||||
extern void tty_wait_until_sent(struct tty_struct *tty, long timeout);
|
||||
extern int __tty_check_change(struct tty_struct *tty, int sig);
|
||||
extern int tty_check_change(struct tty_struct *tty);
|
||||
extern void __stop_tty(struct tty_struct *tty);
|
||||
extern void stop_tty(struct tty_struct *tty);
|
||||
|
||||
Reference in New Issue
Block a user