diff options
author | Greg Kroah-Hartman | 2018-09-16 22:04:13 +0200 |
---|---|---|
committer | Greg Kroah-Hartman | 2018-09-16 22:04:13 +0200 |
commit | 7dc074348eb85d48f7a1fa96879458f4becf68a7 (patch) | |
tree | af626c941574ea68f7d74da04d81e302fbc14a68 /drivers/bluetooth/btmtkuart.c | |
parent | MAINTAINERS: remove myself as staging FBTFT maintainer (diff) | |
parent | Linux 4.19-rc4 (diff) | |
download | kernel-qcow2-linux-7dc074348eb85d48f7a1fa96879458f4becf68a7.tar.gz kernel-qcow2-linux-7dc074348eb85d48f7a1fa96879458f4becf68a7.tar.xz kernel-qcow2-linux-7dc074348eb85d48f7a1fa96879458f4becf68a7.zip |
Merge 4.19-rc4 into staging-next
Handle the merge issues and take the iio and staging driver fixes.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/bluetooth/btmtkuart.c')
-rw-r--r-- | drivers/bluetooth/btmtkuart.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/bluetooth/btmtkuart.c b/drivers/bluetooth/btmtkuart.c index ed2a5c7cb77f..4593baff2bc9 100644 --- a/drivers/bluetooth/btmtkuart.c +++ b/drivers/bluetooth/btmtkuart.c @@ -144,8 +144,10 @@ static int mtk_setup_fw(struct hci_dev *hdev) fw_size = fw->size; /* The size of patch header is 30 bytes, should be skip */ - if (fw_size < 30) - return -EINVAL; + if (fw_size < 30) { + err = -EINVAL; + goto free_fw; + } fw_size -= 30; fw_ptr += 30; @@ -172,8 +174,8 @@ static int mtk_setup_fw(struct hci_dev *hdev) fw_ptr += dlen; } +free_fw: release_firmware(fw); - return err; } |