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

tty: ttyprintk: convert to u8 and size_t

Switch character types to u8 and sizes to size_t. To conform to
characters/sizes in the rest of the tty layer.

Signed-off-by: "Jiri Slaby (SUSE)" <jirislaby@kernel.org>
Cc: Arnd Bergmann <arnd@arndb.de>
Link: https://lore.kernel.org/r/20231206073712.17776-26-jirislaby@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Jiri Slaby (SUSE) and committed by
Greg Kroah-Hartman
18977909 14abfd0c

+3 -3
+3 -3
drivers/char/ttyprintk.c
··· 40 40 41 41 static int tpk_curr; 42 42 43 - static char tpk_buffer[TPK_STR_SIZE + 4]; 43 + static u8 tpk_buffer[TPK_STR_SIZE + 4]; 44 44 45 45 static void tpk_flush(void) 46 46 { ··· 51 51 } 52 52 } 53 53 54 - static int tpk_printk(const u8 *buf, int count) 54 + static int tpk_printk(const u8 *buf, size_t count) 55 55 { 56 - int i; 56 + size_t i; 57 57 58 58 for (i = 0; i < count; i++) { 59 59 if (tpk_curr >= TPK_STR_SIZE) {