summaryrefslogtreecommitdiff
path: root/sys/netbt/hci_socket.c
diff options
context:
space:
mode:
authorUwe Stuehler <uwe@cvs.openbsd.org>2008-11-22 04:42:59 +0000
committerUwe Stuehler <uwe@cvs.openbsd.org>2008-11-22 04:42:59 +0000
commitee43d395f23778051691eb4bfc357fa8a319dc36 (patch)
tree39f64994e1dc4a1a4688f1cd259f7a4ac2a1fa41 /sys/netbt/hci_socket.c
parent40b98550b7357a09aad4dfe870e508bc05f03705 (diff)
Sync bluetooth with NetBSD
Diffstat (limited to 'sys/netbt/hci_socket.c')
-rw-r--r--sys/netbt/hci_socket.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/sys/netbt/hci_socket.c b/sys/netbt/hci_socket.c
index 4e6fa332a9b..ca5aa5f14a3 100644
--- a/sys/netbt/hci_socket.c
+++ b/sys/netbt/hci_socket.c
@@ -1,5 +1,5 @@
-/* $OpenBSD: hci_socket.c,v 1.6 2008/05/27 19:41:14 thib Exp $ */
-/* $NetBSD: hci_socket.c,v 1.14 2008/02/10 17:40:54 plunky Exp $ */
+/* $OpenBSD: hci_socket.c,v 1.7 2008/11/22 04:42:58 uwe Exp $ */
+/* $NetBSD: hci_socket.c,v 1.17 2008/08/06 15:01:24 plunky Exp $ */
/*-
* Copyright (c) 2005 Iain Hibbert.
@@ -555,12 +555,15 @@ hci_usrreq(struct socket *up, int req, struct mbuf *m,
switch(req) {
case PRU_CONTROL:
- return hci_ioctl((unsigned long)m, (void *)nam, curproc);
+ mutex_enter(&bt_lock);
+ err = hci_ioctl((unsigned long)m, (void *)nam, curproc);
+ mutex_exit(&bt_lock);
+ return err;
case PRU_ATTACH:
+ /* XXX solock() and bt_lock fiddling in NetBSD */
if (pcb)
return EINVAL;
-
err = soreserve(up, hci_sendspace, hci_recvspace);
if (err)
return err;