Commit graph

9553 commits

Author SHA1 Message Date
Kevin Rocard
74980b56eb Audio V4: Fix documentation and useable/untestable bugs
Add missing documentation, especially for failure cases
and methods that are optional.
Add missing operation status for testability.
Add format for getSupported* methods as they could not
be implemented in 2.0 for multi-format stream (HDMI).

Test: compile
Bug: 38184704
Change-Id: I14ee5e02ef70a82df6de732f88b065810e9b032f
Signed-off-by: Kevin Rocard <krocard@google.com>
2018-01-31 23:09:23 -08:00
Michael Butler
162aa583b8 Create NeuralNetworks HAL v1.1 for new OperationTypes
Test: mm
Change-Id: I08efaba79ec28a2f89e94a84ab88b0fa701b7d98
(cherry picked from commit 5c6ee9ecef)
2018-01-31 15:42:11 -08:00
Chia-I Wu
5255c35a70 graphics: move libVtsHalGraphicsMapperTestUtils
Move libVtsHalGraphicsMapperTestUtils from 2.0/vts/functional/ to
2.0/utils/vts/.  Run clang-format.

Test: VTS
Change-Id: I1e87129cbdc12167160f7e2f1cd76478e88bbf41
2018-01-31 15:11:50 -08:00
Chia-I Wu
821c4c4a9d graphics: make mapper default impl a header library
Reimplement the default impl as a header-only library,
android.hardware.graphics.mapper@2.0-passthrough, based on the HAL
support library.

Effectively, this renames Gralloc[01]Mapper to Gralloc[01]Hal, and
make adjustments here and there to meet the requirements of the HAL
support library.  This also adds GrallocLoader to load either of
Gralloc[01]Hal and create an IMapper instance.

libgrallocmapperincludes is renamed to follow the new naming and
include path conventions.

Test: boots and VTS
Change-Id: I924cadce9a10a6e544f99ceba63aadc38ec431ac
2018-01-31 15:11:50 -08:00
Chia-I Wu
fd1924f6f5 graphics: add mapper HAL support library
Add a header-only support library
android.hardware.graphics.mapper@2.0-hal that can be used by
implementations.  There are two classes in the support library.
MapperHal is an abstract class to be implemented by implementations.
Mapper is an implementation of HIDL IMapper interface on top of
MapperHal.

An implementation can

  class VendorHal : public MapperHal { ... };

  auto mapper = std::make_unique<Mapper>();
  mapper->init(std::make_unique<VendorHal>(...));

Or, if vendor extensions are to be added to the IMapper,

  class MapperHalExt : public MapperHal { ... };
  class VendorHal : public MapperHalExt { ... };
  class MapperExt : public MapperImpl<IMapperExt, MapperHalExt> { ... };

  auto mapper = std::make_unique<MapperExt>();
  mapper->init(std::make_unique<VendorHal>(...));

Test: builds
Change-Id: Ib23c1f5977744f7e116bb93db53e882e2dad7ce3
2018-01-31 15:11:50 -08:00
Chia-I Wu
422b94e002 graphics: make allocator passthrough library header-only
android.hardware.graphics.allocator@2.0-passthrough should be a
header-only library to be fully reusable by vendor HALs.

This also allows us to switch from virtual inheritance to templates,
which is more straightforward.  This changes nothing to the users
and we still have these relations

 - AllocatorHal is an abstract class to be implemented by vendors or
   the default implementations
 - Gralloc[01]Hal are our default implementations
 - Allocator implements HIDL IAllocator interface on top of
   AllocatorHal

What we do not like about virtual inheritance is that, given

  // abstract class B and D
  class B {
    virtual void foo() = 0;
    virtual void bar() = 0;
  };
  class D : public virtual B {
    // foo is superceded by fooEnhanced in D
    void foo() { fooEnhanced(); }
    virtual void fooEnhanced() = 0;
  };

  // an implementation of B
  class BImpl : public virtual B {
    void foo() {}
    void bar() {}
  };

  // an implementation of D on top of BImpl
  class DImpl : public virtual D, public virtual BImpl {
    void fooEnhanced() {}
  };

we get "no unique final overrider" becase both D and BImpl implement
foo.  With non-virtual inheritance, on the other hand, we get "DImpl
is abstract" because foo is still pure virtual implemented in DImpl.
Templates solve the issue by allowing

  namespace detail{
  template<typename T>
  class BImpl : public T { ... };

  template<typename T>
  class DImpl : public BImpl<T> { ... };
  } // namespace detail

  using BImpl = detail::BImpl<B>;
  using DImpl = detail::DImpl<D>;

Test: boots
Change-Id: Iccb513e4fc751e9a687a1ed2d9fb2192c8324a50
2018-01-31 15:11:50 -08:00
TreeHugger Robot
52d951b8eb Merge "Add GNSS VTS test for IGnssDebug.TimeDebug values sanity check" 2018-01-31 22:38:27 +00:00
Ruchi Kandoi
22a4d0e07e Add VTS Test for Secure Element HAL
Test: Run VTS test
Bug: 64881253
Change-Id: If77d87c88bd073409dce3d18aba8f15a1267a80e
2018-01-31 11:51:48 -08:00
Kevin Rocard
a4e6d8b1de Audio V4: Copy 2.0 .hal files in 4.0
That will ease review of the changes.
The only changes are:
 - replace all @2.0 by 4.0
   $ sed -i 's/@2\.0/@4\.0/g' */4.0/*.hal
 - replace all licence 2016 by 2018
   $ sed -i 's/2016/2018/g' */4.0/*.hal

Moving the .hal in a subfolder forces the package name and the
namespace to change.

This mean that the audio HAL 2.0 and 4.0 will not be consider
different version of the same HAL but two different HALs.

As a result to minimize code change due to tight deadline,
keep the 4.0 core in the audio folder.

Bug: 38184704
Test: hardware/interfaces/update-makefiles.sh
Change-Id: I7c7a826270c9933091f037b795806787e1284583
Signed-off-by: Kevin Rocard <krocard@google.com>
2018-01-31 10:39:47 -08:00
Miao Wang
1bdf3d835c Merge "Create NeuralNetworks HAL v1.1 for new OperationTypes" 2018-01-31 17:34:30 +00:00
Yifan Hong
9fe3cc4e34 health 2.0: update README for typo. am: de542acbbf am: 6271c38c90
am: a9e9f9182d

Change-Id: Ia2997a95ca4034e79895197c56206e0cd0a7a379
2018-01-31 02:33:45 +00:00
Yifan Hong
5c32b61858 health: add README. am: 3e6dbcbc30 am: 28068121ce
am: ed795844a6  -s ours

Change-Id: I04114c54a61805a630c7754e173d4dcec6c49361
2018-01-31 02:33:39 +00:00
Ruchi Kandoi
8d358cb471 Add SecureElement HAL interface am: 241e5aba9e am: a9938a3d57
am: 8d25fb59e8

Change-Id: I008784ef03794a369466b6f76026b1afd5eb2987
2018-01-31 02:33:18 +00:00
Yifan Hong
a9e9f9182d health 2.0: update README for typo. am: de542acbbf
am: 6271c38c90

Change-Id: I9f5b13e620efe65e4917da5446035f1e691cf888
2018-01-31 02:10:09 +00:00
Yifan Hong
ed795844a6 health: add README. am: 3e6dbcbc30
am: 28068121ce

Change-Id: I69690fd96d566d1d38e81314bdcd3d010c609fb7
2018-01-31 02:10:04 +00:00
Ruchi Kandoi
8d25fb59e8 Add SecureElement HAL interface am: 241e5aba9e
am: a9938a3d57

Change-Id: Ibac179a8a996d97cea169d12e776ca8e71b49301
2018-01-31 02:09:47 +00:00
Yifan Hong
6271c38c90 health 2.0: update README for typo.
am: de542acbbf

Change-Id: Id443c3ea9949d77119d9e619a85f8fe53ca64f3b
2018-01-31 01:58:16 +00:00
Yifan Hong
28068121ce health: add README.
am: 3e6dbcbc30

Change-Id: If4d64db9bb3febed1a5d48f2d24d8a158a0880d9
2018-01-31 01:58:11 +00:00
Ruchi Kandoi
a9938a3d57 Add SecureElement HAL interface
am: 241e5aba9e

Change-Id: I80adcfbfe36c6bcb0a2b1e3e52624d92781c58cf
2018-01-31 01:57:52 +00:00
TreeHugger Robot
bc72cdf1ea Merge "Remove unused property from Vehicle HAL" 2018-01-31 01:30:30 +00:00
TreeHugger Robot
f04f687d0d Merge "android.hardware.media.bufferpool@1.0 HAL" 2018-01-31 00:36:35 +00:00
Yu-Han Yang
de41625b4e Add GNSS VTS test for IGnssDebug.TimeDebug values sanity check
Bug: 36567271

Test: Copied the change to v1.0 and tested on Walleye.

Change-Id: I891ac655738cea72a67406dce954bbce34fc03ad
2018-01-30 16:32:14 -08:00
Yifan Hong
de542acbbf health 2.0: update README for typo.
Test: none
Change-Id: Iaede40e22b909a06592dceedb3b430232ced0b1a
2018-01-30 15:32:30 -08:00
Yifan Hong
3e6dbcbc30 health: add README.
Test: none
Bug: 63702641
Change-Id: I1d23c0cdf56516585e7c6dd0db577784baa7b74e
Merged-In: I1d23c0cdf56516585e7c6dd0db577784baa7b74e
2018-01-30 15:06:21 -08:00
Jorim Jaggi
62df80180b Merge "Revert "Add "Unlocked device required" parameter to keys"" 2018-01-30 15:36:28 +00:00
Brian Young
95b60a0f41 Revert "Add "Unlocked device required" parameter to keys"
This reverts commit 5fe872413b.

Reason for revert: Build breakages on elfin, gce_x86_phone.

Bug: 72679761
Bug: 67752510
Change-Id: I2857b2a9b6ff26735bd4989a36c5e5deb4953904
2018-01-30 15:31:19 +00:00
Michael Butler
5c6ee9ecef Create NeuralNetworks HAL v1.1 for new OperationTypes
Test: mm
Change-Id: I08efaba79ec28a2f89e94a84ab88b0fa701b7d98
2018-01-29 22:24:13 -08:00
TreeHugger Robot
4c5bfc6979 Merge "Camera: add buffer size to Stream" 2018-01-30 06:05:25 +00:00
TreeHugger Robot
76a434e67d Merge "Add new secure stop methods" 2018-01-30 02:16:44 +00:00
Steve Paik
ded5e17510 Modify FAN_DIRECTION to be a bit mask
We are changing VehicleHvacFanDirection to be a bit mask so that any
combination of fan directions can be made.  This means that
HVAC_FAN_DIRECTION_AVAILABLE must now be a int32_vector.

Bug: 72221544
Test: Unit tests pass
Change-Id: I602871c95aa2429ea334ec85a879610c68979184
2018-01-29 16:52:52 -08:00
Sungtak Lee
108a2fe68c android.hardware.media.bufferpool@1.0 HAL
BufferPool HAL for allocating, deallocating, and recycling buffers
on behalf of media.stagefright.

Bug: 72651719
Change-Id: I30bf630e41de2c8718aaaf8cbf5ee3f48f2859bc
2018-01-29 15:49:41 -08:00
TreeHugger Robot
ea52a4d3b8 Merge "Add "Unlocked device required" parameter to keys" 2018-01-29 23:16:02 +00:00
Jeff Tinker
80da0aa06f Add new secure stop methods
Methods are needed to release a secure stop by ID and
return a list of secure stops.

Tests: gts media tests

bug:67361434
bug:64001680
Change-Id: I53cb0671b9b775e8da16bcc61008e1700466180b
2018-01-29 14:27:29 -08:00
TreeHugger Robot
3e2f90f9ca Merge "Implement JPEG support in external camera HAL" 2018-01-29 21:55:52 +00:00
Yuriy Romanenko
e932f1b5cb Implement JPEG support in external camera HAL
* Certain tests are still failing

Change-Id: I01bb90757cd969ace30857a8d246e4701498d379
2018-01-29 12:07:34 -08:00
Yu-Han Yang
22f1b90e16 Add GNSS VTS test for GnssDebug position values
sanity check.

Bug: 36567271

Test: vts-tradefed run commandAndExit vts \
--skip-all-system-status-check \
--primary-abi-only --skip-preconditions -l VERBOSE \
--module VtsHalGnssV1_0Target

Change-Id: I4fc2caf757743481f84ee1ec679082842c46adbd
2018-01-29 10:31:18 -08:00
Yuriy Romanenko
33d5f66633 Common: Added CameraMetadata -> libexif converter
A fully-ported version of the ExifUtils class from
ChromeOS (see [chromeos]/src/platform/arc-camera/common/exif_utils.cc)

 * Made into an interface to remove libexif dependencies
   from header file
 * Rewrote ChromeOS dependencies
 * Minor fixes

Change-Id: I2e93fa3e08e6b82b26641cc736eeb1c61b04a2c0
2018-01-26 21:23:56 -08:00
TreeHugger Robot
8ed63de92f Merge "Wifi: Add Support for Body Proximity for SAR" 2018-01-27 02:50:18 +00:00
Yin-Chia Yeh
b534d9bf29 Camera: add buffer size to Stream
So that HALs without device knowledge knows the maximal size
it can lock using graphics mapper API.

Bug: 64874137 72261675
Change-Id: I7363f5c63d955ab412f9570bf8e5be2a942cf381
2018-01-26 16:50:24 -08:00
Ahmed ElArabawy
6a1accf8ba Wifi: Add Support for Body Proximity for SAR
This commit extends the SAR support to include scenarios for near
head/body and voice calls
These features are only applicale for a certain device capability
(defined in capability mask)

Bug: 3489513
Test: Manual

Change-Id: Ie99978df3c19e04fdd3d7862240f6d3c62eac539
Signed-off-by: Ahmed ElArabawy <arabawy@google.com>
2018-01-26 16:34:10 -08:00
Yuriy Romanenko
083de0c3c6 ExternalCameraDeviceSession: Fix request initialization
This code was exiting because of unsupported RequestTemplate::*
enum values that are now just ignored.

Change-Id: I37f79cbbfe99664ec173458721d71947f0d002ff
2018-01-26 16:11:12 -08:00
TreeHugger Robot
e210c3cddf Merge "Fix missing copies of status member variable" 2018-01-26 21:17:33 +00:00
Pavel Maltsev
eccbbf8538 Remove unused property from Vehicle HAL
Fix: b/72159812

Test: m -j ; verified device is booting up

Change-Id: I99b59d58dd713d48c50be1a12d9ee2019861c080
2018-01-26 11:59:31 -08:00
Steve Paik
54f2ac6994 Fix missing copies of status member variable
Bug: 72348165
Test: Status appears in Embedded Kitchen Sink
Change-Id: Ia6a672fa44f0c1d5a7fe04234897d73b3f45e939
2018-01-26 11:10:45 -08:00
TreeHugger Robot
2d638c49ac Merge "Support library enhancements, to ease transition of vold to KM4" 2018-01-26 09:07:16 +00:00
Shawn Willden
98b998b59a Support library enhancements, to ease transition of vold to KM4
Keymaster clients need to see all the available devices and figure out
which they want to use.  This method finds them all and returns them
in a vector sorted from most secure to least, according to a heuristic
defined in Keymaster::VersionResult::operator<

This CL also makes a few other minor improvements to the support
library, providing more information in VersionResult and adding some
more convenience methods in AuthorizationSetBuilder.

Test: Build & boot
Change-Id: I876238ee9ff72573c30d60e1cec665dd610bcde6
2018-01-25 22:38:56 -07:00
TreeHugger Robot
fa58d40b69 Merge "HIDL changes to support Stadium Wifi." 2018-01-26 04:57:55 +00:00
Hongwei Wang
d879f7a131 Merge "Runs audio control service in delicated user" 2018-01-26 03:24:45 +00:00
TreeHugger Robot
a4c3b60c2c Merge "Update emulator protobuf to include status" 2018-01-26 03:24:18 +00:00
Jack Yu
f32d1978cd Merge "HIDL changes for IWLAN refactoring" am: 4365f2e6bc am: fd428d8f4d
am: c77519448b

Change-Id: Ia8f014fb1492eb9276ed56e80a23744000f90625
2018-01-26 01:45:58 +00:00