Commit 43b79209 authored by Frederic Danis's avatar Frederic Danis Committed by Marcel Holtmann

Bluetooth: btbcm: Fix calls to __hci_cmd_sync()

Remove test of command reply status as it is already performed by
__hci_cmd_sync().

__hci_cmd_sync_ev() function already returns an error if it got a
non-zero status either through a Command Complete or a Command
Status event.

For both of these events the status is collected up in the event
handlers called by hci_event_packet() and then passed as the second
parameter to req_complete_skb(). The req_complete_skb() callback in
turn is hci_req_sync_complete() for __hci_cmd_sync_ev() which stores
the status in hdev->req_result. The hdev->req_result is then further
converted through bt_to_errno() back in __hci_cmd_sync_ev().
Signed-off-by: default avatarFrederic Danis <frederic.danis@linux.intel.com>
Signed-off-by: default avatarMarcel Holtmann <marcel@holtmann.org>
parent b1f5cf0c
...@@ -55,12 +55,6 @@ int btbcm_check_bdaddr(struct hci_dev *hdev) ...@@ -55,12 +55,6 @@ int btbcm_check_bdaddr(struct hci_dev *hdev)
} }
bda = (struct hci_rp_read_bd_addr *)skb->data; bda = (struct hci_rp_read_bd_addr *)skb->data;
if (bda->status) {
BT_ERR("%s: BCM: Device address result failed (%02x)",
hdev->name, bda->status);
kfree_skb(skb);
return -bt_to_errno(bda->status);
}
/* The address 00:20:70:02:A0:00 indicates a BCM20702A0 controller /* The address 00:20:70:02:A0:00 indicates a BCM20702A0 controller
* with no configured address. * with no configured address.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment