diff options
Diffstat (limited to 'sys/netgraph/bluetooth/l2cap/ng_l2cap_cmds.c')
-rw-r--r-- | sys/netgraph/bluetooth/l2cap/ng_l2cap_cmds.c | 23 |
1 files changed, 18 insertions, 5 deletions
diff --git a/sys/netgraph/bluetooth/l2cap/ng_l2cap_cmds.c b/sys/netgraph/bluetooth/l2cap/ng_l2cap_cmds.c index db667b9..167fcb6 100644 --- a/sys/netgraph/bluetooth/l2cap/ng_l2cap_cmds.c +++ b/sys/netgraph/bluetooth/l2cap/ng_l2cap_cmds.c @@ -86,7 +86,6 @@ ng_l2cap_con_wakeup(ng_l2cap_con_p con) /* Process command */ switch (cmd->code) { - case NG_L2CAP_CMD_REJ: case NG_L2CAP_DISCON_RSP: case NG_L2CAP_ECHO_RSP: case NG_L2CAP_INFO_RSP: @@ -104,7 +103,16 @@ ng_l2cap_con_wakeup(ng_l2cap_con_p con) ng_l2cap_unlink_cmd(cmd); ng_l2cap_free_cmd(cmd); break; - + case NG_L2CAP_CMD_REJ: + (void) ng_l2cap_lp_send(con, + (con->linktype == NG_HCI_LINK_ACL)? + NG_L2CAP_SIGNAL_CID: + NG_L2CAP_LESIGNAL_CID + , m); + ng_l2cap_unlink_cmd(cmd); + ng_l2cap_free_cmd(cmd); + break; + case NG_L2CAP_CON_REQ: error = ng_l2cap_lp_send(con, NG_L2CAP_SIGNAL_CID, m); if (error != 0) { @@ -115,7 +123,6 @@ ng_l2cap_con_wakeup(ng_l2cap_con_p con) ng_l2cap_command_timeout(cmd, bluetooth_l2cap_rtx_timeout()); break; - case NG_L2CAP_CON_RSP: error = ng_l2cap_lp_send(con, NG_L2CAP_SIGNAL_CID, m); ng_l2cap_unlink_cmd(cmd); @@ -208,9 +215,14 @@ ng_l2cap_con_wakeup(ng_l2cap_con_p con) ng_l2cap_unlink_cmd(cmd); ng_l2cap_free_cmd(cmd); } break; - + case NG_L2CAP_CMD_PARAM_UPDATE_RESPONSE: + error = ng_l2cap_lp_send(con, NG_L2CAP_LESIGNAL_CID, m); + ng_l2cap_unlink_cmd(cmd); + ng_l2cap_free_cmd(cmd); + break; + case NG_L2CAP_CMD_PARAM_UPDATE_REQUEST: + /*TBD.*/ /* XXX FIXME add other commands */ - default: panic( "%s: %s - unknown command code=%d\n", @@ -256,6 +268,7 @@ ng_l2cap_con_fail(ng_l2cap_con_p con, u_int16_t result) case NG_L2CAP_DISCON_RSP: case NG_L2CAP_ECHO_RSP: case NG_L2CAP_INFO_RSP: + case NG_L2CAP_CMD_PARAM_UPDATE_RESPONSE: break; case NG_L2CAP_CON_REQ: |