Bluetooth: Use unsigned int instead of signed int
authorMikel Astiz <mikel.astiz@bmw-carit.de>
Wed, 11 Apr 2012 06:48:47 +0000 (08:48 +0200)
committerGustavo Padovan <gustavo@padovan.org>
Wed, 9 May 2012 04:40:31 +0000 (01:40 -0300)
commitabc5de8f4e68ea785e32b91e456f467d2a2fb7db
treeb2b2b1e5da841384ac2315f6ea8ff31d0dfec3b8
parent59f34fb3354bb7b5f9d865ccaa2c54d3cf691cb8
Bluetooth: Use unsigned int instead of signed int

The involved values are all unsigned and thus unsigned int should be
used instead of signed int. Assigning ~0 to a signed int results in -1,
which is confusing and error-prone, while the code is trying to set the
maximum value possible.

The code still works because the C standard defines that unsigned
comparison will be performed in these cases, when comparing an unsigned
int and a signed int.

Signed-off-by: Mikel Astiz <mikel.astiz.oss@gmail.com>
Acked-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Gustavo Padovan <gustavo@padovan.org>
net/bluetooth/hci_core.c