Commit Graph

13905 Commits

Author SHA1 Message Date
Michael Butler
f96dc6ed8f Merge "NNAPI Burst -- HAL interface" 2019-01-23 19:17:06 +00:00
Jeff Tinker
72a82168a6 Merge "Add securityLevel to MediaDrm isCryptoSchemeSupported API" 2019-01-23 19:01:52 +00:00
Michael Butler
7e91e24fe1 NNAPI Burst -- HAL interface
FastMessageQueue is a Treble-compliant data structure that enables fast
communication between two processes. The FMQ object itself is an atomic
circular buffer that is optionally synchronized with a futex. However,
FMQ has no notion of ownership or lifetime across processes, so it must
be paired with higher-level constructs to manage the lifetime and
ownership.

The NNAPI is introducing the notion of an "Execution Burst" object (or
more simply a "Burst" object), which is similar to an
ANeuralNetworksExecution, but is intended to be reused across multiple
executions and has lower IPC overheads. It achieves this low IPC
overhead by replacing HIDL HwBinder calls with FMQ messages.
Specifically, it replaces IPreparedModel::executeSynchronously's call
from the client into the service with fmq_sync<FmqRequestDatum> (an FMQ
channel used to pass a serialized Request object) and it replaces
the return from the service into the client with
fmq_sync<FmqResultDatum> (an FMQ channel used to return serialized
result status and OutputShapes information).

Each channel is a unidirectional flow of information with exactly one
producer and exactly one consumer. The channels are created by the NN
runtime and passed to the service via
IPreparedModel::configureExecutionBurst.

This CL defines the FmqRequestDatum and FmqResultDatum types in
types.hal. IBurstContext.hal defines IBurstContext, a HIDL object used
by the service to manage the resources of a Burst. IBurstCallback.hal
defines IBurstCallback, a HIDL callback object that can be used to
retrieve the handle to a resource the service has either not yet seen or
has evicted from its cache. Finally, IPreparedModel.hal is extended with
IPreparedModel::configureExecutionBurst to create the burst object.

Bug: 119570067
Test: mma
Change-Id: I333da70201531b1396efc714d096c277e8e1d47b
2019-01-22 20:23:08 -08:00
Sooraj Sasindran
2ef3aecf5a Merge "Fix the compatibility matrix with range" 2019-01-23 04:17:36 +00:00
Paul Hu
4e78356ddb Merge "Refine error causes to make them more clear" am: db4cc673f5 am: 291c63b21b
am: 7392c07398

Change-Id: I91ef9fbc0731ce2397e1ca9aff7c8349022dad44
2019-01-22 19:33:31 -08:00
Jimmy Chen
62c6495663 Merge "p2p: add HAL method to enable P2P random MAC address feature" 2019-01-23 02:53:12 +00:00
Paul Hu
7392c07398 Merge "Refine error causes to make them more clear" am: db4cc673f5
am: 291c63b21b

Change-Id: I8b50ec7b78663f1da3014cccc1bf225a5da0a843
2019-01-22 18:17:47 -08:00
TreeHugger Robot
a4ec958d31 Merge changes from topic "IA/IM-3.0-feature"
* changes:
  allocator: require optimal allocations
  mapper: add isSupported
  mapper: update lock's return values
  mapper: update documentation on locking
2019-01-23 02:02:45 +00:00
Paul Hu
291c63b21b Merge "Refine error causes to make them more clear"
am: db4cc673f5

Change-Id: I9f0778aeb1f306cb28f228383e0b8033f9af2405
2019-01-22 17:57:52 -08:00
Socrates Li
a40b7516dc [automerger skipped] Camera: Document 3.4 metadata selection logic. am: 9ada649246 am: 802422d05e
am: 6b058b2bcc -s ours
am skip reason: change_id I6500ab06b8c392310009ecfa0570000742fd069c with SHA1 a5cbabbee9 is in history

Change-Id: I2a05fb4c7aed6a7928484cc72183c57cb42a06a4
2019-01-22 17:51:33 -08:00
Paul Hu
db4cc673f5 Merge "Refine error causes to make them more clear" 2019-01-23 01:25:02 +00:00
Socrates Li
6b058b2bcc Camera: Document 3.4 metadata selection logic. am: 9ada649246
am: 802422d05e

Change-Id: Iaed4c594763d31bced453484b65b417dc4ea7293
2019-01-22 17:16:55 -08:00
Socrates Li
802422d05e Camera: Document 3.4 metadata selection logic.
am: 9ada649246

Change-Id: I1b3a4509983fbbcc9c93f28d7c4aab5ece367c52
2019-01-22 16:47:15 -08:00
Jeff Tinker
08ff314594 Add securityLevel to MediaDrm isCryptoSchemeSupported API
bug:110701831
test: cts media test cases, widevine integration tests

Change-Id: I9e4679ee63b3997f7141c9b81fd6f375e862862d
2019-01-22 23:27:26 +00:00
Sooraj Sasindran
c87be8aace Fix the compatibility matrix with range
Fix the compatibility matrix with range of versions

Bug: 122994344
Test: verified manually
Change-Id: Ic5ebb7261d2fe8f379d46ebcc0c47efe8dbd3c59
2019-01-22 15:10:50 -08:00
Nazanin Bakhshi
f1edd06918 [automerger skipped] Merge "Add getModemEnabled HAL API" am: 5acbc036b0 am: e816c587f0
am: d907ccd214 -s ours
am skip reason: change_id I1ac193dd144b840e4f3e3a397c0c93327ac00186 with SHA1 50eed9211f is in history

Change-Id: Icbbb2eadbb18bfa74e73b3357c49b13046d137cf
2019-01-22 14:46:47 -08:00
Nazanin Bakhshi
d907ccd214 Merge "Add getModemEnabled HAL API" am: 5acbc036b0
am: e816c587f0

Change-Id: Id4205ab50156c679c6f958969f75b3545c3a98e2
2019-01-22 14:10:24 -08:00
Marissa Wall
2a1a695599 allocator: require optimal allocations
Add a clarification the documentation that all buffer allocations
should be optimized for the usage bits provided in the descriptor.
This was always assumed to be a requirement of buffer allocations
but it was not explicitly documented.

Bug: 120493579
Test: N/A
Change-Id: Id9e3e1df861d0f32c995f18cabe37d62e7e5ce5c
2019-01-22 22:10:22 +00:00
Marissa Wall
a6a30b1aec mapper: add isSupported
Add a function to the mapper hal that checks if a BufferDescriptorInfo
is ever supported on a device. This value can be cached by the client.
The client can use this information to make decisions on what type of
buffers should attempt to allocate.

Bug: 120493579
Test: vts
Change-Id: I6bd7909e40d6462524bf49cf0d4e7af721e701ed
2019-01-22 22:09:59 +00:00
Marissa Wall
69292faf0b mapper: update lock's return values
Require mapper to return more information when locking a buffer.
Opaque vendor formats make it difficult to manipulate a locked
buffer. The pointer to the buffer's data is always at the top
left hand corner of the buffer. It can be impossible to know
where the locked region begins.

The mapper now must return the bytes per pixel and bytes
per stride of a locked buffer when the values are consistent
and known.

Bug: 120493579
Test: vts
Change-Id: Id0921f191f1e388d4950ecef73acab6a34010dc4
2019-01-22 22:07:10 +00:00
Marissa Wall
2f43f46211 mapper: update documentation on locking
Update the locking documentation to require all 1D buffers
"lock in place". Previously, the framework was able to get 1D
buffers that locked in place via ion. The ion interface is no
longer directly accessible. Some framework use cases still need
1D buffers that lock in place so add the requirement to mapper.

Bug: 120493579
Test: N/A
Change-Id: Ib903efdbeeb8c44ed70c3c6022d6792d05df1a63
2019-01-22 22:03:58 +00:00
Nazanin Bakhshi
e816c587f0 Merge "Add getModemEnabled HAL API"
am: 5acbc036b0

Change-Id: I62b5453b62d8e68eebd09c784c82ed5b5d910caa
2019-01-22 13:47:23 -08:00
Socrates Li
9ada649246 Camera: Document 3.4 metadata selection logic.
Bug: 119575429
Test: Ensure everything still builds.
Change-Id: I6500ab06b8c392310009ecfa0570000742fd069c
Merged-In: I6500ab06b8c392310009ecfa0570000742fd069c
(cherry picked from commit a5cbabbee9)
2019-01-22 13:46:57 -08:00
Treehugger Robot
5acbc036b0 Merge "Add getModemEnabled HAL API" 2019-01-22 21:29:24 +00:00
Youming Ye
5279d8161b Clean up error codes and add error description for IRadioResponse 1.4. am: 7224c5dc1c am: 2d80031567
am: 4ed9de3c7c

Change-Id: I579db049699796768019d8d1ae0a4f2374bf94a2
2019-01-22 13:06:24 -08:00
Nazanin Bakhshi
da4e793b56 Add getModemEnabled HAL API
Bug: 121020566
Test: vts
Change-Id: I1ac193dd144b840e4f3e3a397c0c93327ac00186
Merged-In: I1ac193dd144b840e4f3e3a397c0c93327ac00186
2019-01-22 20:51:33 +00:00
Youming Ye
4ed9de3c7c Clean up error codes and add error description for IRadioResponse 1.4. am: 7224c5dc1c
am: 2d80031567

Change-Id: Iffacf5eca1243352a9062706df8cf334b6e6815d
2019-01-22 12:14:10 -08:00
Youming Ye
2d80031567 Clean up error codes and add error description for IRadioResponse 1.4.
am: 7224c5dc1c

Change-Id: If38a344a841d0a81f5263d24338967af535e913e
2019-01-22 11:58:58 -08:00
TreeHugger Robot
c02a133f5a Merge "mutateOperationOperandTypeSkip for new TRANSPOSE_CONV_2D variant" 2019-01-22 18:40:08 +00:00
Youming Ye
7224c5dc1c Clean up error codes and add error description for IRadioResponse 1.4.
Clean up some unneeded/confusing error codes in the 1.4 Radio HAL.
Quoting description from aosp/616923:

-Remove SYSTEM_ERROR. This is an ultra-generic error
 that also provides no meaningful distinction from
 INTERNAL_ERROR but is even less specified in scope.

-Remove NO_MEMORY. This is very implementation
 specific, and should be essentially impossible to
 hit in the generic sense. Today we don't have a
 generic EBUSY error code, which this would map to.
 Since it should be essentially impossible to hit,
 the preference is to assert that it shouldn't be.
 If an implementation really has memory pressure
 then it can return INTERNAL_ERROR, of which this
 is a class. INTERNAL_ERROR will be treated as a
 temporary failure anyway, making NO_MEMORY a
 distinction without a difference.

-Remove CANCELLED. We have no way to cancel an API
 call. If a persistent/ongoing request is cancelled
 by the caller using a separate API request, then
 that's a success case rather than an error case.

Bug: 73174777
Change-Id: I5bf268f86ed52e7294f7127f24beba04c9159fea
Test: Compilation
2019-01-22 17:49:40 +00:00
Nazanin Bakhshi
f52680bd04 Merge "Add getModemEnabled HAL API" 2019-01-22 17:45:39 +00:00
Lev Proleev
1509a2664c mutateOperationOperandTypeSkip for new TRANSPOSE_CONV_2D variant
Bug: 119255406
Test: Vts NNAPI tests.
Change-Id: I63f7fc67cedcc2a9db8c359ff96be3c9403b9a20
2019-01-22 15:20:13 +00:00
Pierre Lee
62da080e00 Merge "The test failed when one of the three cameras was configured with a maximum android.scaler.availableStreamConfiguration size of 1600*1200" am: ac6175ee79 am: cb516f7cca
am: 556b049596

Change-Id: I40eb4709eaea843a06222c20baec61c150d5e3f5
2019-01-21 20:29:42 -08:00
Pierre Lee
556b049596 Merge "The test failed when one of the three cameras was configured with a maximum android.scaler.availableStreamConfiguration size of 1600*1200" am: ac6175ee79
am: cb516f7cca

Change-Id: I52e581a8d0c43239da8a78b6d6ea78c7ae719b73
2019-01-21 20:25:36 -08:00
Pierre Lee
cb516f7cca Merge "The test failed when one of the three cameras was configured with a maximum android.scaler.availableStreamConfiguration size of 1600*1200"
am: ac6175ee79

Change-Id: I3e2b8d078abcd414663f802afa1d3d6926e08247
2019-01-21 20:21:33 -08:00
Treehugger Robot
ac6175ee79 Merge "The test failed when one of the three cameras was configured with a maximum android.scaler.availableStreamConfiguration size of 1600*1200" 2019-01-22 04:12:43 +00:00
Eric Laurent
a9ccf13d9b Merge "audio vts: update with new audio policy class" 2019-01-21 18:49:03 +00:00
Lev Proleev
b0762ccb2f mutateOperationOperandTypeSkip for new GROUPED_CONV_2D variant
Bug: 119255406
Test: Vts NNAPI tests.
Change-Id: I234727f5abba546c1392f7096b7d411d36566bbf
2019-01-21 11:37:28 +00:00
Tor Norbye
647ad0c56a [automerger skipped] Update signature files to the new format am: 0074475ccf am: a63b2e4d4f
am: 9927a9f142 -s ours
am skip reason: change_id I2943d9a65c24e7ca8fb9ae9b69f7edf06173f467 with SHA1 c9ea9f66de is in history

Change-Id: Ice5399204cb09ddde9bc91a417502bead1c3a1b7
2019-01-21 02:53:02 -08:00
Tor Norbye
9927a9f142 Update signature files to the new format am: 0074475ccf
am: a63b2e4d4f

Change-Id: Iee5da05800ed21d7c5d77079bcb6aaa360e4be76
2019-01-21 02:41:20 -08:00
Tor Norbye
a63b2e4d4f Update signature files to the new format
am: 0074475ccf

Change-Id: I1ea62c1b2bcb450dc695dab74230560a48f09191
2019-01-20 07:25:52 -08:00
Eric Laurent
7f877d427f audio vts: update with new audio policy class
Bug: 111812273
Test: make
Change-Id: I2daae7401269d2fff59f0ecf69a45b62873ef1a1
2019-01-19 14:53:55 -08:00
Tor Norbye
c9ea9f66de Update signature files to the new format
The new format is described in tools/metalava/FORMAT.md.

Fixes: 116589402 Switch signature files over to the v2 format
Fixes: 112626813 Drop "synchronized" modifier from the signature format
Fixes: 122358225 Omit overriding methods that only differ in final [...]
Fixes: 73088715 API Review: Need doclava to output nullability
Fixes: 79739773 API Review: Metalava enforcing constants are constant
Exempt-From-Owner-Approval: Large-scale tooling change
Test: make sdk, make update-api, make checkapi
Change-Id: I2943d9a65c24e7ca8fb9ae9b69f7edf06173f467
2019-01-18 22:09:18 -08:00
Tor Norbye
0074475ccf Update signature files to the new format
The new format is described in tools/metalava/FORMAT.md.

Fixes: 116589402 Switch signature files over to the v2 format
Fixes: 112626813 Drop "synchronized" modifier from the signature format
Fixes: 122358225 Omit overriding methods that only differ in final [...]
Fixes: 73088715 API Review: Need doclava to output nullability
Fixes: 79739773 API Review: Metalava enforcing constants are constant
Exempt-From-Owner-Approval: Large-scale tooling change
Test: make sdk, make update-api, make checkapi
Change-Id: I767f9fb2941789615c9513072a381e79a5654373
Merged-In: I2943d9a65c24e7ca8fb9ae9b69f7edf06173f467
2019-01-18 22:08:52 -08:00
Jeff Tinker
3e5e311546 Merge "Add support for HDCP 2.3" 2019-01-19 05:48:04 +00:00
Xusong Wang
f637f04a36 Merge "Add new OperandType TENSOR_QUANT16_ASYMM." 2019-01-19 03:37:04 +00:00
TreeHugger Robot
5cbef169cd Merge "Verify stale requests are removed" 2019-01-19 03:36:29 +00:00
paulhu
14e4d76502 Refine error causes to make them more clear
Many of error causes reason are using very esoteric
abbreviations and acronyms. Refine description for making more
clear to the developer.

Bug: 113505704
Test: Build pass and data call can setup normally.
Change-Id: Ifb9c256eef8354add46c76c322cd6a3bd126bd44
2019-01-19 03:17:35 +00:00
Michele Berionne
e8ef723266 [automerger skipped] Merge "Carrier restriction enhancements for Android Q" am: f6dbeefbc3 am: 578fc681b2
am: dc740a3e9f -s ours
am skip reason: change_id Ib05267fda5f2fd0b8821a5812fcf47d460e60a2b with SHA1 4f59a2a174 is in history

Change-Id: Ica10ce5e8bd1f8b255185a595e8fcfb37cc850cf
2019-01-18 17:17:38 -08:00
Benjamin Schwartz
cb4de0fe8a Merge "power.stats: Add more informative default implementation" am: bc93126d60 am: 88b2a11aca
am: 83afa3a95f

Change-Id: I1ac317ffb7524358ad5fb54921e08de5a4adc209
2019-01-18 17:17:06 -08:00