Skip to content

Commit 71067fb

Browse files
Jiri Slaby (SUSE)gregkh
authored andcommitted
tty: fix kernel-doc for functions in tty.h
tty_kref_get() is already included in Documentation, but is not properly formatted. Fix this. tty_get_baud_rate() is neither properly formatted, nor is included. Fix both. Signed-off-by: "Jiri Slaby (SUSE)" <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 3b1a696 commit 71067fb

File tree

2 files changed

+12
-12
lines changed

2 files changed

+12
-12
lines changed

Documentation/driver-api/tty/tty_ioctl.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,6 @@ TTY IOCTL Helpers
55
=================
66

77
.. kernel-doc:: drivers/tty/tty_ioctl.c
8+
9+
.. kernel-doc:: include/linux/tty.h
10+
:identifiers: tty_get_baud_rate

include/linux/tty.h

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -390,14 +390,12 @@ int vcs_init(void);
390390
extern const struct class tty_class;
391391

392392
/**
393-
* tty_kref_get - get a tty reference
394-
* @tty: tty device
393+
* tty_kref_get - get a tty reference
394+
* @tty: tty device
395395
*
396-
* Return a new reference to a tty object. The caller must hold
397-
* sufficient locks/counts to ensure that their existing reference cannot
398-
* go away
396+
* Returns: a new reference to a tty object. The caller must hold sufficient
397+
* locks/counts to ensure that their existing reference cannot go away
399398
*/
400-
401399
static inline struct tty_struct *tty_kref_get(struct tty_struct *tty)
402400
{
403401
if (tty)
@@ -435,14 +433,13 @@ void tty_encode_baud_rate(struct tty_struct *tty, speed_t ibaud,
435433
speed_t obaud);
436434

437435
/**
438-
* tty_get_baud_rate - get tty bit rates
439-
* @tty: tty to query
436+
* tty_get_baud_rate - get tty bit rates
437+
* @tty: tty to query
440438
*
441-
* Returns the baud rate as an integer for this terminal. The
442-
* termios lock must be held by the caller and the terminal bit
443-
* flags may be updated.
439+
* Returns: the baud rate as an integer for this terminal. The termios lock
440+
* must be held by the caller and the terminal bit flags may be updated.
444441
*
445-
* Locking: none
442+
* Locking: none
446443
*/
447444
static inline speed_t tty_get_baud_rate(struct tty_struct *tty)
448445
{

0 commit comments

Comments
 (0)