diff options
author | Loic Poulain | 2014-08-08 19:07:16 +0200 |
---|---|---|
committer | Marcel Holtmann | 2014-08-14 08:49:19 +0200 |
commit | 4807b51895dce8aa650ebebc51fa4a795ed6b8b8 (patch) | |
tree | 8030a32684c78cb7b03939e640ef58c522bd49a7 /MAINTAINERS | |
parent | Bluetooth: Convert SMP to use l2cap_chan infrastructure (diff) | |
download | kernel-qcow2-linux-4807b51895dce8aa650ebebc51fa4a795ed6b8b8.tar.gz kernel-qcow2-linux-4807b51895dce8aa650ebebc51fa4a795ed6b8b8.tar.xz kernel-qcow2-linux-4807b51895dce8aa650ebebc51fa4a795ed6b8b8.zip |
Bluetooth: Fix HCI H5 corrupted ack value
In this expression: seq = (seq - 1) % 8
seq (u8) is implicitly converted to an int in the arithmetic operation.
So if seq value is 0, operation is ((0 - 1) % 8) => (-1 % 8) => -1.
The new seq value is 0xff which is an invalid ACK value, we expect 0x07.
It leads to frequent dropped ACK and retransmission.
Fix this by using '&' binary operator instead of '%'.
Signed-off-by: Loic Poulain <loic.poulain@intel.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Cc: stable@vger.kernel.org
Diffstat (limited to 'MAINTAINERS')
0 files changed, 0 insertions, 0 deletions