Linux bluetooth development
 help / color / mirror / Atom feed
* [V1] Bluetooth: btusb: Add return error code
@ 2024-03-13  5:11 Youwan Wang
  2024-03-13  5:55 ` bluez.test.bot
  2024-03-13  7:18 ` Paul Menzel
  0 siblings, 2 replies; 3+ messages in thread
From: Youwan Wang @ 2024-03-13  5:11 UTC (permalink / raw)
  To: marcel; +Cc: johan.hedberg, luiz.dentz, linux-bluetooth, Youwan Wang

Add return error code

Signed-off-by: Youwan Wang <youwan@nfschina.com>
---
 drivers/bluetooth/btusb.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c
index b8e9de887b5d..ec6bdc9687b1 100644
--- a/drivers/bluetooth/btusb.c
+++ b/drivers/bluetooth/btusb.c
@@ -2826,8 +2826,10 @@ static int btusb_mtk_hci_wmt_sync(struct hci_dev *hdev,
 		goto err_free_wc;
 	}
 
-	if (data->evt_skb == NULL)
+	if (data->evt_skb == NULL) {
+		err = -ENOBUFS;
 		goto err_free_wc;
+	}
 
 	/* Parse and handle the return WMT event */
 	wmt_evt = (struct btmtk_hci_wmt_evt *)data->evt_skb->data;
-- 
2.25.1


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

end of thread, other threads:[~2024-03-13  7:19 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-03-13  5:11 [V1] Bluetooth: btusb: Add return error code Youwan Wang
2024-03-13  5:55 ` bluez.test.bot
2024-03-13  7:18 ` Paul Menzel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox