Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 06519e81 authored by weichinweng's avatar weichinweng
Browse files

HIDH: Initialize the ctrl_cid after trigger l2cap disconnect

Since the ctrl_cid doesn't initialize, the HIDH sm can't initialize.
Next time, can't correctly trigger connect and handle the ctrl_cid
connect request.

Bug: 184128916
Test: compile && disconnect/reconnect HID device
Tag: #feature
Change-Id: I7bafe8728726d3df1d0bc58c8bc5224260042365
parent 75961ba4
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -535,6 +535,7 @@ static void hidh_l2cif_disconnect(uint16_t l2cap_cid) {
    if (p_hcon->ctrl_cid) {
      HIDH_TRACE_EVENT("HID-Host Initiating L2CAP Ctrl disconnection");
      L2CA_DisconnectReq(p_hcon->ctrl_cid);
      p_hcon->ctrl_cid = 0;
    }
  }