Commit Graph

220 Commits

Author SHA1 Message Date
Konsta
27d5b9a0b8 v4l2: don't allocate using ion
Codec2.0 poolMask:
  ION(16)
  BUFFERQUEUE(18)
  BLOB(19)
  V4L2_BUFFERQUEUE(20)
  V4L2_BUFFERPOOL(21)
  SECURE_LINEAR(22)
  SECURE_GRAPHIC(23)

For linear buffer allocation:
  If ION is chosen, then the mask should be 0xf50000
  If BLOB is chosen, then the mask should be 0xfc0000

0xf50000 -> 11110101 0000000000000000
0xfc0000 -> 11111100 0000000000000000
2025-04-02 13:57:38 +03:00
Konsta
0dc4975917 sepolicy: allow keymint to read serialno property 2025-04-02 13:55:01 +03:00
Konsta
8a1b860709 sepolicy: allow vendor_init to set cec property 2025-04-02 13:54:52 +03:00
Konsta
ee074c799e v4l2: use vendor properties 2025-04-02 13:54:26 +03:00
Konsta
e5346626fc ffmpeg: use vendor properties 2025-04-02 13:53:58 +03:00
Konsta
6456ba251c audio: use vendor properties 2025-04-02 13:53:41 +03:00
Konsta
d10016b71d audio: auto probe pcm card for jack & dac
* When 'jack' is selected using the property, first PCM card that has name
  'Headphones' is used.
  When 'dac' is selected, first PCM card that is not named 'Headphones',
  'vc4hdmi0', or 'vc4hdmi1' is used.
2025-04-02 13:53:14 +03:00
Konsta
4aa73b41a6 audio: cache pcm card and device
* It's always been intended that changing audio output devices requires
  a reboot. Get the PCM card and device once when the HAL is initialized.
  Might save a few ms on start_output_stream.
2025-04-02 13:52:36 +03:00
Konsta
bc7579e2a5 hdmi audio: cache alsa device
* It's always been intended that changing audio output devices requires
  a reboot. Get the ALSA device once when the HAL is initialized.
  Might save a few ms on start_output_stream.
2025-04-02 13:52:25 +03:00
Konsta
5420780e92 bump shipping api level
* HIDL services are not included on API level 35. Add the services since
  we're still using few HIDL HALs.
  4ce8327a8f
* FCM level can't be bumped to 202404 until all HALs have been updated to
  AIDL i.e. at least following HALs reported by 'make check-vintf-all'.

All HALs in device manifest are declared in FCM <= level 202404
ERROR: files are incompatible:
...
android.hardware.camera.provider@2.5::ICameraProvider/legacy/0 is deprecated in compatibility matrix at FCM Version 202404; it should not be served.
    because it matches android.hardware.camera.provider@2.4::ICameraProvider/[^/]+/[0-9]+ from /system/etc/vintf/compatibility_matrix.7.xml
android.hardware.audio@7.1::IDevicesFactory/default is deprecated in compatibility matrix at FCM Version 202404; it should not be served.
    because it matches android.hardware.audio@7.0::IDevicesFactory/default from /system/etc/vintf/compatibility_matrix.8.xml
android.hardware.audio.effect@7.0::IEffectsFactory/default is deprecated in compatibility matrix at FCM Version 202404; it should not be served.
    because it matches android.hardware.audio.effect@7.0::IEffectsFactory/default from /system/etc/vintf/compatibility_matrix.8.xml: Success
INCOMPATIBLE
2025-03-31 19:34:18 +03:00
Konsta
05888d86db camera: add to framework compatibility matrix
* Picked up by 'make check-vintf-all'.

The following instances are in the device manifest but not specified in framework compatibility matrix:
    android.hardware.camera.provider@2.5::ICameraProvider/legacy/0
2025-03-31 19:34:03 +03:00
Konsta
46fe18c658 remove device compatibility matrix
* Use default device compatibility matrix from
  system/libhidl/vintfdata/device_compatibility_matrix.default.xml.
* 282994a8a2
2025-03-31 19:33:55 +03:00
Konsta
2e6ec77756 sepolicy: 64-bit only 2025-03-31 19:33:45 +03:00
Konsta
be863bb0bf switch to 64-bit only target 2025-03-31 19:33:37 +03:00
Konsta
48b4fe88df sepolicy: indent file_context and service_contexts by section 2025-03-28 23:40:19 +02:00
Konsta
f3eec1f842 sepolicy: move sysfs entries to genfs_contexts
* rfkill nodes are already labeled by default.
2025-03-28 23:39:13 +02:00
Konsta
2241197367 sepolicy: label wakeup node 2025-03-28 23:39:04 +02:00
Konsta
b6700c25a6 sepolicy: various fixes for graphics 2025-03-28 23:38:38 +02:00
Konsta
e6363fd2d6 sepolicy: fix label type for hdmi connection nodes
* Gets cought with neverallow rules.
* Fixes f6fe82c411.
2025-03-27 12:41:49 +02:00
Konsta
08303135d2 hdmi: connection: convert to apex 2025-03-25 18:00:14 +02:00
Konsta
b7cafd27c1 hdmi: cec: convert to apex 2025-03-25 18:00:03 +02:00
Konsta
f6fe82c411 hdmi: connection: add rpi specific aidl hal
* Needed for AIDL HDMI-CEC HAL to work. Some functions that were in the
  HIDL HDMI-CEC HAL have been moved to separate HDMI connection HAL in the
  AIDL versions. Only returns connection status of HDMI ports on Pi.
  onHotplugEvent is not implemented.
* Use hardware/interfaces/tv/hdmi/connection/aidl/ as reference.
2025-03-25 17:59:46 +02:00
Konsta
667fad95e6 hdmi: cec: remove onHotplugEvent
* HDMI connection HAL should manage this.
2025-03-25 17:58:58 +02:00
Konsta
50cc6c9ca9 hdmi: cec: move to subdir 2025-03-25 17:58:49 +02:00
Konsta
6fbb90fa33 cec: add device type property
* e2b6b1cfe2
  e7a511f911
2025-03-25 17:58:37 +02:00
Konsta
3022586712 cec: use vendor property for device & remove unneeded properties
* Use vendor property to allow labeling it for SELinux.
* Remove unneeded properties to set version and vendor id. Using the
  default values in any case.
2025-03-25 17:58:26 +02:00
Konsta
47a329c4e4 cec: convert to aidl
* Use hardware/interfaces/tv/hdmi/cec/aidl/ as reference.
2025-03-25 17:58:14 +02:00
Konsta
4ffea81903 suspend_blocker: convert to apex
* Start the service later at 'class hal' to avoid making this into bootstrap
  APEX. 'class early_hal' is started on trigger 'on late-fs' which is too
  early for vendor APEX.
2025-03-20 13:38:59 +02:00
Konsta
080a9d7c3a add chipset properties
* This became needed for CTS some years ago.
  faa63a37c0
2025-03-20 13:38:42 +02:00
Konsta
e82989d87f wifi: package hostapd and wpa_supplicant into apex
* This is now possible on Android 15 QPR2. Use cuttlefish as reference.
  https://android.googlesource.com/device/google/cuttlefish/+/refs/tags/android-15.0.0_r20/apex/com.google.cf.wpa_supplicant/
* Create local copies of the service entries. Generally creating the
  directories for wireless subsystem happens on trigger 'on post-fs-data'.
  Since apexd for non-bootstrap APEXs starts 'on post-fs-data', this
  trigger is not available for vendor APEX packages. Use trigger
  'apex.all.ready=true' instead which is later still within post-fs-data.
  https://source.android.com/docs/core/ota/vendor-apex#init-scripts
* Create a local copy of wpa_supplicant_overlay.conf. It hasn't been updated
  in ten years in hardware/broadcom/wlan. TODO: Check relevance.
2025-03-19 12:23:04 +02:00
Konsta
6db460055a wifi: switch to apex 2025-03-19 12:22:56 +02:00
Konsta
00e46f0d1e usb: convert gadget to apex 2025-03-19 12:22:48 +02:00
Konsta
faabc62ea4 usb: switch to apex 2025-03-19 12:22:40 +02:00
Konsta
ca95b7824f power: switch to apex
* In addtion to android.hardware.power-service.example,
  com.android.hardware.power APEX also contains
  android.hardware.power.stats-service.example.
2025-03-19 12:22:32 +02:00
Konsta
e288798b65 light: convert to apex 2025-03-19 12:22:24 +02:00
Konsta
543cb97137 health: convert to apex 2025-03-19 12:22:15 +02:00
Konsta
e03e665eec graphics: switch hwcomposer to apex 2025-03-19 12:22:07 +02:00
Konsta
aa53179895 drm: switch clearkey to apex 2025-03-19 12:21:20 +02:00
Konsta
7d91c1b33c bluetooth: convert to apex
* Use device as an identifier in package names so APEXs on rpi4/rpi5 trees
  can co-exist. Somehow apex definitions escape the soong namespace. It
  doesn't complain about duplicate package names but dependecies later in
  the build after analyzing Android.bp files and generating ninja file.
  FAILED: ninja: ... multiple rules generate com.android.hardware.bluetooth.rpi-deps-info [-w dupbuild=err]
  https://android.googlesource.com/platform/build/soong/+/refs/heads/main/README.md#namespaces
* Not sure if this is an AOSP bug or intended behaviour for apex targets.
  Don't like using the rpi4/rpi5 tags but couldn't come up with better
  solution to limit the visibility that worked.
* General cleanups. As APEX package contains all dependencies that are
  needed for the service, remove unused shared libraries.
  Run 'bpfmt -s -w Android.bp'.
2025-03-19 12:20:30 +02:00
Konsta
146369a9a4 bluetooth: remove unused BDROID_BUILDCFG header
* Doesn't do anything if BOARD_HAVE_BLUETOOTH_BCM is not set.
* Bluetooth device name is parsed from 'ro.product.model' if no default
  is provided using 'bluetooth.device.default_name' property.
2025-03-18 23:49:39 +02:00
Konsta
221f89b35f set TARGET_BOOTLOADER_BOARD_NAME
* Populate 'ro.product.board' as well.
* Fixes b310542c14.
2025-03-18 20:26:49 +02:00
Konsta
8fc1e786fc Revert "car: Disabled BT MAP causing cyclic BT reconnect"
* This should be enabled on automotive targets and I can't reprocude any
  connection issues described in https://github.com/raspberry-vanilla/android_local_manifest/issues/33.
* Partially fixes https://github.com/raspberry-vanilla/android_local_manifest/issues/110.

This reverts commit 973797e543.
2025-03-18 16:38:10 +02:00
Konsta
06c2ae2559 car: device path has car directory
* Fixes ef8706e703.
2025-03-18 16:38:02 +02:00
Konsta
c8117b1305 cleanup device identifiers
* Drop Raspberry from model as some hardware information applications
  display it after the manufacturer/brand and we'll end up with duplicate
  Raspberry in the device name.
* PRODUCT_RELEASE_NAME is long gone.
2025-03-18 16:37:54 +02:00
Konsta
b310542c14 set hardware platform name
* Some hardware information applications use this so set actual hardware
  platform name.
* Historic reason why this was set to rpi is that this allowed to use same
  HALs on rpi3/rpi4 when they were commonized. 'ro.board.platform' this sets
  is used in the legacy module load order.
  https://android.googlesource.com/platform/hardware/libhardware/+/refs/tags/android-15.0.0_r20/modules/README.android
  This has no use with modern HIDL/AIDL/APEX HALs. For legacy HALs name can
  be implicitly set using system properties (e.g. 'ro.hardware.audio.primary'
  that's still relevant).
2025-03-18 16:37:46 +02:00
Konsta
f92559efc7 reorganize board config 2025-03-18 16:37:30 +02:00
Konsta
8ec47479b4 treble: remove deprecated vndk flag
* Deprecated in Android 15.
  https://source.android.com/docs/whatsnew/android-15-release#deprecate-vndk
  69f5dbb0d0
2025-03-18 16:37:12 +02:00
Konsta
93dbd7462f treble: remove unneeded flags
* PRODUCT_FULL_TREBLE gets set on PRODUCT_SHIPPING_API_LEVEL >= 26.
  There's no need to override it.
  2b32469c47
* BOARD_PROPERTY_OVERRIDES_SPLIT_ENABLED gets set with PRODUCT_FULL_TREBLE.
  c227ce7c25
2025-03-17 19:34:41 +02:00
Konsta
d6d1d6fe05 sepolicy: remove libglapi
* Fixes 6a128defbc.
2025-03-17 18:47:07 +02:00
Konsta
b57146cc25 Revert "overlay: disable screen dimming by default"
* In practice, doesn't disable dimming.

This reverts commit e934722c00.
2025-03-16 17:53:59 +02:00