diff options
author | Marcel Holtmann <marcel@holtmann.org> | 2015-06-07 09:47:08 +0200 |
---|---|---|
committer | Johan Hedberg <johan.hedberg@intel.com> | 2015-06-09 10:41:49 +0300 |
commit | e66890a96abbb746e1229c3067471be36dc49b34 (patch) | |
tree | 3fca106502e3f4f0e9887b7393e7d46c1329a567 /net | |
parent | 8b76ce34c43a569f981623485c1b6c700594678e (diff) |
Bluetooth: btusb: Fix secure send command length alignment on Intel 8260
This patch fixes the command length alignment issue for Intel Bluetooth
8260.
The length of parameters in the firmware downloading command must be
multiplication of 4. If not, the command must append Intel_NOP command
with extra parameters, zeros, at the end, and the firmware file is
already included Intel_NOP command for alignment.
This patch checks the next command and if the next command is Intel_NOP
command, it reads the Intel_NOP command and send them together.
For example, if the data from the firmware file looks like this:
8E FC 03 11 22 33 02 FC 03 00 00 00
Previously, btusb sends two commands:
09 FC 06 8E FC 03 11 22 33
09 FC 06 02 FC 03 00 00 00
This won't work because the length of parameters are 6 which violates
the 4 byte alignment.
This patch will append them together and send as one command:
09 FC 0C 8E FC 03 11 22 33 02 FC 03 00 00 00
Based on previous work from Tedd Ho-Jeong An <tedd.an@intel.com>
Reported-by: Tedd Ho-Jeong An <tedd.an@intel.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Tested-by: Tedd Ho-Jeong An <tedd.an@intel.com>
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Cc: stable@vger.kernel.org
Diffstat (limited to 'net')
0 files changed, 0 insertions, 0 deletions