Commit graph

90311 commits

Author SHA1 Message Date
Justin Yun
3a7cb4c637 Use __ANDROID_VENDOR_API__ for vendor API surface
Build system defines __ANDROID_VENDOR_API__ for non-system modules.
Use this flag to provide vendor API surface for vendor or product
variant modules.

Bug: 368559337
Test: atest AImageReaderWindowTest
Change-Id: I7da3d4ca9f92255a426af8d66b4391f3c1426759
2024-10-07 16:56:06 +09:00
Treehugger Robot
7cc50a8c29 Merge "init/epoll: clean up reorder-init-list warning" into main 2024-10-04 17:33:25 +00:00
Treehugger Robot
f348909323 Merge "Revert "init: Wait for /dev/hvc1 during ARCVM first-stage mount"" into main 2024-10-04 17:28:04 +00:00
Neill Kapron
551c6018c8 init/epoll: clean up reorder-init-list warning
This change cleans up the following build warning:

warning: ISO C++ requires field designators to be specified in
declaration order; field 'events' will be initialized after field
'handler' [-Wreorder-init-list]

Bug: none
Test: TH
Change-Id: I9fe566b452438dc9f00f782fc4435905227a60c9
Signed-off-by: Neill Kapron <nkapron@google.com>
2024-10-04 15:57:35 +00:00
Konrad Adamczyk
8278575b91 Merge "Revert "init: Look for super partition only on a boot device"" into main 2024-10-04 06:24:26 +00:00
Jusik Chung
8d71220df2 Revert "init: Look for super partition only on a boot device"
This reverts commit 6f0ebcb526.

Reason for revert: b/371393845 boot up failure of gcar emulator

Change-Id: I15e5bea609938cf5a1e347666b9a2abb287cb086
2024-10-04 02:21:37 +00:00
Tiffany Yang
36ea62f1fd Revert "init: Wait for /dev/hvc1 during ARCVM first-stage mount"
This reverts commit b885e4ad53.

Reason for revert: No longer needed (using virtio-blk instead)

Change-Id: I667f0d4f58060e781a5e9b21c778cd568b92971a
2024-10-03 23:52:54 +00:00
Treehugger Robot
8dd9d45534 Merge "Change owner of ACPI BERT tables to system" into main 2024-10-03 14:54:40 +00:00
Rob Barnes
da77c2e1dc Change owner of ACPI BERT tables to system
Changes the owner of the following files to system:system:

* /sys/firmware/acpi/tables
* /sys/firmware/acpi/tables/BERT
* /sys/firmware/acpi/tables/data/BERT

This allows the bert_collector deamon to read these files for error reporting.

Bug: 357626966
Test: m && atest bert_collector_test

Change-Id: Iba3a169f1851566ee6fed6d41b538dae448bf811
2024-10-03 13:54:52 +00:00
Konrad Adamczyk
bd71df6e3a Merge "init: Look for super partition only on a boot device" into main 2024-10-03 09:04:53 +00:00
Daniel Zheng
4174d07b7f Merge "libsnapshot: configure num worker threads" into main 2024-10-02 19:59:02 +00:00
Treehugger Robot
1bf57e1d71 Merge "libprocessgroup: Remove schedtune support" into main 2024-10-02 17:26:11 +00:00
Daniel Zheng
a23013dd4b libsnapshot: configure num worker threads
Forward number of worker threads build configuration to snapuserd. these
are the threads that will be used to serve i/o requests to dm-user.

Bug: 361438985
Test: OTA with print logs post OTA reboot
Change-Id: Ib70a3cb8766b96232ea6f97effece041534dc922
2024-10-02 09:56:06 -07:00
T.J. Mercier
981664df08 libprocessgroup: Remove schedtune support
Schedtune was an out of tree cgroup controller present in Android
kernels up to 4.19. It was replaced with uclamp and the cpu controller.
Now that 4.19 is EOL and unsupported, and schedtune is not present in
any supported Android kernels, remove the userspace support for
schedtune.

Bug: 362504801
Change-Id: If8baaf1a616984c5dbaac1bbd03e23ad001bc29c
2024-10-02 14:47:45 +00:00
Treehugger Robot
aa56f29ff9 Merge "Replace ANDROID_VENDOR with ANDROID_VNDK in versioning" into main 2024-10-01 05:38:46 +00:00
Hans Boehm
47ec15c928 Merge "Remove unnecessary getpriority() system call" into main 2024-09-30 18:21:39 +00:00
Sandeep Dhavale
dcb13446f2 Merge "libsnapshot: Use words for xor ops" into main 2024-09-30 16:26:50 +00:00
Sandeep Dhavale
0d84909d66 libsnapshot: Use words for xor ops
Use words instead of doing xor byte-by-byte for the entire buffer.
Profiling this with unittest, I can see the xor ops is much faster.

Also handle the word size appropriately for 32bit and 64bit platforms.

simpleperf shows that ProcessXorOp() is atleast 30% faster.
Similar improvement is seen for ProcessXorData().

Test: snapuserd_test
Bug: 369905394
Change-Id: I0bd8586f7fc1bf184f19320667b8195b07f9cdf2
Signed-off-by: Sandeep Dhavale <dhavale@google.com>
2024-09-27 14:55:06 -07:00
Jan Dabros
6f0ebcb526 init: Look for super partition only on a boot device
Init code is bailing out as soon as `super` partition was
found in the system, ignoring rest of uevents.

In case given device contains multiple boot sources, `super`
partition as well as all other partitions shall be taken
from the same boot source, instead of relying on
`which uevent came first`.

Bug: 309244873, 349144493
Test: Plug secondary USB boot device to device that supports multiple
      boot sources. Select boot from USB. Device boots properly.

Signed-off-by: Jan Dabros <dabros@google.com>
Signed-off-by: Konrad Adamczyk <konrada@google.com>

Change-Id: I70eb7d4223258ec273faa523cb67ddab0b7c32a0
2024-09-27 06:43:00 +00:00
Vova Sharaienko
778ad88da6 Merge "Added ownership attribution for test targets" into main 2024-09-26 22:18:57 +00:00
Vova Sharaienko
892ef23a9e Merge "Add host support to libexpresslog" into main 2024-09-26 22:18:57 +00:00
Vova Sharaienko
78d5f7c6f5 Added ownership attribution for test targets
Flag: NONE Docs
Bug: n/a
Test: build
Ignore-AOSP-First: will cp to aosp after
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:8a32d828847a989523ebee8d21d084cf1d55a605)
Merged-In: I6ca6e48ea1ec704216833c2c04177b0022e7b659
Change-Id: I6ca6e48ea1ec704216833c2c04177b0022e7b659
2024-09-26 21:12:01 +00:00
Vova Sharaienko
717b4a7187 Add host support to libexpresslog
- change to a set of build artifacts

Flag: EXEMPT Refactor

Ignore-AOSP-First: will cp to aosp after
Bug: n/a
Test: build
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:1396f9d3bb43ea44aa6b0a67fe44570828f9f668)
Merged-In: I8b565a9237319da0b24fed2c802f0e03a15bcd57
Change-Id: I8b565a9237319da0b24fed2c802f0e03a15bcd57
2024-09-26 21:11:51 +00:00
Hans Boehm
1ec5290872 Remove unnecessary getpriority() system call
This was introduced for a valid reason in aosp/1224543, but that reason
was later removed. This code wasn't.

It is not worth making a system call in order to possibly avoid a second
one, which I expect is no more expensive in that, particularly easy,
case.

Test: Treehugger
Change-Id: I346f9b641c6feb791247b16fb900a4ad97e646d2
2024-09-26 12:59:37 -07:00
Treehugger Robot
0de42845ad Merge "Remove OEM_UNLOCK_PROP usage" into main 2024-09-26 15:34:05 +00:00
Treehugger Robot
038b6269b0 Merge "Use std::sync::LazyLock rather than once_cell." into main 2024-09-26 11:10:04 +00:00
Treehugger Robot
eedb53cb0c Merge "trusty: utils: trusty-ut-ctrl: fix the vendor target" into main 2024-09-25 08:34:56 +00:00
Treehugger Robot
2d78a263bd Merge "trusty: support secure storage in system-ext" into main 2024-09-25 07:54:22 +00:00
Armelle Laine
3d90ed0cea trusty: utils: trusty-ut-ctrl: fix the vendor target
Bug: 369492636
Test: trusty-ut-ctl -D <trusty device> <port-name>

Change-Id: I9d8a298941caa4e3c5a424269577580be0ba79c8
2024-09-25 07:00:51 +00:00
Armelle Laine
69f3da832f trusty: support secure storage in system-ext
Bug: 355194622
Test: CF gets booted with KeyMint TA in VM
Change-Id: I3708ac572068162ca57c0e9b287296cea73215a7
2024-09-25 06:46:54 +00:00
Priyanka Advani (xWF)
1350207265 Merge "Revert "Support vendor partition in non-debuggable pVMs"" into main 2024-09-24 21:21:38 +00:00
Pechetty Sravani (xWF)
16f94816db Revert "Support vendor partition in non-debuggable pVMs"
Revert submission 3236797-b/340506965

Reason for revert: DroidMonitor created revert due to b/366178299.

Reverted changes: /q/submissionid:3236797-b/340506965

Tracking bug: b/369390218

Change-Id: I0ec7fe89a7a0ca3a9981cd80222d03a785e9b28f
2024-09-24 18:31:49 +00:00
Treehugger Robot
bb8dbd6b07 Merge "Update struct to include far and elr on the NS side" into main 2024-09-24 10:09:53 +00:00
Alice Wang
179d341569 Merge "trusty: utils: trusty-ut-ctrl: add to system_ext" into main 2024-09-24 06:45:08 +00:00
Treehugger Robot
b9e63943de Merge "Fix the trigger name for loading bpf programs." into main 2024-09-24 01:49:11 +00:00
Treehugger Robot
02ae1e127d Merge "trusty: storage: proxy: FS_READY property setting on vendor only" into main 2024-09-24 00:43:54 +00:00
Armelle Laine
d26f39ab0e trusty: storage: proxy: FS_READY property setting on vendor only
Bug: 367965796
Test: launch_cvd --noresume --console=true \
      --extra_kernel_cmdline='androidboot.selinux=permissive' \
      --secure_hals=guest_keymint_trusty_insecure
Change-Id: I4d5ea1762f7cf9edfd8cbc00e2aec13caae965f4
2024-09-23 23:38:14 +00:00
Armelle Laine
4f0e3eb6f2 trusty: utils: trusty-ut-ctrl: add to system_ext
Bug: 367423387
Test: atest VtsHalSecureStorageTargetTest

Change-Id: I70a8a9108c7399f99bfdf26b00c5fbd1fcb039c6
2024-09-23 23:37:09 +00:00
Maciej Żenczykowski
b4b3950e52 Fix the trigger name for loading bpf programs.
The trigger name should be load-bpf-programs, not load_bpf_programs.

Test: TreeHugger
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I00cff0a3dd971de39dfc3226b140be972854ea28
2024-09-23 21:34:33 +00:00
Maciej Żenczykowski
3e8f0b53e4 Merge "start netd earlier" into main 2024-09-23 21:16:05 +00:00
Maciej Żenczykowski
e60b760e74 start netd earlier
In this change we're moving the asynchronous netd startup ahead of
the async statd and *synchronous* update_verifier.

This is desirable as we want a netd failure (which could
happen due to some mainline incompatibility wrt. bpf
or mainline shipped shared libs: resolver or netd updatable)
to be considered a signal for a bad boot.

It's still asynchronous though, so it's not ideal.

Test: TreeHugger
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: Ib3e252f085f569864feddaf20ac80858a3bb969d
2024-09-23 21:15:01 +00:00
Pawan Wagh
a3b9e560bd Replace ANDROID_VENDOR with ANDROID_VNDK in versioning
API_LEVEL_AT_LEAST Check doesn't work on product modules

Bug: 368559337
Test: Boot device
Change-Id: I8b37b39caa642afc4d8c2b7adf6eed0b08efb40c
2024-09-23 20:32:48 +00:00
Treehugger Robot
23903e1655 Merge "Support vendor partition in non-debuggable pVMs" into main 2024-09-23 20:27:15 +00:00
Treehugger Robot
9d0b877619 Merge "Move the dist target of mke2fs to build/core/tasks" into main 2024-09-23 02:35:53 +00:00
Han Wang
47718268d4 Remove OEM_UNLOCK_PROP usage
* It was only used for adb host scripts, but after commit
   "Remove sys.oem_unlock_allowed check for Android device"
   in 2016, there is no usage for it. Remove it because this prop
   is now exposed to untrusted apps, which is not desirable.

Change-Id: Ic1c2f4e06b3a07ecf3f724fe5085974c626cb3fc
2024-09-22 03:51:29 +00:00
Andrew Walbran
34083b7151 Use std::sync::LazyLock rather than once_cell.
This was recently stabilised in Rust 1.80.

Test: Treehugger
Change-Id: I33a16bb1ad6c868c5d32ab72d08ce4e7f910300f
2024-09-20 15:27:46 +01:00
Inseob Kim
65daca3b88 Merge "Mount /mnt/vm earlier" into main 2024-09-20 08:01:56 +00:00
Treehugger Robot
d53b098097 Merge "Replace base::RandInt with std::uniform_int_distribution" into main 2024-09-20 05:36:34 +00:00
Shengsong Tan
ad5948a810 Replace base::RandInt with std::uniform_int_distribution
As part of the effort to uprev libchrome in Android, we are
removing Android dependencies to libchrome utility functions
that are not strictly required.
This CL remove the usage of base::RandInt and replace by std cpp

Bug: 360917504
Change-Id: I83ea0f00ca07074f8c6c9a69db343a65cc8deb27
Test: atest libfs_avb_internal_test
2024-09-20 04:49:35 +00:00
Treehugger Robot
8da4af89fd Merge "trusty: keymint: rename trusty_ipc_dev property" into main 2024-09-19 19:45:51 +00:00