History log of /frameworks/av/media/libaudiohal/StreamHalHidl.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
3a85e5623164d7dce0912224962d6ad85bdffea4 12-May-2017 Eric Laurent <elaurent@google.com> fix mmap fd leak inn HIDL audio stream

Do not dup the fd received from HAL in StreamHalHidl::createMmapBuffer()

Bug: 38232872
Test: verify that MMAP streams can be opened and closed multiple times
Change-Id: I4813f78bd1ae1e8c705d1769a59710c9437bf246
/frameworks/av/media/libaudiohal/StreamHalHidl.cpp
4ec4e6b1073b0dc1b608aeeaf4e3129ea1a725c8 03-Mar-2017 TreeHugger Robot <treehugger-gerrit@google.com> Merge "audiohal: Check for EINTR and retry when waiting for EventFlag"
d2ae9cd57cfbb6f2f4dd0a91dbc7ea2e9e5fc447 03-Mar-2017 Mikhail Naganov <mnaganov@google.com> audiohal: Check for EINTR and retry when waiting for EventFlag

EINTR can be returned in the case when a futex wait has been
interrupted by a signal. We need to retry in that case.

Bug: 35813113
Change-Id: I7eaee5298f5c0bc5cd62309c3fd8349ee3eae629
Test: make
/frameworks/av/media/libaudiohal/StreamHalHidl.cpp
d15f127a54b4b04a89ca07f52c0508326bf46a92 28-Feb-2017 Mikhail Naganov <mnaganov@google.com> audiohal: Add diagnostic message to check the number of bytes written

Temporary change for investigating b/35813113. Need to test
the hypothesis that sometimes either legacy HAL, or the wrapper
reports more bytes written than being asked for.

Bug: 35813113
Change-Id: I6916d39e40d332b45a95aad05674009266e9cd96
Test: make
/frameworks/av/media/libaudiohal/StreamHalHidl.cpp
23feba2593973e8ab251db8b63d8c2e228acbd51 23-Feb-2017 Mikhail Naganov <mnaganov@google.com> audiohal: Enforce flush of hwbinder commands queue after cleaning client refs

In binderized mode, the exact time of destroying the server object
is not defined. Enforce destruction by flusing hwbinder commands
queue after releasing the last client reference.

Bug: 35394629
Test: capture trace while following repro steps, verify that server-side object
gets destroyed

Change-Id: Id2756cab0f36ed4eaf290d3f5a1c750c9c75b1d3
/frameworks/av/media/libaudiohal/StreamHalHidl.cpp
b4e779137c1849b7b3b09ee782e8bc14de9e2655 15-Feb-2017 Mikhail Naganov <mnaganov@google.com> audiohal: Remove timeouts in eventflag waits

Having a timeout is causing issues on hal driver thread startup.
If thread startup is delayed, then eventflag wait exits with
timeout. This leaves fmqs in an intermediate state, and a pending
wakeup for the server enables the client and the server to run
in parallel, causing races.

The legacy HAL interface didn't have any timeouts for read / write
operations, so there is no good reason for having them in
the wrapping interface.

The only difference with legacy HAL is that Treble HAL can be in
a separate process, and can crash, but this is handled separately.

Test: Check logs on startup, must be no fmq read / write errors
Bug: 35346610
Change-Id: Id3f79d31305afab194a4543bfb4501665518a27b
/frameworks/av/media/libaudiohal/StreamHalHidl.cpp
83f042776b131b149f803fff6ab184ae2c4d98cd 07-Feb-2017 Mikhail Naganov <mnaganov@google.com> audioflinger: Adjust priority of hal threads

HALs are prohibited from using framework binder, and there is
no equivalent scheduling policy service in hwbinder. Thus, in order
to match priorities of FastCapture / Mixer threads with their
counterparts in the HAL, it is needed to request the priority boost
from audioflinger on behalf of the HAL.

Test done to verify the priority was correctly set.

Bug: 34131400
Change-Id: If8b6b031c0fcba771fae901a5b8e7da89b3a1570
Test: check priority match between audioflinger's and hal's threads
/frameworks/av/media/libaudiohal/StreamHalHidl.cpp
c8381909c97dd939706d8b1b9069dcfb4e2bf52f 31-Jan-2017 Mikhail Naganov <mnaganov@google.com> audiohal: Make sure audio data transfer related commands go via FMQ

When outputting audio, the framework issues several HAL calls
from the same thread that writes into data FMQ. These calls
also need to be served on the same thread that writes audio data
to HAL. The same thing happens when audio input is commenced.

Add a command FMQ for passing different commands to the HAL thread.
This way, depending on the calling thread, the same call may go
either via hwbinder or via the command queue.

This dramatically reduces jitter in RTT measurements (although
doesn't improve the latency).

Bug: 30222631
Test: scripted RTT app
Change-Id: Ic212e33d4e2b1cf404973fe9d60762523eef9f40
/frameworks/av/media/libaudiohal/StreamHalHidl.cpp
efbd36c8f57f41b0ef061cde5a88a3d384538fc9 23-Jan-2017 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Cleanup MQDescriptor usage with typedefs"
d635199dcaae89ac50391bdfee4a12d4c88c519d 12-Jan-2017 Mikhail Naganov <mnaganov@google.com> Update StreamHalHidl to use IStreamOut.WriteStatus new field

Updated the client code to use the new field:
IStreamOut.WriteStatus.presentationPositionRetval for providing
legacy-compatible results when calling 'get_presentation_position'
immediately after 'write'.

Bug: 30222631
Test: Loopback RTT, media CTS
Change-Id: Idf3f1d29288ddf17a5015f96291648d64d124ec7
/frameworks/av/media/libaudiohal/StreamHalHidl.cpp
085ae9a0c72e1d1ed76533973b20ead13f5b3cac 10-Jan-2017 Hridya Valsaraju <hridya@google.com> Cleanup MQDescriptor usage with typedefs

Test: mm
Bug: 34054917

Change-Id: Iccfed3af89f3527318c1c3621b6f26ebd6a2e970
/frameworks/av/media/libaudiohal/StreamHalHidl.cpp
e83be8af690ef1ac820a63414d522e77ca9d4db6 06-Jan-2017 Steven Moreland <smoreland@google.com> Remove usage of getStatus.

- remove from libaudiohal
- remove from services/radio
- remove from soundtrigger
- remove from omx

Bug: 31348667
Test: compiles
Change-Id: I75bb7b7388527dacfdc5bf128712cb8690bc286b
/frameworks/av/media/libaudiohal/StreamHalHidl.cpp
e1c4b5d7a94c21b8ce0c5707b4af84de596fbb79 22-Dec-2016 Mikhail Naganov <mnaganov@google.com> Re-implement HIDL stream read and write using FMQ

Result: no hwbinder calls due read / write session.

Test: make, perform Loopback RTT, check traces
Bug: 30222631

Change-Id: I4a8792525ec374111302cfd5c0a2e41f9f4cc418
/frameworks/av/media/libaudiohal/StreamHalHidl.cpp
b8753077cf128ad6492c10e632e118333eb00aee 21-Dec-2016 Eric Laurent <elaurent@google.com> fix ENABLE_TREBLE build broken by commit af35aadb

Test: build marlin-eng with and without ENABLE_TREBLE
Change-Id: Ia8cd2c8b01e2e14557b65ae8ce9c9c4827f596f5
/frameworks/av/media/libaudiohal/StreamHalHidl.cpp
af35aadb7ab558035b6cf45bd3930ecaa3a3b330 15-Dec-2016 Eric Laurent <elaurent@google.com> audio HAL: implement mmap stream functions

Bug: 33398120
Test: make marlin-eng with ENABLE_TREBLE true

Change-Id: I10df5440b9946398a73a7ee309eca860eae0bfcd
/frameworks/av/media/libaudiohal/StreamHalHidl.cpp
f558e0218d2677a813c9c600886f673894eec927 15-Nov-2016 Mikhail Naganov <mnaganov@google.com> libaudiohal: Implement simple HIDL client

This client requires both HIDL client and server to be of the same
ABI version (e.g. 32-bit).

EffectHalHidl::process and EffectHalHidl::processReverse are stubs.

Some extra warnings are logged due to unimplemented functions
in the legacy HAL.

Bug: 30222631
Change-Id: Id074131dec6d6c4f1031695abcf3ea066e92a5af
Test: Play Music (play / EQ), YouTube, Loopback RTLT, Ok Google on N5X
/frameworks/av/media/libaudiohal/StreamHalHidl.cpp