diff options
author | Jiri Slaby <jslaby@suse.cz> | 2013-03-07 07:12:27 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-03-18 19:19:05 -0400 |
commit | 6865ff222ccab371c04afce17aec1f7d70b17dbc (patch) | |
tree | c5fb3ebecb698f8735e52fd7bdcbcb69e3a99f86 /include/linux/tty.h | |
parent | 049b539b39977fc9343056435eba568fc7779970 (diff) |
TTY: do not warn about setting speed via SPD_*
The warning is there since 2.1.69 and we have not seen anybody
reporting it in the past decade. Remove the warning now.
tty_get_baud_rate can now be inline. This gives us one less
EXPORT_SYMBOL.
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/tty.h')
-rw-r--r-- | include/linux/tty.h | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/include/linux/tty.h b/include/linux/tty.h index 189ca80494d1..63b62865c8e9 100644 --- a/include/linux/tty.h +++ b/include/linux/tty.h | |||
@@ -255,7 +255,6 @@ struct tty_struct { | |||
255 | int count; | 255 | int count; |
256 | struct winsize winsize; /* termios mutex */ | 256 | struct winsize winsize; /* termios mutex */ |
257 | unsigned char stopped:1, hw_stopped:1, flow_stopped:1, packet:1; | 257 | unsigned char stopped:1, hw_stopped:1, flow_stopped:1, packet:1; |
258 | unsigned char warned:1; | ||
259 | unsigned char ctrl_status; /* ctrl_lock */ | 258 | unsigned char ctrl_status; /* ctrl_lock */ |
260 | unsigned int receive_room; /* Bytes free for queue */ | 259 | unsigned int receive_room; /* Bytes free for queue */ |
261 | int flow_change; | 260 | int flow_change; |
@@ -437,13 +436,28 @@ extern void tty_flush_to_ldisc(struct tty_struct *tty); | |||
437 | extern void tty_buffer_free_all(struct tty_port *port); | 436 | extern void tty_buffer_free_all(struct tty_port *port); |
438 | extern void tty_buffer_flush(struct tty_struct *tty); | 437 | extern void tty_buffer_flush(struct tty_struct *tty); |
439 | extern void tty_buffer_init(struct tty_port *port); | 438 | extern void tty_buffer_init(struct tty_port *port); |
440 | extern speed_t tty_get_baud_rate(struct tty_struct *tty); | ||
441 | extern speed_t tty_termios_baud_rate(struct ktermios *termios); | 439 | extern speed_t tty_termios_baud_rate(struct ktermios *termios); |
442 | extern speed_t tty_termios_input_baud_rate(struct ktermios *termios); | 440 | extern speed_t tty_termios_input_baud_rate(struct ktermios *termios); |
443 | extern void tty_termios_encode_baud_rate(struct ktermios *termios, | 441 | extern void tty_termios_encode_baud_rate(struct ktermios *termios, |
444 | speed_t ibaud, speed_t obaud); | 442 | speed_t ibaud, speed_t obaud); |
445 | extern void tty_encode_baud_rate(struct tty_struct *tty, | 443 | extern void tty_encode_baud_rate(struct tty_struct *tty, |
446 | speed_t ibaud, speed_t obaud); | 444 | speed_t ibaud, speed_t obaud); |
445 | |||
446 | /** | ||
447 | * tty_get_baud_rate - get tty bit rates | ||
448 | * @tty: tty to query | ||
449 | * | ||
450 | * Returns the baud rate as an integer for this terminal. The | ||
451 | * termios lock must be held by the caller and the terminal bit | ||
452 | * flags may be updated. | ||
453 | * | ||
454 | * Locking: none | ||
455 | */ | ||
456 | static inline speed_t tty_get_baud_rate(struct tty_struct *tty) | ||
457 | { | ||
458 | return tty_termios_baud_rate(&tty->termios); | ||
459 | } | ||
460 | |||
447 | extern void tty_termios_copy_hw(struct ktermios *new, struct ktermios *old); | 461 | extern void tty_termios_copy_hw(struct ktermios *new, struct ktermios *old); |
448 | extern int tty_termios_hw_change(struct ktermios *a, struct ktermios *b); | 462 | extern int tty_termios_hw_change(struct ktermios *a, struct ktermios *b); |
449 | extern int tty_set_termios(struct tty_struct *tty, struct ktermios *kt); | 463 | extern int tty_set_termios(struct tty_struct *tty, struct ktermios *kt); |