Commit graph

52 commits

Author SHA1 Message Date
Michael Butler
ad643b608c Move NN_TRY macro out of struct initialization
NNAPI NN_TRY macros use Statement Expressions (a GNU extension) to
propagate errors. However, a "return" statement in a Statement
Expression can lead to memory leaks when the Statement Expression is
being used to initialize a member of a struct. Specifically, when one
member of a struct is already initialized, and a Statement Expression
used to initialize a subsequent member early-returns, the previously
initialized members will not have their destructors called.

This CL moves any NN_TRY macro out of struct initialization to avoid any
potential memory leaks.

Bug: 230500484
Test: mma
Test: presubmit
Change-Id: I3493fd4764f8eacc86750e6414e62bc891abaccd
Merged-In: I3493fd4764f8eacc86750e6414e62bc891abaccd
2022-04-29 14:32:10 -07:00
Michael Butler
fe9368b729 Merge "Remove NN host specific build defines" 2022-02-24 00:59:51 +00:00
Michael Butler
323bddccc6 Remove NN host specific build defines
These defines are redundant because they are already defined in
neuralnetworks_utils_defaults.

Bug: N/A
Test: mma
Change-Id: I1c5c44e9e61da19bc10dd8ed2e38099f7c4baccd
2022-02-23 11:44:53 -08:00
Chih-Hung Hsieh
ad1bf31b78 Add timed out test files to tidy_timeout_srcs
* Timed out runs do not show any warning messages.
* These test files cannot finish clang-tidy runs with
  the following settings:
    TIDY_TIMEOUT=90
    WITH_TIDY=1
    CLANG_ANALYZER_CHECKS=1
* When TIDY_TIMEOUT is set, in Android continuous builds,
  tidy_timeout_srcs files will not be compiled by clang-tidy.
  When developers build locally without TIDY_TIMEOUT,
  tidy_timeout_srcs files will be compiled.
* Some of these test modules may be split into smaller ones,
  or disable some time consuming checks, and then
  enable clang-tidy to run within limited time.

Bug: 201099167
Test: make droid tidy-hardware-interfaces_subset
Change-Id: I1de28f1572fff368f67eab512fffec9f2e5c2a9b
2022-02-18 17:25:41 -08:00
Michael Butler
d3e413e759 Merge "Cleanup NN utility libraries' dependencies" 2022-01-20 23:36:09 +00:00
Michael Butler
9257d6d06d Cleanup NN utility libraries' dependencies
Bug: N/A
Test: mma
Change-Id: I0243c477098d9a2de28ca78bfde155d3ecb5acb6
2022-01-20 12:31:38 -08:00
Miao Wang
b5c8a82f25 HAL interface for compilation and execution hints
The following AIDL types are added:
 - TokenValuePair
 - PrepareModelConfig
 - ExecutionConfig

The following AIDL methods are added:
 - IDevice::prepareModelWithConfig
 - IPreparedModel::executeSynchronouslyWithConfig
 - IPreparedModel::executeFencedWithConfig
 - IBurst::executeSynchronouslyWithConfig

The compilation and execution hints are being stored as a list of
token-value pairs as part of the PrepareModelConfig / ExecutionConfig.
And the PrepareModelConfig / ExecutionConfig parcelables are created in
order to make future extensions to the execution related interfaces
easier.

It is the drivers responsibility to verify the hints, and it is allowed
for the driver to ignore them.

Bug: 203248587
Test: neuralnetworks_utils_hal_aidl_test
Change-Id: I98240fd75089fc85cdfcaa0be28aab8a6f0dfca5
Merged-In: I98240fd75089fc85cdfcaa0be28aab8a6f0dfca5
(cherry picked from commit 0e671f3edb)
2022-01-20 16:48:40 +00:00
Michael Butler
60a7b86cf0 Rename Version::ANDROID_* to kVersionFeatureLevel* -- hal
Prior to this change, version constants (e.g., Version::ANDROID_S) were
public static constants to make the version constants look as if they
were enum values. However, this method prevented versions from being
constexpr, because the Version type was incomplete by that point in
time. This change moves these version constants outside of the Version
struct, and makes them constexpr. They have the new names:
* Version::ANDROID_OC_MR1 -> kVersionFeatureLevel1
* Version::ANDROID_P -> kVersionFeatureLevel2
* Version::ANDROID_Q -> kVersionFeatureLevel3
* Version::ANDROID_R -> kVersionFeatureLevel4
* Version::ANDROID_S -> kVersionFeatureLevel5
* Version::FEATURE_LEVEL_6 -> kVersionFeatureLevel6
* Version::EXPERIMENTAL -> kVersionFeatureLevelExperimental

Bug: 206975939
Test: mma
Change-Id: Ibf5f2fdb1459a69c51865aa5fdcd0cb0c3a88ade
2021-11-18 23:56:54 +00:00
Michael Butler
34f0a8f418 Make NNAPI Version more structured -- hal
Prior to this topic, NNAPI Versions were linear and represented by an
enumeration. However, this did not properly account for the
non-linearity of runtime-specific features such as a control flow
operations with operands of dynamic sizes. This topic alters Version to
be a struct containing a feature level enumeration as well as a boolean
which indicates whether there are runtime-specific features.

Bug: 206975939
Test: mma
Test: NeuralNetworksTests_static
Change-Id: I78c54ef597bf269b137f2835332bdedac49883d4
2021-11-18 23:56:15 +00:00
Michael Butler
acd7955b21 Consolidate NNAPI OWNERS files
This change deletes all existing OWNERS files under
hardware/interfaces/neuralnetworks and creates a new OWNERS file with
the current NNAPI team members.

This change also updates the NNAPI project path in
hardware/interfaces/neuralnetworks/README.

Bug: 179510251
Test: N/A
Change-Id: Iaca69505c8449ae7d93be0db99205f5f56556e86
2021-11-15 20:22:41 +00:00
Michael Butler
ee7a476090 Merge changes from topic "libneuralnetworks_common-cleanup"
* changes:
  Move Aidl utility code to aidl/utils -- hal 2/2
  Move Aidl utility code to aidl/utils -- hal 1/2
2021-11-03 18:14:06 +00:00
Michael Butler
c331067aac Move Aidl utility code to aidl/utils -- hal 2/2
This change is part of an effort to remove HAL types from
libneuralnetworks_common*. This change:
* Updates the header guard names for the new directory
* Removes the "Aidl" prefix from the files
* Adds temporary "Aidl" header files under include/ that redirect to
   their corresponding files in include/nnapi/hal/aidl/
* Changes references of libneuralnetworks_common_hidl to
   libneuralnetworks_common

Bug: 191442336
Test: mma
Change-Id: Icbcc04e0a49a9adf8d8826fd5735028ea26de0ca
2021-11-01 21:34:53 -07:00
Michael Butler
137ee99a16 Re-organize NNAPI Burst utility classes
This change:
* Renames ExecutionBurstController to Burst in 1.2/utils
* Renames ExecutionBurstUtils to BurstUtils in 1.2/utils
* Renames ExecutionBurstServer to Burst in common/adapter

Bug: N/A
Test: mma
Change-Id: Ibd460229887c8c9cd23ebc6ee61da37c7c820288
2021-11-01 16:40:31 -07:00
Michael Butler
abc86918ae Revert^2 "Provide explicitly versioned NNAPI AIDL utils libs -- HAL."
Reason for revert: rollforward fix of this topic

This change is a revert of I3d3ac4745, which itself is a revert of
I74f1798e8.

This CL modifies the AIDL utils libraries to be explicitly
versioned. Currently, we only have two versions: v1 and "current".
Specifically, the following changes are made:
- Remove AIDL dependencies from neuralnetworks_utils_hal_common
- Create explicitly versioned libs of neuralnetworks_utils_hal_aidl*

This is needed because it is not allowed for a build target to
link against multiple versions of the same AIDL lirary.

The canonical driver will report ANDROID_S for AIDL v1, and FL6 for v2.

Reverted Changes:
I2aefa0023:Revert "Use explicitly versioned NNAPI HAL util li...
Ia7df07ab9:Revert "Add neuralnetworks_utils_hal_aidl_v2 to al...
Iadd823460:Revert "Provide explicitly version NNAPI AIDL util...
I3d3ac4745:Revert "Provide explicitly versioned NNAPI AIDL ut...

Bug: 202405342
Test: NNT_static
Test: CtsNNAPITestCases
Test: VtsHalNeuralnetworksTargetTest
Change-Id: Ib3b732aa406f6d37e8f941082807c9232720c909
Merged-In: Ib3b732aa406f6d37e8f941082807c9232720c909
(cherry picked from commit 478a78ea77)
2021-10-29 14:28:45 -07:00
Michael Butler
49d95e0457 Move NN HandleError from utils/common to 1.0/utils
This change is part of a larger chain of changes to remove HIDL and AIDL
libraries from neuralnetworks_utils_hal_common.

Bug: N/A
Test: mma
Change-Id: Iae9f692ffc72700294aae694c256e75c7e353fef
2021-10-26 21:18:33 +00:00
Michael Butler
e8645c3b8d Relocate NN ProtectCallback to 1.0/utils
This change is part of a larger chain of changes to remove HIDL and AIDL
libraries from neuralnetworks_utils_hal_common.

Bug: N/A
Test: mma
Change-Id: Ib43f1cb683a09ae5c9116a6dea4d269c9c2c78b4
2021-10-26 21:18:09 +00:00
Michael Butler
15965821e8 Move NN memory utils from utils/common to 1.0/utils
This change is part of a larger chain of changes to remove HIDL and AIDL
libraries from neuralnetworks_utils_hal_common.

Bug: N/A
Test: mma
Change-Id: I9d4f0c30932fad7ccb6231aa03e57f7227af4880
2021-10-26 21:17:53 +00:00
Michael Butler
301ef060e9 Remove hal::utils::countNumberOfConsumers
This CL removes hal::utils::countNumberOfConsumers and uses the existing
nn::countNumberOfConsumers.

This change is part of a larger chain of changes to remove HIDL and AIDL
libraries from neuralnetworks_utils_hal_common.

Bug: N/A
Test: mma
Change-Id: I7d06ea355eae7aa80b94b09a23d606bbb2322120
2021-10-26 21:17:10 +00:00
Michael Butler
ff9a5a527a Allow implicit conversions for NN errors -- hal
This change allows GeneralErrors to be created from a string and allows
ExecutionErrors to be created from a string or a GeneralError.
This makes error handling more terse, removing the need for helper
functions such as makeGeneralFailure or makeExecutionFailure.

Bug: N/A
Test: mma
Change-Id: I8c5e80a2eb4f399fad64aab763fe6fa08cf8d1db
2021-10-15 16:37:09 -07:00
Ray Hernandez
338d6f8b86 Revert^2 "Making NN hardware interface libs "host supported""
This is a revert of I6f657743, which is a revert of I1d7c66516.

Changing static libraries in hardware/interfaces/neuralnetworks to be
"host supported", meaning that the libraries within this directory
will be available on the host/linux build to make integration and
debugging more efficient.

Host Supported Libs:
* neuralnetworks_utils_hal_1_0
* neuralnetworks_utils_hal_1_1
* neuralnetworks_utils_hal_1_2
* neuralnetworks_utils_hal_1_3
* neuralnetworks_utils_hal_aidl
* neuralnetworks_utils_hal_common

Host Supported Tests:
* neuralnetworks_utils_hal_1_0_test
* neuralnetworks_utils_hal_1_1_test
* neuralnetworks_utils_hal_1_2_test
* neuralnetworks_utils_hal_1_3_test
* neuralnetworks_utils_hal_aidl_test
* neuralnetworks_utils_hal_common_test

Bug: 146324523
Test: neuralnetworks_utils_hal_*_test
Change-Id: I6c3cc00cd1ceefe4ae4ca5e40a8f3062d3251ff1
2021-08-11 21:54:44 +00:00
Ray Hernandez
ea89e30439 Revert "Making NN hardware interface libs "host supported""
Revert "Making NNAPI libraries and tests host supported"

Revert submission 1769046-neuralnetworks_host_build

Reason for revert: New Build Breakage
Reverted Changes:
Ib54d5c274:Making NNAPI libraries and tests host supported
I1d7c66516:Making NN hardware interface libs "host supported"...

Change-Id: I6f65774325889c50b9f8bbab13b557705419b6cf
2021-08-04 23:46:41 +00:00
rayhdez
a6d6002431 Making NN hardware interface libs "host supported"
Changing static libraries in hardware/interfaces/neuralnetworks to be
"host supported", meaning that the libraries within this directory
will be available on the host/linux build to make integration and
debugging more efficient.

Host Supported Libs:
* neuralnetworks_utils_hal_1_0
* neuralnetworks_utils_hal_1_1
* neuralnetworks_utils_hal_1_2
* neuralnetworks_utils_hal_1_3
* neuralnetworks_utils_hal_aidl
* neuralnetworks_utils_hal_common

Host Supported Tests:
* neuralnetworks_utils_hal_1_0_test
* neuralnetworks_utils_hal_1_1_test
* neuralnetworks_utils_hal_1_2_test
* neuralnetworks_utils_hal_1_3_test
* neuralnetworks_utils_hal_aidl_test
* neuralnetworks_utils_hal_common_test

Bug: 146324523
Test: neuralnetworks_utils_hal_*_test
Change-Id: I1d7c665169d2ce0c978b1e510e71f1371402a950
2021-07-27 22:14:05 +00:00
Michael Butler
e52a77efaa Simplify NNAPI SharedHandle -- hal
Prior to this CL, the NNAPI represented SharedHandle as a collection of
file descriptors and a vector of ints to act as metadata. This struct
mirrored Android's native_handle_t. However, the NNAPI only uses
SharedHandle to hold a single file descriptor to hold a single cache
file.

A sibling CL simplifies the SharedHandle by changing it to be a single
ref-counted file descriptor. This CL makes changes to the HAL utility
code in response to the SharedHandle change.

Bug: N/A
Test: mma
Test: NeuralNetworksTest_static
Change-Id: Ib390ad76bcdadffd85f8c2c502189aaa7da483e4
2021-06-08 20:14:52 -07:00
Xusong Wang
e3d0dad8d5 Use proper alignment and padding for pointer arguments -- HAL.
This CL modifies the shared memory allocation for pointer arguments to
use proper alignment and padding. We use default alignment (64) and
min padding (1) for HIDL drivers, and default alignment (64) and default
padding (64) for sAIDL drivers.

Bug: 184164929
Test: NNT_static
Change-Id: I22591640fa047d5f75d437edac1a7645d3b05526
Merged-In: I22591640fa047d5f75d437edac1a7645d3b05526
(cherry picked from commit 8bfa243972)
2021-05-11 09:17:34 -07:00
Xusong Wang
b2e8085ce2 Introduce reusable burst to canonical interface -- HAL.
This CL modifies the canonical interface for reusable burst executions:
- Add new method IBurst::createExecution

The reusable burst execution will not fallback to another execution path
if sending request packet fails. The behavior of single-time burst
execution remains unchanged.

Additionally, this CL enables pointer -> shared memory conversion in
1.2/1.3 burst implementation.

Bug: 184073769
Test: NNT_static
Test: neuralnetworks_utils_hal_1_0_test
Test: neuralnetworks_utils_hal_1_1_test
Test: neuralnetworks_utils_hal_1_2_test
Test: neuralnetworks_utils_hal_1_3_test
Test: neuralnetworks_utils_hal_common_test
Change-Id: Iaac81668d247c2cb76d70e6abbd10f00b397b19f
Merged-In: Iaac81668d247c2cb76d70e6abbd10f00b397b19f
(cherry picked from commit ead6d37ae9)
2021-05-10 15:22:08 -07:00
Xusong Wang
5f6bedb43a Introduce reusable execution to canonical interface -- HAL.
This CL modifies the canonical interface for reusable executions:
- Add new interface: IExecution with compute and computeFenced methods
- Add new method IPreparedModel::createExecution

In NNAPI runtime, the new interface IExecution is used to
memoize request-specific execution resources (e.g. converted HAL
request). The expected usage is that, IPreparedModel::createExecution
will be invoked in the first computation of a reusable NDK ANNExecution
object, and IExecution::compute* will be invoked repeatedly.

The IPreparedModel::execute* methods are preserved to avoid redundant
object creation and memoization overhead for a single-time
(non-reusable) execution.

For a vendor implementing the canonical interfaces, only the
IPreparedModel::execute* methods will be called because there is
currently no reusable execution at HAL interface. A DefaultExecution
implementation is provided to reduce the work needed on the vendor side.

Bug: 184073769
Test: NNT_static
Test: neuralnetworks_utils_hal_1_0_test
Test: neuralnetworks_utils_hal_1_1_test
Test: neuralnetworks_utils_hal_1_2_test
Test: neuralnetworks_utils_hal_1_3_test
Test: neuralnetworks_utils_hal_common_test
Test: neuralnetworks_utils_hal_aidl_test
Change-Id: I91790bb5ccf5ae648687fe603f88ffda2c9fd2b2
Merged-In: I91790bb5ccf5ae648687fe603f88ffda2c9fd2b2
(cherry picked from commit 727a7b2104)
2021-05-10 15:21:36 -07:00
Michael Butler
3e9720b83f Remove NN canonical IDevice::isUpdatable -- hal
This CL alters the AIDL utility "getDevices" to return whether or not a
service is updatable. This CL additional removes IDevice::isUpdatable
because it is now redundant with the changes to "getDevices".

Bug: 170696350
Test: mma
Test: NeuralNetworksTest_static
Change-Id: I86228763937c0dd2ee5b1d9d547c367cd7504ed4
2021-04-21 13:27:59 -07:00
Michael Butler
382d513dff Change NNAPI time from steady_clock to boot_clock -- hal
Previously, the NNAPI used std::chrono::steady_clock to represent and
measure timings. However, steady_clock does not count while the system
is suspended. Instead, boot_clock is monotonic like steady_clock but
does include the time when the system is suspended.

This change also indicates that services may convert from
std::chrono::steady_clock::time_point to
android::base::boot_clock::time_point in the HIDL 1.3 NN HAL.

Bug: 183118340
Test: mma
Test: VtsHalNeuralnetworksV1_3TargetTest
Test: VtsHalNeuralnetworksTargetTest
Test: presubmit
Change-Id: I5a7d039a31d9ce98602a301387ec99635f279f42
Merged-In: I5a7d039a31d9ce98602a301387ec99635f279f42
(cherry picked from commit b8cf54cf5a)
2021-04-06 15:00:49 -07:00
Michael Butler
8414a6ebf9 Add additional parameters for NN Burst -- HAL
Adds deadline and loopTimeoutDuration to nn::IBurst::execute.

This CL additionally adds a test case for
IPreparedModel::configureExecutionBurst and adds the suffix "_H" to
the header guards that were missing "_H".

Bug: 180492058
Bug: 177267324
Test: mma
Test: NeuralNetworksTest_static
Change-Id: Ic9ba2fb9b4dee4e40d99ae91bb9555a58d0508d2
Merged-In: Ic9ba2fb9b4dee4e40d99ae91bb9555a58d0508d2
(cherry picked from commit bbbdb0d5f1)
2021-04-02 22:02:38 -07:00
Michael Butler
388bcebc8f Add missing validation for NN canonical types
Bug: 177669661
Test: mma
Test: NeuralNetworksTest_static
Change-Id: Ic05c177f61a906a69bf82ff9c4d5bb8b0556d5ca
Merged-In: Ic05c177f61a906a69bf82ff9c4d5bb8b0556d5ca
(cherry picked from commit 08ee3f9287)
2021-04-02 22:02:02 -07:00
Xusong Wang
3633d07092 Rename BufferRole.frequency -> probability -- HAL.
"Frenquency" often refers to the number of occurrences over a period of
time, while "probability" refers to the number of occurrences of one
event over the number of occurrences of all events. "Probability" is a
better name for this field.

Fixes: 183117895
Test: VtsHalNeuralnetworksTargetTest
Test: NNT_static
Change-Id: Ic86f73b8be2aed567ae4ca17bdb3a57c658fb349
Merged-In: Ic86f73b8be2aed567ae4ca17bdb3a57c658fb349
(cherry picked from commit 46bf892f46)
2021-04-02 10:26:29 -07:00
Michael Butler
76e491fa46 Implement full canonical Burst in NN util code
Bug: 180492058
Bug: 177267324
Test: mma
Test: presubmit
Change-Id: I5018f6cf2dbaf705f74f4f46318142c64433e19d
Merged-In: I5018f6cf2dbaf705f74f4f46318142c64433e19d
(cherry picked from commit acff4063b6)
2021-03-16 11:57:19 -07:00
Lev Proleev
7b0b54697c Add missing NNAPI HIDL interface mock tests
prepareModelFromCache* was tested for handling of errors happening
during the preparation launch but not during the actual preparation.

Bug: 163801800
Test: mma
Test: atest neuralnetworks_utils_hal_common_test
Test: atest neuralnetworks_utils_hal_1_[0-3]_test
Change-Id: I2c4b235fd4877238d7a18be8b0ea051434c1df6b
Merged-In: I2c4b235fd4877238d7a18be8b0ea051434c1df6b
(cherry picked from commit c6cf50ad42)
2021-03-16 11:56:47 -07:00
Michael Butler
65de531533 Merge changes from topic "nnapi-numberOfConsumers"
* changes:
  Create NNAPI adapter interface
  Make NNAPI countNumberOfConsumers return GeneralResult -- hal
2021-02-23 20:01:01 +00:00
Bob Badour
b224b363de [LSC] Add LOCAL_LICENSE_KINDS to hardware/interfaces
Added SPDX-license-identifier-Apache-2.0 to:
  atrace/1.0/Android.bp
  atrace/1.0/default/Android.bp
  atrace/1.0/vts/functional/Android.bp
  audio/2.0/Android.bp
  audio/2.0/config/Android.bp
  audio/4.0/Android.bp
  audio/4.0/config/Android.bp
  audio/5.0/Android.bp
  audio/5.0/config/Android.bp
  audio/6.0/Android.bp
  audio/6.0/config/Android.bp
  audio/7.0/Android.bp
  audio/7.0/config/Android.bp
  audio/common/2.0/Android.bp
  audio/common/4.0/Android.bp
  audio/common/5.0/Android.bp
  audio/common/6.0/Android.bp
  audio/common/7.0/Android.bp
  audio/common/7.0/example/Android.bp
  audio/common/all-versions/default/Android.bp
  audio/common/all-versions/default/service/Android.bp
  audio/common/all-versions/test/utility/Android.bp
  audio/common/all-versions/util/Android.bp
  audio/core/all-versions/default/Android.bp
  audio/core/all-versions/default/util/Android.bp
  audio/core/all-versions/vts/functional/Android.bp
  audio/effect/2.0/Android.bp
  audio/effect/2.0/xml/Android.bp
  audio/effect/4.0/Android.bp
  audio/effect/4.0/xml/Android.bp
  audio/effect/5.0/Android.bp
  audio/effect/5.0/xml/Android.bp
  audio/effect/6.0/Android.bp
  audio/effect/6.0/xml/Android.bp
  audio/effect/7.0/Android.bp
  audio/effect/7.0/xml/Android.bp
  audio/effect/all-versions/default/Android.bp
  audio/effect/all-versions/default/util/Android.bp
  audio/effect/all-versions/vts/functional/Android.bp
  audio/policy/1.0/vts/functional/Android.bp
  audio/policy/1.0/xml/Android.bp
  audio/policy/1.0/xml/pfw_schemas/Android.bp
  authsecret/1.0/Android.bp
  authsecret/1.0/default/Android.bp
  authsecret/1.0/vts/functional/Android.bp
  authsecret/aidl/Android.bp
  authsecret/aidl/default/Android.bp
  authsecret/aidl/vts/Android.bp
  automotive/audiocontrol/1.0/Android.bp
  automotive/audiocontrol/1.0/default/Android.bp
  automotive/audiocontrol/1.0/vts/functional/Android.bp
  automotive/audiocontrol/2.0/Android.bp
  automotive/audiocontrol/2.0/default/Android.bp
  automotive/audiocontrol/2.0/vts/functional/Android.bp
  automotive/can/1.0/default/libnetdevice/Android.bp
  automotive/can/1.0/hidl-utils/Android.bp
  automotive/can/1.0/tools/Android.bp
  automotive/can/1.0/tools/configurator/Android.bp
  automotive/can/1.0/tools/configurator/proto/Android.bp
  automotive/can/1.0/tools/libcanhaltools/Android.bp
  automotive/can/1.0/vts/functional/Android.bp
  automotive/can/1.0/vts/utils/Android.bp
  automotive/evs/1.0/Android.bp
  automotive/evs/1.0/default/Android.bp
  automotive/evs/1.0/vts/functional/Android.bp
  automotive/evs/1.1/Android.bp
  automotive/evs/1.1/default/Android.bp
  automotive/evs/1.1/vts/functional/Android.bp
  automotive/evs/1.1/vts/fuzzing/Android.bp
  automotive/evs/common/utils/default/Android.bp
  automotive/evs/common/utils/default/test/fuzz/Android.bp
  automotive/occupant_awareness/aidl/Android.bp
  automotive/occupant_awareness/aidl/default/Android.bp
  automotive/occupant_awareness/aidl/mock/Android.bp
  automotive/occupant_awareness/aidl/vts/functional/Android.bp
  automotive/sv/1.0/Android.bp
  automotive/sv/1.0/default/Android.bp
  automotive/sv/1.0/vts/functional/Android.bp
  automotive/vehicle/2.0/Android.bp
  automotive/vehicle/2.0/default/Android.bp
  automotive/vehicle/2.0/default/impl/vhal_v2_0/proto/Android.bp
  automotive/vehicle/2.0/utils/Android.bp
  biometrics/face/1.0/Android.bp
  biometrics/face/1.0/default/Android.bp
  biometrics/face/1.0/vts/functional/Android.bp
  biometrics/fingerprint/2.1/Android.bp
  biometrics/fingerprint/2.1/default/Android.bp
  biometrics/fingerprint/2.1/vts/functional/Android.bp
  biometrics/fingerprint/2.2/Android.bp
  biometrics/fingerprint/2.2/vts/functional/Android.bp
  bluetooth/1.0/Android.bp
  bluetooth/1.0/default/Android.bp
  bluetooth/1.0/vts/functional/Android.bp
  bluetooth/1.1/Android.bp
  bluetooth/1.1/default/Android.bp
  bluetooth/1.1/vts/functional/Android.bp
  bluetooth/a2dp/1.0/Android.bp
  bluetooth/a2dp/1.0/default/Android.bp
  bluetooth/a2dp/1.0/vts/functional/Android.bp
  bluetooth/audio/2.0/Android.bp
  bluetooth/audio/2.0/default/Android.bp
  bluetooth/audio/2.0/vts/functional/Android.bp
  bluetooth/audio/2.1/Android.bp
  bluetooth/audio/2.1/default/Android.bp
  bluetooth/audio/2.1/vts/functional/Android.bp
  bluetooth/audio/utils/Android.bp
  boot/1.0/Android.bp
  boot/1.0/default/Android.bp
  boot/1.0/vts/functional/Android.bp
  boot/1.1/Android.bp
  boot/1.1/default/Android.bp
  boot/1.1/default/boot_control/Android.bp
  boot/1.1/vts/functional/Android.bp
  boot/1.2/Android.bp
  boot/1.2/default/Android.bp
  boot/1.2/vts/functional/Android.bp
  broadcastradio/1.0/Android.bp
  broadcastradio/1.0/default/Android.bp
  broadcastradio/1.0/vts/functional/Android.bp
  broadcastradio/1.1/Android.bp
  broadcastradio/1.1/default/Android.bp
  broadcastradio/1.1/vts/functional/Android.bp
  broadcastradio/2.0/Android.bp
  broadcastradio/2.0/default/Android.bp
  broadcastradio/2.0/vts/functional/Android.bp
  broadcastradio/common/tests/Android.bp
  broadcastradio/common/utils/Android.bp
  broadcastradio/common/utils1x/Android.bp
  broadcastradio/common/utils2x/Android.bp
  broadcastradio/common/vts/utils/Android.bp
  camera/common/1.0/Android.bp
  camera/common/1.0/default/Android.bp
  camera/device/1.0/Android.bp
  camera/device/1.0/default/Android.bp
  camera/device/3.2/Android.bp
  camera/device/3.2/default/Android.bp
  camera/device/3.3/Android.bp
  camera/device/3.3/default/Android.bp
  camera/device/3.4/Android.bp
  camera/device/3.4/default/Android.bp
  camera/device/3.5/Android.bp
  camera/device/3.5/default/Android.bp
  camera/device/3.6/Android.bp
  camera/device/3.6/default/Android.bp
  camera/metadata/3.2/Android.bp
  camera/metadata/3.3/Android.bp
  camera/metadata/3.4/Android.bp
  camera/metadata/3.5/Android.bp
  camera/provider/2.4/Android.bp
  camera/provider/2.4/default/Android.bp
  camera/provider/2.4/vts/functional/Android.bp
  camera/provider/2.5/Android.bp
  camera/provider/2.5/default/Android.bp
  camera/provider/2.6/Android.bp
  cas/1.0/Android.bp
  cas/1.0/default/Android.bp
  cas/1.0/vts/functional/Android.bp
  cas/1.1/Android.bp
  cas/1.1/default/Android.bp
  cas/1.1/vts/functional/Android.bp
  cas/1.2/Android.bp
  cas/1.2/default/Android.bp
  cas/1.2/vts/functional/Android.bp
  cas/native/1.0/Android.bp
  common/aidl/Android.bp
  common/fmq/aidl/Android.bp
  common/support/Android.bp
  compatibility_matrices/Android.bp
  compatibility_matrices/Android.mk
  compatibility_matrices/build/Android.bp
  compatibility_matrices/exclude/Android.bp
  configstore/1.0/Android.bp
  configstore/1.0/vts/functional/Android.bp
  configstore/1.1/Android.bp
  configstore/1.1/default/Android.mk
  configstore/utils/Android.bp
  confirmationui/1.0/Android.bp
  confirmationui/1.0/default/Android.bp
  confirmationui/1.0/vts/functional/Android.bp
  confirmationui/support/Android.bp
  contexthub/1.0/Android.bp
  contexthub/1.0/default/Android.bp
  contexthub/1.0/vts/functional/Android.bp
  contexthub/1.1/Android.bp
  contexthub/1.1/default/Android.bp
  contexthub/1.1/vts/functional/Android.bp
  contexthub/common/vts/Android.bp
  drm/1.0/Android.bp
  drm/1.0/default/Android.bp
  drm/1.0/vts/functional/Android.bp
  drm/1.1/Android.bp
  drm/1.1/vts/functional/Android.bp
  drm/1.2/Android.bp
  drm/1.2/vts/functional/Android.bp
  drm/1.3/Android.bp
  drm/1.3/vts/functional/Android.bp
  dumpstate/1.0/Android.bp
  dumpstate/1.0/default/Android.bp
  dumpstate/1.0/vts/functional/Android.bp
  dumpstate/1.1/Android.bp
  dumpstate/1.1/default/Android.bp
  dumpstate/1.1/vts/functional/Android.bp
  fastboot/1.0/Android.bp
  fastboot/1.0/default/Android.bp
  fastboot/1.1/Android.bp
  fastboot/1.1/default/Android.bp
  gatekeeper/1.0/Android.bp
  gatekeeper/1.0/default/Android.bp
  gatekeeper/1.0/software/Android.bp
  gatekeeper/1.0/software/tests/Android.bp
  gatekeeper/1.0/vts/functional/Android.bp
  gnss/1.0/Android.bp
  gnss/1.0/default/Android.bp
  gnss/1.0/vts/functional/Android.bp
  gnss/1.1/Android.bp
  gnss/1.1/default/Android.bp
  gnss/1.1/vts/functional/Android.bp
  gnss/2.0/Android.bp
  gnss/2.0/default/Android.bp
  gnss/2.0/vts/functional/Android.bp
  gnss/2.1/Android.bp
  gnss/2.1/default/Android.bp
  gnss/2.1/vts/functional/Android.bp
  gnss/common/utils/default/Android.bp
  gnss/common/utils/vts/Android.bp
  gnss/measurement_corrections/1.0/Android.bp
  gnss/measurement_corrections/1.1/Android.bp
  gnss/visibility_control/1.0/Android.bp
  graphics/allocator/2.0/Android.bp
  graphics/allocator/2.0/default/Android.bp
  graphics/allocator/2.0/utils/gralloc1-adapter/Android.bp
  graphics/allocator/2.0/utils/hal/Android.bp
  graphics/allocator/2.0/utils/passthrough/Android.bp
  graphics/allocator/3.0/Android.bp
  graphics/allocator/4.0/Android.bp
  graphics/bufferqueue/1.0/Android.bp
  graphics/bufferqueue/2.0/Android.bp
  graphics/common/1.0/Android.bp
  graphics/common/1.1/Android.bp
  graphics/common/1.2/Android.bp
  graphics/common/aidl/Android.bp
  graphics/composer/2.1/Android.bp
  graphics/composer/2.1/default/Android.bp
  graphics/composer/2.1/utils/command-buffer/Android.bp
  graphics/composer/2.1/utils/hal/Android.bp
  graphics/composer/2.1/utils/hwc2on1adapter/Android.bp
  graphics/composer/2.1/utils/hwc2onfbadapter/Android.bp
  graphics/composer/2.1/utils/passthrough/Android.bp
  graphics/composer/2.1/utils/resources/Android.bp
  graphics/composer/2.1/utils/vts/Android.bp
  graphics/composer/2.1/vts/functional/Android.bp
  graphics/composer/2.2/Android.bp
  graphics/composer/2.2/default/Android.mk
  graphics/composer/2.2/utils/command-buffer/Android.bp
  graphics/composer/2.2/utils/hal/Android.bp
  graphics/composer/2.2/utils/passthrough/Android.bp
  graphics/composer/2.2/utils/resources/Android.bp
  graphics/composer/2.2/utils/vts/Android.bp
  graphics/composer/2.2/vts/functional/Android.bp
  graphics/composer/2.3/Android.bp
  graphics/composer/2.3/default/Android.bp
  graphics/composer/2.3/utils/command-buffer/Android.bp
  graphics/composer/2.3/utils/hal/Android.bp
  graphics/composer/2.3/utils/passthrough/Android.bp
  graphics/composer/2.3/utils/vts/Android.bp
  graphics/composer/2.3/vts/functional/Android.bp
  graphics/composer/2.4/Android.bp
  graphics/composer/2.4/default/Android.bp
  graphics/composer/2.4/utils/command-buffer/Android.bp
  graphics/composer/2.4/utils/hal/Android.bp
  graphics/composer/2.4/utils/passthrough/Android.bp
  graphics/composer/2.4/utils/vts/Android.bp
  graphics/composer/2.4/vts/functional/Android.bp
  graphics/mapper/2.0/Android.bp
  graphics/mapper/2.0/default/Android.bp
  graphics/mapper/2.0/utils/hal/Android.bp
  graphics/mapper/2.0/utils/passthrough/Android.bp
  graphics/mapper/2.0/utils/vts/Android.bp
  graphics/mapper/2.0/vts/functional/Android.bp
  graphics/mapper/2.1/Android.bp
  graphics/mapper/2.1/default/Android.bp
  graphics/mapper/2.1/utils/hal/Android.bp
  graphics/mapper/2.1/utils/passthrough/Android.bp
  graphics/mapper/2.1/utils/vts/Android.bp
  graphics/mapper/2.1/vts/functional/Android.bp
  graphics/mapper/3.0/Android.bp
  graphics/mapper/3.0/utils/vts/Android.bp
  graphics/mapper/3.0/vts/functional/Android.bp
  graphics/mapper/4.0/Android.bp
  graphics/mapper/4.0/utils/vts/Android.bp
  graphics/mapper/4.0/vts/functional/Android.bp
  health/1.0/Android.bp
  health/1.0/default/Android.bp
  health/2.0/Android.bp
  health/2.0/default/Android.bp
  health/2.0/utils/libhealthhalutils/Android.bp
  health/2.0/utils/libhealthservice/Android.bp
  health/2.0/utils/libhealthstoragedefault/Android.bp
  health/2.0/vts/functional/Android.bp
  health/2.1/Android.bp
  health/2.1/default/Android.bp
  health/2.1/vts/functional/Android.bp
  health/storage/1.0/Android.bp
  health/storage/1.0/default/Android.bp
  health/storage/1.0/vts/functional/Android.bp
  health/storage/aidl/Android.bp
  health/storage/aidl/default/Android.bp
  health/storage/aidl/vts/functional/Android.bp
  health/storage/impl_common/Android.bp
  health/storage/test_common/Android.bp
  health/utils/libhealth2impl/Android.bp
  health/utils/libhealthloop/Android.bp
  identity/aidl/Android.bp
  identity/aidl/default/Android.bp
  identity/aidl/vts/Android.bp
  identity/support/Android.bp
  input/classifier/1.0/Android.bp
  input/classifier/1.0/default/Android.bp
  input/classifier/1.0/vts/functional/Android.bp
  input/common/1.0/Android.bp
  ir/1.0/Android.bp
  ir/1.0/default/Android.bp
  ir/1.0/vts/functional/Android.bp
  keymaster/3.0/Android.bp
  keymaster/3.0/default/Android.mk
  keymaster/3.0/vts/functional/Android.bp
  keymaster/4.0/Android.bp
  keymaster/4.0/default/Android.bp
  keymaster/4.0/support/Android.bp
  keymaster/4.0/vts/functional/Android.bp
  keymaster/4.0/vts/performance/Android.bp
  keymaster/4.1/Android.bp
  keymaster/4.1/default/Android.bp
  keymaster/4.1/support/Android.bp
  keymaster/4.1/vts/functional/Android.bp
  keymaster/aidl/Android.bp
  light/2.0/Android.bp
  light/2.0/default/Android.bp
  light/2.0/vts/functional/Android.bp
  light/aidl/Android.bp
  light/aidl/default/Android.bp
  light/aidl/vts/functional/Android.bp
  light/utils/Android.bp
  media/1.0/Android.bp
  media/1.0/xml/Android.mk
  media/Android.bp
  media/bufferpool/1.0/Android.bp
  media/bufferpool/2.0/Android.bp
  media/c2/1.0/Android.bp
  media/c2/1.1/Android.bp
  media/omx/1.0/Android.bp
  media/omx/1.0/vts/functional/audio/Android.bp
  media/omx/1.0/vts/functional/common/Android.bp
  media/omx/1.0/vts/functional/component/Android.bp
  media/omx/1.0/vts/functional/store/Android.bp
  media/omx/1.0/vts/functional/video/Android.bp
  memtrack/1.0/Android.bp
  memtrack/1.0/default/Android.bp
  memtrack/1.0/vts/functional/Android.bp
  memtrack/aidl/Android.bp
  memtrack/aidl/default/Android.bp
  memtrack/aidl/vts/Android.bp
  neuralnetworks/1.0/Android.bp
  neuralnetworks/1.0/utils/Android.bp
  neuralnetworks/1.0/vts/functional/Android.bp
  neuralnetworks/1.1/Android.bp
  neuralnetworks/1.1/utils/Android.bp
  neuralnetworks/1.1/vts/functional/Android.bp
  neuralnetworks/1.2/Android.bp
  neuralnetworks/1.2/utils/Android.bp
  neuralnetworks/1.2/vts/functional/Android.bp
  neuralnetworks/1.3/Android.bp
  neuralnetworks/1.3/utils/Android.bp
  neuralnetworks/1.3/vts/functional/Android.bp
  neuralnetworks/aidl/Android.bp
  neuralnetworks/aidl/utils/Android.bp
  neuralnetworks/aidl/vts/functional/Android.bp
  neuralnetworks/utils/common/Android.bp
  neuralnetworks/utils/service/Android.bp
  nfc/1.0/Android.bp
  nfc/1.0/default/Android.bp
  nfc/1.0/vts/functional/Android.bp
  nfc/1.1/Android.bp
  nfc/1.1/vts/functional/Android.bp
  nfc/1.2/Android.bp
  nfc/1.2/vts/functional/Android.bp
  oemlock/1.0/Android.bp
  oemlock/1.0/vts/functional/Android.bp
  oemlock/aidl/Android.bp
  oemlock/aidl/default/Android.bp
  oemlock/aidl/vts/Android.bp
  power/1.0/Android.bp
  power/1.0/default/Android.bp
  power/1.0/vts/functional/Android.bp
  power/1.1/Android.bp
  power/1.1/vts/functional/Android.bp
  power/1.2/Android.bp
  power/1.2/vts/functional/Android.bp
  power/1.3/Android.bp
  power/1.3/vts/functional/Android.bp
  power/aidl/Android.bp
  power/aidl/default/Android.bp
  power/aidl/vts/Android.bp
  power/stats/1.0/Android.bp
  power/stats/1.0/default/Android.bp
  power/stats/1.0/vts/functional/Android.bp
  power/stats/aidl/Android.bp
  power/stats/aidl/default/Android.bp
  power/stats/aidl/vts/Android.bp
  radio/1.0/Android.bp
  radio/1.0/vts/functional/Android.bp
  radio/1.1/Android.bp
  radio/1.1/vts/functional/Android.bp
  radio/1.2/Android.bp
  radio/1.2/default/Android.bp
  radio/1.2/vts/functional/Android.bp
  radio/1.3/Android.bp
  radio/1.3/vts/functional/Android.bp
  radio/1.4/Android.bp
  radio/1.4/vts/functional/Android.bp
  radio/1.5/Android.bp
  radio/1.5/vts/functional/Android.bp
  radio/1.6/Android.bp
  radio/1.6/vts/functional/Android.bp
  radio/config/1.0/Android.bp
  radio/config/1.0/default/Android.bp
  radio/config/1.0/vts/functional/Android.bp
  radio/config/1.1/Android.bp
  radio/config/1.1/vts/functional/Android.bp
  radio/config/1.2/Android.bp
  radio/config/1.2/vts/functional/Android.bp
  radio/config/1.3/Android.bp
  radio/config/1.3/vts/functional/Android.bp
  radio/deprecated/1.0/Android.bp
  rebootescrow/aidl/Android.bp
  rebootescrow/aidl/default/Android.bp
  rebootescrow/aidl/vts/functional/Android.bp
  renderscript/1.0/Android.bp
  renderscript/1.0/default/Android.bp
  renderscript/1.0/vts/functional/Android.bp
  secure_element/1.0/Android.bp
  secure_element/1.0/vts/functional/Android.bp
  secure_element/1.1/Android.bp
  secure_element/1.1/vts/functional/Android.bp
  secure_element/1.2/Android.bp
  secure_element/1.2/vts/functional/Android.bp
  security/keymint/aidl/Android.bp
  security/keymint/aidl/default/Android.bp
  security/keymint/aidl/vts/functional/Android.bp
  security/keymint/support/Android.bp
  security/secureclock/aidl/Android.bp
  security/secureclock/aidl/vts/functional/Android.bp
  security/sharedsecret/aidl/Android.bp
  security/sharedsecret/aidl/vts/functional/Android.bp
  sensors/1.0/Android.bp
  sensors/1.0/default/Android.bp
  sensors/1.0/vts/functional/Android.bp
  sensors/2.0/Android.bp
  sensors/2.0/default/Android.bp
  sensors/2.0/multihal/Android.bp
  sensors/2.0/vts/functional/Android.bp
  sensors/2.1/Android.bp
  sensors/2.1/default/Android.bp
  sensors/2.1/multihal/Android.bp
  sensors/2.1/vts/functional/Android.bp
  sensors/common/default/2.X/Android.bp
  sensors/common/default/2.X/multihal/Android.bp
  sensors/common/default/2.X/multihal/tests/Android.bp
  sensors/common/utils/Android.bp
  sensors/common/vts/2_X/Android.bp
  sensors/common/vts/utils/Android.bp
  soundtrigger/2.0/Android.bp
  soundtrigger/2.0/default/Android.bp
  soundtrigger/2.0/default/Android.mk
  soundtrigger/2.0/vts/functional/Android.bp
  soundtrigger/2.1/Android.bp
  soundtrigger/2.1/default/Android.mk
  soundtrigger/2.1/vts/functional/Android.bp
  soundtrigger/2.2/Android.bp
  soundtrigger/2.2/default/Android.bp
  soundtrigger/2.2/vts/functional/Android.bp
  soundtrigger/2.3/Android.bp
  soundtrigger/2.3/default/Android.bp
  soundtrigger/2.3/vts/functional/Android.bp
  tests/bar/1.0/Android.bp
  tests/bar/1.0/default/Android.bp
  tests/baz/1.0/Android.bp
  tests/baz/1.0/default/Android.bp
  tests/expression/1.0/Android.bp
  tests/extension/light/2.0/Android.bp
  tests/extension/light/2.0/default/Android.bp
  tests/extension/vibrator/aidl/Android.bp
  tests/extension/vibrator/aidl/client/Android.bp
  tests/extension/vibrator/aidl/default/Android.bp
  tests/foo/1.0/Android.bp
  tests/foo/1.0/default/Android.bp
  tests/foo/1.0/default/lib/Android.bp
  tests/hash/1.0/Android.bp
  tests/hash/1.0/default/Android.bp
  tests/inheritance/1.0/Android.bp
  tests/inheritance/1.0/default/Android.bp
  tests/lazy/1.0/Android.bp
  tests/lazy/1.1/Android.bp
  tests/libhwbinder/1.0/Android.bp
  tests/libhwbinder/1.0/default/Android.bp
  tests/libhwbinder/aidl/Android.bp
  tests/memory/1.0/Android.bp
  tests/memory/1.0/default/Android.bp
  tests/memory/2.0/Android.bp
  tests/msgq/1.0/Android.bp
  tests/msgq/1.0/default/Android.bp
  tests/multithread/1.0/Android.bp
  tests/multithread/1.0/default/Android.bp
  tests/safeunion/1.0/Android.bp
  tests/safeunion/1.0/default/Android.bp
  tests/safeunion/cpp/1.0/Android.bp
  tests/safeunion/cpp/1.0/default/Android.bp
  tests/trie/1.0/Android.bp
  tests/trie/1.0/default/Android.bp
  tetheroffload/config/1.0/Android.bp
  tetheroffload/config/1.0/vts/functional/Android.bp
  tetheroffload/control/1.0/Android.bp
  tetheroffload/control/1.0/vts/functional/Android.bp
  tetheroffload/control/1.1/Android.bp
  tetheroffload/control/1.1/vts/functional/Android.bp
  thermal/1.0/Android.bp
  thermal/1.0/default/Android.bp
  thermal/1.0/vts/functional/Android.bp
  thermal/1.1/Android.bp
  thermal/1.1/vts/functional/Android.bp
  thermal/2.0/Android.bp
  thermal/2.0/default/Android.bp
  thermal/2.0/vts/functional/Android.bp
  tv/cec/1.0/Android.bp
  tv/cec/1.0/default/Android.bp
  tv/input/1.0/Android.bp
  tv/input/1.0/default/Android.bp
  tv/input/1.0/vts/functional/Android.bp
  tv/tuner/1.0/Android.bp
  tv/tuner/1.0/default/Android.bp
  tv/tuner/1.0/vts/functional/Android.bp
  usb/1.0/Android.bp
  usb/1.0/default/Android.bp
  usb/1.0/vts/functional/Android.bp
  usb/1.1/Android.bp
  usb/1.1/vts/functional/Android.bp
  usb/1.2/Android.bp
  usb/1.2/vts/functional/Android.bp
  usb/gadget/1.0/Android.bp
  usb/gadget/1.1/Android.bp
  usb/gadget/1.1/default/Android.bp
  usb/gadget/1.1/default/lib/Android.bp
  vibrator/1.0/Android.bp
  vibrator/1.0/default/Android.bp
  vibrator/1.0/vts/functional/Android.bp
  vibrator/1.1/Android.bp
  vibrator/1.1/vts/functional/Android.bp
  vibrator/1.2/Android.bp
  vibrator/1.2/vts/functional/Android.bp
  vibrator/1.3/Android.bp
  vibrator/1.3/example/Android.bp
  vibrator/1.3/vts/functional/Android.bp
  vibrator/aidl/Android.bp
  vibrator/aidl/default/Android.bp
  vibrator/aidl/vts/Android.bp
  vr/1.0/Android.bp
  vr/1.0/default/Android.bp
  vr/1.0/vts/functional/Android.bp
  weaver/1.0/Android.bp
  weaver/1.0/vts/functional/Android.bp
  weaver/aidl/Android.bp
  weaver/aidl/default/Android.bp
  weaver/aidl/vts/Android.bp
  wifi/1.0/Android.bp
  wifi/1.0/vts/functional/Android.bp
  wifi/1.1/Android.bp
  wifi/1.1/vts/functional/Android.bp
  wifi/1.2/Android.bp
  wifi/1.2/vts/functional/Android.bp
  wifi/1.3/Android.bp
  wifi/1.3/vts/functional/Android.bp
  wifi/1.4/Android.bp
  wifi/1.4/default/Android.mk
  wifi/1.4/vts/functional/Android.bp
  wifi/hostapd/1.0/Android.bp
  wifi/hostapd/1.0/vts/functional/Android.bp
  wifi/hostapd/1.1/Android.bp
  wifi/hostapd/1.1/vts/functional/Android.bp
  wifi/hostapd/1.2/Android.bp
  wifi/hostapd/1.2/vts/functional/Android.bp
  wifi/offload/1.0/Android.bp
  wifi/offload/1.0/vts/functional/Android.bp
  wifi/supplicant/1.0/Android.bp
  wifi/supplicant/1.0/vts/functional/Android.bp
  wifi/supplicant/1.1/Android.bp
  wifi/supplicant/1.1/vts/functional/Android.bp
  wifi/supplicant/1.2/Android.bp
  wifi/supplicant/1.2/vts/functional/Android.bp
  wifi/supplicant/1.3/Android.bp
  wifi/supplicant/1.3/vts/functional/Android.bp

Added SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-NCSA to:
  Android.bp
  automotive/can/1.0/Android.bp
  automotive/can/1.0/default/Android.bp

Added SPDX-license-identifier-NCSA to:
  automotive/can/1.0/default/libc++fs/Android.bp

Bug: 68860345
Bug: 151177513
Bug: 151953481

Test: m all

Exempt-From-Owner-Approval: janitorial work

Change-Id: I602b072f77ff41e9eb8d3c36b6b5315d63664006
Merged-in: I602b072f77ff41e9eb8d3c36b6b5315d63664006
2021-02-21 20:36:55 -08:00
Michael Butler
68b6926e3c Make NNAPI countNumberOfConsumers return GeneralResult -- hal
Previously, countNumberOfConsumers would trigger a CHECK if the input
was invalid. This CL makes countNumberOfConsumers gracefully fail on
errors, instead returning the error through the GeneralResult.

Bug: N/A
Test: mma
Change-Id: Iee54f87768e52fdf701c22d94083c053b881733d
Merged-In: Iee54f87768e52fdf701c22d94083c053b881733d
(cherry picked from commit c4d98007fd)
2021-02-19 17:34:32 -08:00
Michael Butler
ab2f482af3 Store AHWB in NN canonical memory type -- hal
Prior to this CL, the canonical memory type only held a SharedHandle,
which mirrors the behavior of native_handle_t/hidl_handle. This means
memory types including AHardwareBuffer were stored as this SharedHandle
type. With this CL, the canonical memory type is stored directly as
AHardwareBuffer to avoid using non-NDK AHardwareBuffer calls in the NN
runtime.

Bug: 179906132
Test: mma
Test: NeuralNetworksTest_static
Test: presubmit
Change-Id: I394071c193d15ac0c90ac47e5a2a9a79c635db6c
Merged-In: I394071c193d15ac0c90ac47e5a2a9a79c635db6c
(cherry picked from commit bbe43d950e)
2021-02-17 10:15:39 -08:00
Michael Butler
fadeb8a920 Change NNAPI Memory to ref-counted SharedMemory -- hal
Bug: 179906132
Test: mma
Test: NeuralNetworksTest_static
Test: presubmit
Change-Id: I6435db906a2efe4938da18149a1fcd6d24730a95
Merged-In: I6435db906a2efe4938da18149a1fcd6d24730a95
(cherry picked from commit 79a16ebb6f)
2021-02-17 10:15:09 -08:00
Michael Butler
e5e67024c6 Add dynamic interface casting to NN utility code
Prior to this CL, the NN utility code would always use the type of
IPreparedModel provided by IPreparedModeCallback::notify*. This means
that an IPreparedModel returned as a dynamic type of V1_X but static
type of V1_Y would be used by the utility code as V1_Y. This CL adds
dynamic casting, such that an IPreparedModel returned as a dynamic type
of V1_X but static type V1_Y will be dynamically cast to V1_X and used
as a V1_X::IPreparedModel.

This CL also adds the utility functions
V1_[0123]::convertFromNonCanonical to convert from a non-canonical type
to another non-canonical type by using canonical types as an
intermediate conversion "hop."

Bug: 178180472
Test: mma
Change-Id: I709b2a8944af2cc78b089aade55df1e2ab7b40cc
Merged-In: I709b2a8944af2cc78b089aade55df1e2ab7b40cc
(cherry picked from commit 49b5e4ebea)
2021-02-09 15:28:15 +00:00
Michael Butler
95331510ad Implement partial canonical Burst in NN util code
This CL adds a simple implementation of IBurst that dispatches calls to
an IPreparedModel object and changes
IPreparedModel::configureExecutionBurst to return this new object
(instead of returning an error).

This CL additionally defines an InvalidBurst class that returns errors
whenever it is used and a ResilientBurst class to recover an IBurst
object when it has died.

Bug: 177267324
Test: mma
Change-Id: I4c7e7ff4e6559aeb5e62c4fa02f2e751fef9d87d
Merged-In: I4c7e7ff4e6559aeb5e62c4fa02f2e751fef9d87d
(cherry picked from commit 44f324fb0d)
2021-01-19 16:21:17 +00:00
Michael Butler
2a8b679bba Introduce canonical IBurst object in NNAPI -- hal
A sibling change to this change introduces a canonical IBurst object and
a new method IPreparedModel::configureExecutionBurst. This CL performs
minimal changes to the NN hal utility code to make the code still
compile.

Bug: 177267324
Test: mma
Change-Id: I076067289dde7def5622a6cb25233619f80efa41
Merged-In: I076067289dde7def5622a6cb25233619f80efa41
(cherry picked from commit b6a7ed5d5f)
2021-01-19 16:21:07 +00:00
Michael Butler
9adab0cf49 Add isUpdatable to NNAPI canonical IDevice -- hal
Bug: 177284207
Test: mma
Change-Id: I580d5325be91f566ee1c591736a87a94d0a74315
Merged-In: I580d5325be91f566ee1c591736a87a94d0a74315
(cherry picked from commit 080fbf755c)
2021-01-19 16:21:01 +00:00
Michael Butler
6e492a62e1 Create unit tests for NN interface utility code
This CL introduces unit tests to validate the V1_X::utils::Device,
*PreparedModel, and *Buffer adapter classes. It does so by mocking the
underlying HIDL interface in order to simulate a driver returning bad
data, HIDL transport failures, and service crashes.

Note that the purpose of these new tests is to validate the adapter
classes themselves, not the HIDL interfaces they use. For example,
because nn::IPreparedModel does not currently define a method for
configuring a burst execution, V1_[23]::utils::PreparedModel similarly
does not use hardware::neuralnetworks::V1_[23]::IPreparedModel's
configureExecutionBurst method.

This CL also introduces unit tests to validate the utils::Resilient*
adapter classes, and mocks DEAD_OBJECT failures to ensure that the
underyling object can be recovered appropriately.

Bug: 163801800
Test: mma
Test: atest neuralnetworks_utils_hal_common_test
Test: atest neuralnetworks_utils_hal_1_[0-3]_test
Change-Id: I2c79865bf666d3f4bf53061ff5090746403583e9
Merged-In: I2c79865bf666d3f4bf53061ff5090746403583e9
(cherry picked from commit afc4d7cfe7)
2021-01-08 12:07:43 -08:00
Michael Butler
7fd03c265e Cleanup NN callback error handling
This CL introduces a new templated class CallbackValue to handle HIDL
"return value" callbacks in a terser and more readable way.

This CL also introduces a new macro HANDLE_HAL_STATUS to return from the
current function when an error is present with the ability to append a
more descriptive error message.

Finally, this CL changes the behavior of synchronous executions. Prior
to this CL, IPreparedModel fell back to an asynchronous execution if the
synchronous execution was allowed and failed. This change instead
returns a failure if synchronous execution is allowed and fails.

Bug: 173084343
Test: mma
Change-Id: I62714a932e71dfc77401bbcb9eaaaf3d94fb9707
Merged-In: I62714a932e71dfc77401bbcb9eaaaf3d94fb9707
(cherry picked from commit 98ed9baf5d)
2020-12-21 21:09:37 -08:00
Michael Butler
aad934baa7 Add HIDL lifetime and protecting callback info to NN README
This CL copies information from
packages/modules/NeuralNetworks/runtime/VersionedInterfaces.cpp and
modifies the description to be more appropriate for the NN HAL utility
code.

Specific sections added to the README:
* "HIDL Interface Lifetimes across Processes"
* "Protecting Asynchronous Calls across HIDL"

Bug: 170289677
Test: mma
Change-Id: Id381895535d708b627f4746687b4d12e16560639
Merged-In: Id381895535d708b627f4746687b4d12e16560639
(cherry picked from commit 7a655bb3d4)
2020-12-21 21:09:14 -08:00
Michael Butler
4024d8f4d8 Change NN canonical timings to nanoseconds -- hal
A sibling CL to this CL changes the definition of nn::TimePoint to the
same type as std::chrono::steady_clock::time_point but has changed the
underlying duration representation to use uint64_t. That sibling CL also
renames nn::OptionalTimeoutDuration to nn::OptionalDuration, and changes
the definition to the same type as std::nanoseconds except the
underlying duration representation now uses uint64_t.

This CL makes changes to the NN HAL utility code in response to the
changes in the sibling CL.

Bug: 174297663
Test: mma
Test: NeuralNetworksTest_static
Change-Id: If44d9aefadb2c78b632ff289b5ff5a49f766525c
Merged-In: If44d9aefadb2c78b632ff289b5ff5a49f766525c
(cherry picked from commit ca11420785)
2020-12-21 21:08:43 -08:00
Michael Butler
cca3e20e23 Cleanup how transport errors are handled in NN utils
Prior to this change, whenever the NN utility code encountered a HIDL
transport error, the error message would display the file and line
number of the "handleTransportError" function itself. This change
introduces a new macro "HANDLE_TRANSPORT_FAILURE" that handles the
transport error in a similar way but now the error message displays
the file and line number of where the macro is called.

Bug: N/A
Test: mma
Change-Id: I35b34f8f5be52b7fcff0fbb58a37ab2b8c7dd8bb
Merged-In: I35b34f8f5be52b7fcff0fbb58a37ab2b8c7dd8bb
(cherry picked from commit 61f508e018)
2020-12-07 22:38:16 -08:00
Michael Butler
6547b2ac9c Validate during NN conversions by default -- hal
This change renames all `convert` functions to `unvalidatedConvert`.
This change also introduces new `convert` functions that act only on the
types that appear in the NN HIDL methods directly. These new `convert`
functions perform validation. Specifically, if either the source or
destination value is invalid, then the conversion fails.

Bug: 160667419
Test: mma
Test: NeuralNetworksTest_static
Change-Id: I492956ff60ad1466c67893993d28cdd6f3860708
Merged-In: I492956ff60ad1466c67893993d28cdd6f3860708
(cherry picked from commit 32acc06144)
2020-12-07 22:37:28 -08:00
Slava Shklyaev
77e06d8691 Fix a bug where 1.3 Device ignores 1.3 capabilities
Bug: 170289677
Test: NNT_static --gtest_filter=PartitioningTest.Perf
Change-Id: I476c7ab6ae807b4fd3ed27ec4d63aa6c04d0c7e1
Merged-In: I476c7ab6ae807b4fd3ed27ec4d63aa6c04d0c7e1
(cherry picked from commit d594cd0a4d)
2020-12-02 16:13:33 +00:00
Slava Shklyaev
49817a0e0f Replace nn::NativeHandle with nn::SharedHandle
Bug: 160669116
Test: mma
Change-Id: I73b2b93aab6cbf37d3c145e15ee9ae45228954f1
Merged-In: I73b2b93aab6cbf37d3c145e15ee9ae45228954f1
(cherry picked from commit d4290b8bf8)
2020-11-20 13:55:05 +00:00