|
Lines 145-151
struct sk_buff *__hci_cmd_sync_ev(struct hci_dev *hdev, u16 opcode, u32 plen,
Link Here
|
| 145 |
|
145 |
|
| 146 |
hci_req_init(&req, hdev); |
146 |
hci_req_init(&req, hdev); |
| 147 |
|
147 |
|
| 148 |
hci_req_add_ev(&req, opcode, plen, param, event); |
148 |
hci_req_add_ev(&req, opcode, plen, param, event, false); |
| 149 |
|
149 |
|
| 150 |
hdev->req_status = HCI_REQ_PEND; |
150 |
hdev->req_status = HCI_REQ_PEND; |
| 151 |
|
151 |
|
|
Lines 606-613
static void hci_init3_req(struct hci_request *req, unsigned long opt)
Link Here
|
| 606 |
|
606 |
|
| 607 |
bacpy(&cp.bdaddr, BDADDR_ANY); |
607 |
bacpy(&cp.bdaddr, BDADDR_ANY); |
| 608 |
cp.delete_all = 0x01; |
608 |
cp.delete_all = 0x01; |
| 609 |
hci_req_add(req, HCI_OP_DELETE_STORED_LINK_KEY, |
609 |
hci_req_add_ev(req, HCI_OP_DELETE_STORED_LINK_KEY, |
| 610 |
sizeof(cp), &cp); |
610 |
sizeof(cp), &cp, 0, true); |
| 611 |
} |
611 |
} |
| 612 |
|
612 |
|
| 613 |
if (hdev->commands[5] & 0x10) |
613 |
if (hdev->commands[5] & 0x10) |
|
Lines 2674-2680
int hci_send_cmd(struct hci_dev *hdev, __u16 opcode, __u32 plen,
Link Here
|
| 2674 |
|
2674 |
|
| 2675 |
/* Queue a command to an asynchronous HCI request */ |
2675 |
/* Queue a command to an asynchronous HCI request */ |
| 2676 |
void hci_req_add_ev(struct hci_request *req, u16 opcode, u32 plen, |
2676 |
void hci_req_add_ev(struct hci_request *req, u16 opcode, u32 plen, |
| 2677 |
const void *param, u8 event) |
2677 |
const void *param, u8 event, bool ignore_status) |
| 2678 |
{ |
2678 |
{ |
| 2679 |
struct hci_dev *hdev = req->hdev; |
2679 |
struct hci_dev *hdev = req->hdev; |
| 2680 |
struct sk_buff *skb; |
2680 |
struct sk_buff *skb; |
|
Lines 2699-2704
void hci_req_add_ev(struct hci_request *req, u16 opcode, u32 plen,
Link Here
|
| 2699 |
bt_cb(skb)->req.start = true; |
2699 |
bt_cb(skb)->req.start = true; |
| 2700 |
|
2700 |
|
| 2701 |
bt_cb(skb)->req.event = event; |
2701 |
bt_cb(skb)->req.event = event; |
|
|
2702 |
bt_cb(skb)->req.ignore_status = ignore_status; |
| 2702 |
|
2703 |
|
| 2703 |
skb_queue_tail(&req->cmd_q, skb); |
2704 |
skb_queue_tail(&req->cmd_q, skb); |
| 2704 |
} |
2705 |
} |
|
Lines 2706-2712
void hci_req_add_ev(struct hci_request *req, u16 opcode, u32 plen,
Link Here
|
| 2706 |
void hci_req_add(struct hci_request *req, u16 opcode, u32 plen, |
2707 |
void hci_req_add(struct hci_request *req, u16 opcode, u32 plen, |
| 2707 |
const void *param) |
2708 |
const void *param) |
| 2708 |
{ |
2709 |
{ |
| 2709 |
hci_req_add_ev(req, opcode, plen, param, 0); |
2710 |
hci_req_add_ev(req, opcode, plen, param, 0, false); |
| 2710 |
} |
2711 |
} |
| 2711 |
|
2712 |
|
| 2712 |
/* Get data from the previously sent command */ |
2713 |
/* Get data from the previously sent command */ |
|
Lines 3430-3435
void hci_req_cmd_complete(struct hci_dev *hdev, u16 opcode, u8 status)
Link Here
|
| 3430 |
return; |
3431 |
return; |
| 3431 |
} |
3432 |
} |
| 3432 |
|
3433 |
|
|
|
3434 |
/* Check for commands whose failures aren't critical */ |
| 3435 |
if (bt_cb(hdev->sent_cmd)->req.ignore_status) |
| 3436 |
status = 0; |
| 3437 |
|
| 3433 |
/* If the command succeeded and there's still more commands in |
3438 |
/* If the command succeeded and there's still more commands in |
| 3434 |
* this request the request is not yet complete. |
3439 |
* this request the request is not yet complete. |
| 3435 |
*/ |
3440 |
*/ |