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.

tty: mmc: sdio_uart: switch sdio_in() to return u8

sdio_in() returns a value returned from sdio_readb(). The latter returns
u8. So should the former. Therefore, switch sdio_in() return type to u8
and all its callers too.

Signed-off-by: "Jiri Slaby (SUSE)" <jirislaby@kernel.org>
Cc: Ulf Hansson <ulf.hansson@linaro.org>
Cc: linux-mmc@vger.kernel.org
Link: https://lore.kernel.org/r/20231206073712.17776-3-jirislaby@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Jiri Slaby (SUSE) and committed by
Greg Kroah-Hartman
e93102be e01b5712

+8 -11
+8 -11
drivers/mmc/core/sdio_uart.c
··· 178 178 sdio_release_host(port->func); 179 179 } 180 180 181 - static inline unsigned int sdio_in(struct sdio_uart_port *port, int offset) 181 + static inline u8 sdio_in(struct sdio_uart_port *port, int offset) 182 182 { 183 - unsigned char c; 184 - c = sdio_readb(port->func, port->regs_offset + offset, NULL); 185 - return c; 183 + return sdio_readb(port->func, port->regs_offset + offset, NULL); 186 184 } 187 185 188 186 static inline void sdio_out(struct sdio_uart_port *port, int offset, int value) ··· 190 192 191 193 static unsigned int sdio_uart_get_mctrl(struct sdio_uart_port *port) 192 194 { 193 - unsigned char status; 194 195 unsigned int ret; 196 + u8 status; 195 197 196 198 /* FIXME: What stops this losing the delta bits and breaking 197 199 sdio_uart_check_modem_status ? */ ··· 352 354 sdio_out(port, UART_IER, port->ier); 353 355 } 354 356 355 - static void sdio_uart_receive_chars(struct sdio_uart_port *port, 356 - unsigned int *status) 357 + static void sdio_uart_receive_chars(struct sdio_uart_port *port, u8 *status) 357 358 { 358 - unsigned int ch, flag; 359 + unsigned int flag; 359 360 int max_count = 256; 360 361 361 362 do { 362 - ch = sdio_in(port, UART_RX); 363 + u8 ch = sdio_in(port, UART_RX); 363 364 flag = TTY_NORMAL; 364 365 port->icount.rx++; 365 366 ··· 446 449 447 450 static void sdio_uart_check_modem_status(struct sdio_uart_port *port) 448 451 { 449 - int status; 450 452 struct tty_struct *tty; 453 + u8 status; 451 454 452 455 status = sdio_in(port, UART_MSR); 453 456 ··· 496 499 static void sdio_uart_irq(struct sdio_func *func) 497 500 { 498 501 struct sdio_uart_port *port = sdio_get_drvdata(func); 499 - unsigned int iir, lsr; 502 + u8 iir, lsr; 500 503 501 504 /* 502 505 * In a few places sdio_uart_irq() is called directly instead of