]> git.baikalelectronics.ru Git - kernel.git/commit
Bluetooth: Fix checking for valid device class values
authorJohan Hedberg <johan.hedberg@intel.com>
Wed, 9 Jan 2013 13:29:35 +0000 (15:29 +0200)
committerGustavo Padovan <gustavo.padovan@collabora.co.uk>
Thu, 10 Jan 2013 08:09:07 +0000 (06:09 -0200)
commit6fcf1a99fecd9124167176f1417c0e0a3a563253
tree677812b750e51e31090123be2320267d74582476
parent4a529deb6a5e5226d7e9bf95588c634479f6643d
Bluetooth: Fix checking for valid device class values

The two lowest bits of the minor device class value are reserved and
should be zero, and the three highest bits of the major device class
likewise. The management code should therefore test for this and return
a proper "invalid params" error if the condition is not met.

Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Acked-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
net/bluetooth/mgmt.c