- remove #ifdef DIAGNOSTIC, so that we won't act
differently
- handle the cases where a Bluetooth adapter
sends invalid packet data (I've not seen this,
but it is not impossible)
- use KASSERT for actual impossible situations
(to catch bad future development)
sys/stdarg.h and expect compiler to provide proper builtins, defaulting
to the GCC interface. lint still has a special fallback.
Reduce abuse of _BSD_VA_LIST_ by defining __va_list by default and
derive va_list as required by standards.
and cache the maximum ACL/SCO packet buffers.
provide an additional SIOCGBTFEAT ioctl to retrieve the cached
features, and add the max values to the SIOC?BTINFO results.
(btreq does not change size)
setup, using the handle that they have not yet told us for the
connection-to-be. Disconnecting can cause problems so just ignore
zero length ACL packets on unknown connection handles.
fixes a problem reported by Nick Hudson
party requests must be less than the one we asked for which will not
be greater than the max acceptable value so no need to test for that
but make sure that it is not smaller than minimum acceptable value.
most cases, use a proper constructor. For proplib, give a local
equivalent of POOL_INIT for the kernel object implementation. This
way the code structure can be preserved, and a local link set is
not hazardous anyway (unless proplib is split to several modules,
but that'll be the day).
tested by booting a kernel in qemu and compile-testing i386/ALL
some requests to the device scope:
KAUTH_DEVICE_BLUETOOTH_SEND_COMMAND
KAUTH_DEVICE_BLUETOOTH_RECV_COMMAND
KAUTH_DEVICE_BLUETOOTH_RECV_EVENT
KAUTH_DEVICE_BLUETOOTH_RECV_DATA
and a listener tied to the HCI protocol that will approve the basic
minimum to be sent and received.
handle the requests in the bsd44_suser listener by approving all
when the credential is root.
- Socket layer becomes MP safe.
- Unix protocols become MP safe.
- Allows protocol processing interrupts to safely block on locks.
- Fixes a number of race conditions.
With much feedback from matt@ and plunky@.
reason and the command_status event returns failure but we get no
indication of which connection failed (for instance in the case where
we tried to open too many connections all at once)
So, keep a flag on the link to indicate pending status until the
command_status event is returned to help us decide which should
be failed.
to remove the frobbing that drivers must do in the hci_unit structure.
- driver provides a static const interface descriptor
- hci_unit is allocated by hci_attach() rather than part of softc
- statistics are compiled by driver and provided on request
- driver provides output methods and is responsible for output queue
- stack provides input methods and is responsible for input queue
- mutex is used to arbitrate device queue access
make bluetooth stack keep device_t instead of softc pointer as
device is not necessarily part of softc, and pass device_t to
driver callbacks. hci_devname is no longer required.