summaryrefslogtreecommitdiffstats
path: root/drivers/bluetooth/hci_ll.c
diff options
context:
space:
mode:
authorGustavo F. Padovan <padovan@profusion.mobi>2010-05-01 21:15:34 +0200
committerMarcel Holtmann <marcel@holtmann.org>2010-05-10 09:28:45 +0200
commitfe1aff710756ac73c455d214845c74e304d0e966 (patch)
treeb561c36d75a6b190ba95aab5b5234913af844d74 /drivers/bluetooth/hci_ll.c
parentipv4: remove ip_rt_secret timer (v4) (diff)
downloadlinux-fe1aff710756ac73c455d214845c74e304d0e966.tar.xz
linux-fe1aff710756ac73c455d214845c74e304d0e966.zip
Bluetooth: Fix return value when bt_skb_alloc fails
Set the proper error(ENOMEM), instead of just return 0. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'drivers/bluetooth/hci_ll.c')
-rw-r--r--drivers/bluetooth/hci_ll.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/bluetooth/hci_ll.c b/drivers/bluetooth/hci_ll.c
index 5c65014635be..91e44df84486 100644
--- a/drivers/bluetooth/hci_ll.c
+++ b/drivers/bluetooth/hci_ll.c
@@ -491,7 +491,7 @@ static int ll_recv(struct hci_uart *hu, void *data, int count)
BT_ERR("Can't allocate mem for new packet");
ll->rx_state = HCILL_W4_PACKET_TYPE;
ll->rx_count = 0;
- return 0;
+ return -ENOMEM;
}
ll->rx_skb->dev = (void *) hu->hdev;