1. 04 Nov, 2015 1 commit
  2. 29 Oct, 2015 1 commit
    • Andre Eisenbach's avatar
      Serialize remote version query over LE · 864e7734
      Andre Eisenbach authored
      Some devices (ex. Nexus Player remote) do not take well to having the
      remote version queried while a remote feature request is also sent and
      subsequently fail encryption.
      
      This patch serializes the query of the remote version and requires both
      remote features and the remote version to be read before calling a
      connection established.
      
      Bug: 25357767
      Change-Id: Ie70eea241b47b81778d8e0df47f3a8f376316932
      864e7734
  3. 27 Oct, 2015 2 commits
  4. 23 Oct, 2015 3 commits
    • Andre Eisenbach's avatar
    • Mattias Agren's avatar
      Reduce persistence on aquiring master role · 59d96731
      Mattias Agren authored
      Whenever a device has more than 1 ACL link active and transferring
      data on one of its links via PAN, HH or JV (RFCOMM) the sys busy/idle
      state toggles frequently. To avoid triggering role switches for each
      of these events we filter this out and let the other SYS events handle
      it in combination with other role policy management code. Ideally we
      should revert the toggling to properly reflect the busy/idle state of
      each profile but to limit risk of side effects at this stage we will
      make this intermittent change.
      
      This also affects audio streaming in certain cases.
      
      Bug: 24570959, 25129209
      Change-Id: I141e17ee069c82624e153fd8de5db90ae93724b9
      59d96731
    • Andre Eisenbach's avatar
      Raise alarm callback thread priority · 730a12ac
      Andre Eisenbach authored
      Since alarms [/callbacks] are used in the critical audio path, raising
      the thread priority is required to ensure timely encoding/transmission
      of audio packets and avoiding thread pre-emption.
      
      This patch indiscriminatly raises the (single) callback thread priority,
      affecting all alarm callbacks. In the future, thread priotiry should be
      adjusted based on the alarms pending in the queue.
      
      Bug: 24570959
      Change-Id: I64928fd7325f1d6f76815a185dbccf1e01ae30d2
      730a12ac
  5. 21 Oct, 2015 3 commits
  6. 19 Oct, 2015 1 commit
  7. 11 Oct, 2015 1 commit
  8. 07 Oct, 2015 1 commit
    • Andre Eisenbach's avatar
      Raise BTU and HCI thread priorities · 6c25b3c0
      Andre Eisenbach authored
      The audio sub-system and audio related tasks run at elevated thread
      priorities in order to ensure timely handling of audio packets. This
      patch raises the thread priority of lower layer Bluetooth tasks involved
      in delivering audio packets to avoid thread pre-emption and subsequent
      audio skipping.
      
      Bug: 24570959
      Change-Id: I5e19ee4590207df753f7b8bfc22174959722ec2d
      6c25b3c0
  9. 25 Sep, 2015 2 commits
    • Pavlin Radoslavov's avatar
      am 74dad515: Disable opening network debug ports for security reasons · 60563860
      Pavlin Radoslavov authored
      * commit '74dad515':
        Disable opening network debug ports for security reasons
      60563860
    • Pavlin Radoslavov's avatar
      Disable opening network debug ports for security reasons · 4cac544d
      Pavlin Radoslavov authored
      By default, we open up to three TCP ports that are used
      for debugging purpose:
      
       * TCP port 8872 - used for forwarding btsnoop logs at real time
         Note: the port is open only if "Bluetooth HCI snoop log" is enabled
         in the Developer options
       * TCP port 8873 - used for HCI debugging
       * TCP port 8879 - used for debugging the Bluetooth counters
      
      Those ports are disabled by default.
      To enable, the following #define should be added at the top of the
      corresponding file(s): btcore/src/counter.c hci/src/btsnoop_net.c
      hci/src/hci_inject.c
      
         #define BT_NET_DEBUG TRUE
      
      Bug: 24371736
      
      Change-Id: I5cb43af1a5d29c331eb5ef61a24dccbe95df6f40
      4cac544d
  10. 24 Sep, 2015 2 commits
    • Pavlin Radoslavov's avatar
      Disable opening network debug ports for security reasons · 74dad515
      Pavlin Radoslavov authored
      By default, we open up to three TCP ports that are used
      for debugging purpose:
      
       * TCP port 8872 - used for forwarding btsnoop logs at real time
         Note: the port is open only if "Bluetooth HCI snoop log" is enabled
         in the Developer options
       * TCP port 8873 - used for HCI debugging
       * TCP port 8879 - used for debugging the Bluetooth counters
      
      Those ports are disabled by default.
      To enable, the following #define should be added at the top of the
      corresponding file(s): btcore/src/counter.c hci/src/btsnoop_net.c
      hci/src/hci_inject.c
      
         #define BT_NET_DEBUG TRUE
      
      Bug: 24371736
      
      Change-Id: I5cb43af1a5d29c331eb5ef61a24dccbe95df6f40
      74dad515
    • Nitin Shivpure's avatar
      Fix PAN crash due to fd mismatch · bb2a4fad
      Nitin Shivpure authored
      A case, where tap read thread is always exist, Sometimes
      data packets get recieved on older fd, which is not available.
      which is causing assert due to fd mismatch in race condition.
      when next pan connection is immediately available. If last pan
      connection gets disconnected, then tap_read_thread should be
      destroyed in btif context to fix this issue.
      
      Bug: 24093456
      Change-Id: Ic1053200a7be4c2091d6c394634831ca3fbd61df
      bb2a4fad
  11. 22 Sep, 2015 2 commits
  12. 21 Sep, 2015 1 commit
  13. 19 Sep, 2015 1 commit
  14. 17 Sep, 2015 2 commits
    • Andre Eisenbach's avatar
      Change UHID socket to be non-blocking · ef7d8cb8
      Andre Eisenbach authored
      On some platforms, the logs indicate that the BTU task is stalled by
      UHID driver when writing the HID descriptor to the kernel. This patch
      converts the UHID socket to non-blocking to avoid stalling the main
      BTU task.
      
      Bug: 23978964
      Change-Id: I5a7a3e106fb2c967d68f077faedcd4fe62bbd912
      ef7d8cb8
    • Nitin Shivpure's avatar
      Check BR device count before initiating role switch · 66df3209
      Nitin Shivpure authored
      A case where DUT is acting as PANU device on BR/EDR link & also
      acting as central on LE link. As LE link & PANU link need not to
      be master & it's not a scatter-net scenario, because there is only
      a BR link. So checking for BR device count before initiating role
      switch to avoid continuous loop of role switches.
      
      Cherry-picked from: https://partner-android-review.googlesource.com/#/c/376058/
      
      Change-Id: I70e4041a71ba965f1f9e25729c3cfd20ae03d6b4
      Bug: 23290136
      66df3209
  15. 15 Sep, 2015 1 commit
  16. 09 Sep, 2015 2 commits
  17. 08 Sep, 2015 2 commits
    • tturney's avatar
      Allow BT inquiry while discovery is in progress. · 2a1b8ac5
      tturney authored
      BT Inquiry is disallowed when service discovery
      is in progress. Innitially when GATT discovery
      is in progress (crosskey pairing), it resulted
      in inquiry requests being rejected. During an
      insecure connection like OPP, bonding link key
      is not stored. In an earlier patch (b820aec7),
      BR/EDR discovery was bypassed if the bonding was
      temporary. However, this was not done for LE.
      Applying the same logic to LE, resolved the
      inquiry issue reported in this bug.
      
      Bug: 23468169
      Change-Id: I6111c80a420aeb0bc36a0393eb215c112512d251
      2a1b8ac5
    • Pavlin Radoslavov's avatar
      Eliminate recursive calling when handling GATT related errors · 50671055
      Pavlin Radoslavov authored
      If there are errors when processing GATT related events (e.g.,
      configuring the MTU), don't use recursive calls into
      bta_gattc_sm_execute(), because it breaks the free-ing of some
      of the memory.
      
      Bug: 23756301
      Change-Id: I3c685170e868ffbf4e488d2bb5a31904e3f7b39d
      50671055
  18. 07 Sep, 2015 1 commit
    • wang ping's avatar
      Fix issue where bluesleep idle timer is not started · 72abbbea
      wang ping authored
      Sometimes allow_device_sleep() is called before wake_assert, this result in transmit_done
      does not start idle timer. This is because the "wake_state" does not match while
      allow_device_sleep() is called before wake_assert() is called. So start idle timer
      anyway when transmit_done is called.
      
      Bug: 23754156
      Change-Id: I5437aea0abc4b7f5cf847701e2d0a889c6823fcb
      72abbbea
  19. 31 Aug, 2015 1 commit
    • tturney's avatar
      Fix btwrite timer timeout for Angler (2/2) · 65d1c84f
      tturney authored
      When calculating the appropriate LPM's idle timeout,
      the local chip name was NULL. This is fixed by calculating
      LMP's idle timeout when the chip is enabling.
      
      Bug: 23248798
      Change-Id: I8ee2b28fb4363359e035e242fdcff8a736ee448c
      65d1c84f
  20. 29 Aug, 2015 1 commit
  21. 28 Aug, 2015 3 commits
    • Jacob Lee's avatar
      LE Multi-Advertising State Change Sub-event Wrong Variable Type · 24923939
      Jacob Lee authored
      Wrong connection handle type in multi-adv event parsing,
      causing random address (confirm value) mismatch and pairing failure.
      
      Bug id: 23201007
      
      Change-Id: I13ce231360937e711f61eb0777805b07bcde7074
      24923939
    • Sunny Kapdi's avatar
      am dcfafe9a: Fix incorrect SetConnScanParam function mapping · ed9a5c76
      Sunny Kapdi authored
      * commit 'dcfafe9a':
        Fix incorrect SetConnScanParam function mapping
      ed9a5c76
    • Sunny Kapdi's avatar
      Fix incorrect SetConnScanParam function mapping · dcfafe9a
      Sunny Kapdi authored
      BTA_DM_API_BLE_CONN_SCAN_PARAM_EVT is defined before
      BTA_DM_API_BLE_SCAN_PARAM_EVT in the enum but the corresponding
      entries in bta_dm_action were inverted. This resulted in incorrect
      invocation of set_conn_scan_params while trying to set parameters
      for scanning. The call was hence failing here and was not
      resulting in setting of the new scan parameters in the Controller
      irrespective of the scan mode selected from the App. This would
      essentially result in the breakage of ScanSettings.SCAN_MODE_<xx>
      Android SDK APIs.
      
      Bug: 23602042
      Change-Id: I17e1b14a32250e3ccb7631a67690ec2e0a6bc321
      dcfafe9a
  22. 25 Aug, 2015 2 commits
  23. 24 Aug, 2015 2 commits
  24. 19 Aug, 2015 1 commit
  25. 18 Aug, 2015 1 commit
    • Pavlin Radoslavov's avatar
      Disable remote TCP connections · d2199cbb
      Pavlin Radoslavov authored
      For security reasons, TCP sockets now listen on the loopback
      IPv4 address 127.0.0.1 for incoming TCP connections.
      
      Bug: 23272146
      Change-Id: I88523f643f305f2281740575d7011b6077bf0843
      d2199cbb