linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1 0/3] Bluetooth: fix recv_buf() return value
@ 2023-11-27 19:14 Francesco Dolcini
  2023-11-27 19:14 ` [PATCH v1 1/3] Bluetooth: btnxpuart: " Francesco Dolcini
                   ` (3 more replies)
  0 siblings, 4 replies; 12+ messages in thread
From: Francesco Dolcini @ 2023-11-27 19:14 UTC (permalink / raw)
  To: Sean Wang, Marcel Holtmann, Johan Hedberg, Luiz Augusto von Dentz,
	Matthias Brugger, AngeloGioacchino Del Regno, Amitkumar Karwar,
	Neeraj Kale
  Cc: Francesco Dolcini, linux-bluetooth, linux-mediatek, linux-kernel,
	linux-arm-kernel, Jiri Slaby, linux-serial

From: Francesco Dolcini <francesco.dolcini@toradex.com>

Serdev recv_buf() callback is supposed to return the amount of bytes consumed, therefore an int in between 0 and count.

Do not return negative number in case of issue, just print an error and return count. This fixes a WARN in ttyport_receive_buf().

In addition to that a small cleanup patch is added on btnxpuart to remove a useless assignment.

Francesco Dolcini (3):
  Bluetooth: btnxpuart: fix recv_buf() return value
  Bluetooth: btmtkuart: fix recv_buf() return value
  Bluetooth: btnxpuart: remove useless assignment

 drivers/bluetooth/btmtkuart.c | 11 +++--------
 drivers/bluetooth/btnxpuart.c |  8 +++-----
 2 files changed, 6 insertions(+), 13 deletions(-)

-- 
2.25.1


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2023-11-28  7:40 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-11-27 19:14 [PATCH v1 0/3] Bluetooth: fix recv_buf() return value Francesco Dolcini
2023-11-27 19:14 ` [PATCH v1 1/3] Bluetooth: btnxpuart: " Francesco Dolcini
2023-11-27 19:24   ` Greg KH
2023-11-27 20:39   ` Bluetooth: " bluez.test.bot
2023-11-28  5:23   ` [PATCH v1 1/3] Bluetooth: btnxpuart: " Jiri Slaby
2023-11-28  7:40     ` Francesco Dolcini
2023-11-27 19:14 ` [PATCH v1 2/3] Bluetooth: btmtkuart: " Francesco Dolcini
2023-11-27 19:14 ` [PATCH v1 3/3] Bluetooth: btnxpuart: remove useless assignment Francesco Dolcini
2023-11-28  5:26   ` Jiri Slaby
2023-11-28  7:31     ` Francesco Dolcini
2023-11-27 19:23 ` [PATCH v1 0/3] Bluetooth: fix recv_buf() return value Francesco Dolcini
2023-11-28  5:17   ` Jiri Slaby

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).