1. 15 Aug, 2016 6 commits
  2. 12 Aug, 2016 1 commit
    • Myles Watson's avatar
      RemoteDevices: Optimize adding new remote devices · 619e48d1
      Myles Watson authored
      
      RemoteDevices keeps track of the Bluetooth devices which have been
      seen since the Bluetooth stack was initialized.  Each time a remote
      device is discovered, it is added to a hash map.  When the size of the
      hash map grows beyond a few hundred devices, the performance degrades.
      
      This patch:
       - creates the address string once per search
        reducing the average search time with 300 devices from ~20ms to ~1ms
       - uses the hash of the address string to search
        further reducing the time with 1200 devices from ~2ms to ~1ms
      
      HashMap<BluetoothDevice, DeviceProperties> became
       HashMap<String, DeviceProperties>
      
      mDevice now stores the BluetoothDevice in each instance of
      DeviceProperties.
      
      TEST: Used System.nanoTime() to measure the elapsed time of
            getDeviceProperties()
      Bug: 30828758
      
      Change-Id: Id44886143fb2910955294341d4938d638c72f7f9
      Signed-off-by: default avatarMyles Watson <mylesgw@google.com>
      (cherry picked from commit 1fb90c4f)
      619e48d1
  3. 09 Aug, 2016 1 commit
  4. 08 Aug, 2016 1 commit
    • Ajay Panicker's avatar
      Prevent OPP connections from staying open forever · 8528cc92
      Ajay Panicker authored
      OPP connections could possibly stay open forever if no response to
      the put request is received after transfering very small files. Fixed
      by waiting to clear the timeout message until after the response is
      received.
      
      Bug: 30645605
      Change-Id: I0743685e98e74195b99eff7012dc8c8044c425ca
      8528cc92
  5. 04 Aug, 2016 1 commit
  6. 02 Aug, 2016 1 commit
  7. 01 Aug, 2016 1 commit
    • Marie Janssen's avatar
      Fix bugs in play status and play pos notifications · 7d4aa832
      Marie Janssen authored
      Fix multiple issues with status notificatios:
        * Playback state was not being sent when state wasn't sent
          accompanying a metadata change
        * Play state was being sent without an update
        * Position was being sent without a change and with the wrong
          indicator
        * Position was not being scheduled for update when playing.
        * Position was being scheduled for update when paused / stopped.
      
      Bug: 30459664
      Bug: 29400658
      Bug: 28639383
      Change-Id: Ic550dcab0430be45187b0267cc77875740388a2a
      (cherry picked from commit fa81085f)
      7d4aa832
  8. 28 Jul, 2016 1 commit
  9. 27 Jul, 2016 1 commit
  10. 26 Jul, 2016 2 commits
  11. 25 Jul, 2016 1 commit
  12. 21 Jul, 2016 1 commit
  13. 18 Jul, 2016 2 commits
  14. 15 Jul, 2016 3 commits
    • Marie Janssen's avatar
      Fix AVRCP crash, position and state tracking · 9b04e432
      Marie Janssen authored
      When the MediaController goes away (media stops) a NPE would cause a
      crash.
      
      Initialize the position so that an initial notification gets sent
      when position is requested, send it when the music is paused, and
      send play state whenever the app sends us a play state update.
      
      Bug: 30039744
      Bug: 29416450
      Change-Id: I44397b3dc40d328fa75a2c15875fad298a5090dd
      (cherry picked from commit 84d3f084)
      9b04e432
    • Marie Janssen's avatar
      Refactor playback position tracking · 2be59462
      Marie Janssen authored
      Use PlaybackState directly to track the position through time.  Update
      the state when necessary (track changes, etc.)
      
      Remove complex logic and centralize sending of Play Position
      Notificaiton response and scheduling.
      
      Update dumpsys and add current package session.
      
      Bug: 29416450
      Bug: 29606822
      
      Change-Id: Ie82b48d6d7f9e1a05b64835731433d05a3a3a41a
      (cherry picked from commit eb9e6ef0)
      2be59462
    • Hemant Gupta's avatar
      MAP: Remove redundant call to sendShutdownMessage to prevent crash · 983e5e14
      Hemant Gupta authored
      Usecase:
      Perform BT off/on repeatedly.
      
      Issue:
      Bluetooth crashes.
      
      Fix:
      Remove redundant call to sendShutdownMessage() from stop API to prevent
      MapServiceMessageHandler becoming null and being dereferenced.
      
      Bug: 29149190
      Change-Id: I739664975043c4a1895fd2113869c87cdb704338
      (cherry picked from commit 5847ca3c)
      983e5e14
  15. 14 Jul, 2016 5 commits
    • TreeHugger Robot's avatar
    • Nitin Shivpure's avatar
      PAN: Avoid reconfiguration of bt-pan interface in NAP role · fe85d07e
      Nitin Shivpure authored
      Issue:
      Browsing is not working with multiple remote PANU Device(s).
      
      Root Cause:
      When the 1st remote PANU is connected, the bt-pan interface gets
      configured. As soon as 2nd PANU is connected, the bt-pan interface
      goes into a bad state. The second device is able to write Ethernet
      packets on the bt-pan interface (TUN driver) after reconfiguration,
      but it is unable to read Ethernet packets from the interface.
      
      Fix:
      If the bt-pan interface is already configured in the NAP role,
      then do not reconfigure bt-pan when the 2nd PANU is connected.
      
      Bug: 29992925
      Change-Id: Ib6e0cb91d573649af45ffe25c7095a4bd74a5022
      fe85d07e
    • Marie Janssen's avatar
      Fix AVRCP crash, position and state tracking · 84d3f084
      Marie Janssen authored
      When the MediaController goes away (media stops) a NPE would cause a
      crash.
      
      Initialize the position so that an initial notification gets sent
      when position is requested, send it when the music is paused, and
      send play state whenever the app sends us a play state update.
      
      Bug: 30039744
      Bug: 29416450
      Change-Id: I44397b3dc40d328fa75a2c15875fad298a5090dd
      84d3f084
    • Marie Janssen's avatar
      Refactor playback position tracking · eb9e6ef0
      Marie Janssen authored
      Use PlaybackState directly to track the position through time.  Update
      the state when necessary (track changes, etc.)
      
      Remove complex logic and centralize sending of Play Position
      Notificaiton response and scheduling.
      
      Update dumpsys and add current package session.
      
      Bug: 29416450
      Bug: 29606822
      
      Change-Id: Ie82b48d6d7f9e1a05b64835731433d05a3a3a41a
      eb9e6ef0
    • Ajay Panicker's avatar
      Allow MAP to accept and list draft messages without recipients · c06dad4b
      Ajay Panicker authored
      Bug: 28970268
      Change-Id: I5bdef6cd67708036352ed37ea35b027d6a54af03
      c06dad4b
  16. 06 Jul, 2016 1 commit
    • Satish Kodishala's avatar
      Check for call/call setup state before creating SCO · 4b84ae98
      Satish Kodishala authored
      Use case:
      1. Run HFP AG PTS test cases.
      or
      1. Pair and connect phone with Sony xba-bt75 Bluetooth headset.
      2. Make incoming call and accept it.
      
      Failure:
      PTS test cases fail. There will be no call audio on
      Sony xba-bt75 headset.
      
      Root cause:
      Telephony asking to create SCO before incoming call
      is accepted.
      
      Fix:
      If there is no active/held call, outgoing call setup
      in progress, we should not create SCO. Telephony will
      ask to create SCO for incoming call before the call
      becomes active, this creates IOT issues and fail below
      PTS test cases.
      TC_AG_ACC_BV_08_I
      TC_AG_ACC_BV_10_I
      TC_AG_ACC_BV_11_I
      TC_AG_ACC_BV_12_I
      TC_AG_ACC_BV_13_I
      TC_AG_ACC_BV_14_I
      
      Bug: 29417803
      Change-Id: I0c1002b31da65cbc0b0e74b590468d37ea51d065
      (cherry picked from commit c01a35486da7fa801b4cb6ad4d1bb7702ab4f272)
      4b84ae98
  17. 25 Jun, 2016 1 commit
    • Pavlin Radoslavov's avatar
      Set the Adapter Service onCreate() · 39d7556b
      Pavlin Radoslavov authored
      We should call setAdapterService(this) inside onCreate() instead of
      inside BleOnProcessStart(). The former is more robust.
      
      Change-Id: Ide1d98dfdde148645f3efe246e6fbf95659195a7
      39d7556b
  18. 24 Jun, 2016 1 commit
  19. 23 Jun, 2016 4 commits
  20. 22 Jun, 2016 4 commits
  21. 21 Jun, 2016 1 commit
    • Ajay Panicker's avatar
      Fix how file size is calculated if not provided · 120ba1db
      Ajay Panicker authored
      Currently if there is no file size provided, InputStream.available()
      is used to guess how many bytes are available. According to the
      java documentation, available() should not be used to calculate
      file sizes, as it isn't guarenteed to return the total number of
      bytes in the stream. This is fixed by reading the stream to
      calculate the length, then resetting the stream.
      
      Bug: 29334784
      Change-Id: Ic851c46d053157e4d5404352d76f9ff87a509607
      120ba1db