aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/nfc/s3fwrn5/uart.c
Commit message (Collapse)AuthorAgeFilesLines
* treewide, serdev: change receive_buf() return type to size_tFrancesco Dolcini2024-01-281-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | receive_buf() is called from ttyport_receive_buf() that expects values ">= 0" from serdev_controller_receive_buf(), change its return type from ssize_t to size_t. The need for this clean-up was noticed while fixing a warning, see commit 94d053942544 ("Bluetooth: btnxpuart: fix recv_buf() return value"). Changing the callback prototype to return an unsigned seems the best way to document the API and ensure that is properly used. GNSS drivers implementation of serdev receive_buf() callback return directly the return value of gnss_insert_raw(). gnss_insert_raw() returns a signed int, however this is not an issue since the value returned is always positive, because of the kfifo_in() implementation. gnss_insert_raw() could be changed to return also an unsigned, however this is not implemented here as request by the GNSS maintainer Johan Hovold. Suggested-by: Jiri Slaby <[email protected]> Link: https://lore.kernel.org/all/[email protected]/ Signed-off-by: Francesco Dolcini <[email protected]> Acked-by: Jonathan Cameron <[email protected]> #for-iio Reviewed-by: Johan Hovold <[email protected]> Reviewed-by: Rob Herring <[email protected]> Reviewed-by: Alex Elder <[email protected]> Acked-by: Maximilian Luz <[email protected]> # for platform/surface Acked-by: Lee Jones <[email protected]> Acked-by: Ilpo Järvinen <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
* tty: serdev: convert to u8 and size_tJiri Slaby (SUSE)2023-12-081-3/+2
| | | | | | | | | | | | | | Switch character types to u8 and sizes to size_t. To conform to characters/sizes in the rest of the tty layer. This patch converts struct serdev_device_ops hooks and its instantiations. Signed-off-by: "Jiri Slaby (SUSE)" <[email protected]> Cc: Rob Herring <[email protected]> Acked-by: Johan Hovold <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
* nfc: s3fwrn5: Support a UART interfaceBongsu Jeon2020-12-031-0/+196
Since S3FWRN82 NFC Chip, The UART interface can be used. S3FWRN82 uses NCI protocol and supports I2C and UART interface. Reviewed-by: Krzysztof Kozlowski <[email protected]> Signed-off-by: Bongsu Jeon <[email protected]> Signed-off-by: Jakub Kicinski <[email protected]>