Commit graph

80858 commits

Author SHA1 Message Date
Treehugger Robot
f58219c0f1 Merge "Accept SEGV_MTESERR in CrasherTest.mte_async test." am: b3bf57dbe9
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2476664

Change-Id: I550d6a570b3b72a7348595d72ae0408a3c97ea0c
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-09 01:04:34 +00:00
Treehugger Robot
b3bf57dbe9 Merge "Accept SEGV_MTESERR in CrasherTest.mte_async test." 2023-03-09 00:34:39 +00:00
Daniel Zheng
43987c948b Fixed parameter styling and minor error in tasks
Test: tested compilation
Change-Id: Ieb949243da1284dec3bad2caa895a59465858adc
2023-03-08 23:07:51 +00:00
Daniel Zheng
aa70f4c748 Added support for Delete Task
Test: tested delete-logical-partition {partition} and flashall on Raven

Change-Id: I04f07c8132159deda42434b9178e8c98d5ab768b
Bug: 194686221
2023-03-08 23:07:51 +00:00
Daniel Zheng
9f7bf7eff3 Added support for Resize Task
Test: tested flashall on raven
Bug: 194686221
Change-Id: I60586756b2d5f99848a664def8204c0bd47d7e67
2023-03-08 23:07:50 +00:00
Daniel Zheng
6bb8baa929 Added support for Update Super Task
Test: tested flashall on raven
Bug: 194686221
Change-Id: Ifc99af77f9235bf56a549f53e7d43575686fb42b
2023-03-08 23:07:50 +00:00
Daniel Zheng
47d70a5559 Added support for FlashSuperLayoutTask
Test: testing flashall code with this change
Bug: 194686221
Change-Id: Ibb96980402db51b48c9a296338f29195f68c65bf
2023-03-08 23:07:48 +00:00
Eric Biggers
cc4ebd8442 Merge "Avoid odd behavior when clearing nonexistent SID" am: 9089ec6b0b
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2470860

Change-Id: I760afb05eb7a0b802d4dc053371ebdfe18e3c723
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-08 20:56:22 +00:00
Eric Biggers
9089ec6b0b Merge "Avoid odd behavior when clearing nonexistent SID" 2023-03-08 20:16:10 +00:00
David Drysdale
645a0d8e3d Add more Gatekeeper OWNERS
Test: none
Change-Id: Id27ab0fec14e9290820eabff5a5f0ccb3d8eada4
2023-03-08 16:47:13 +00:00
Zijun Zhao
0e161700aa Merge "Suppress the error warning" am: e851f2d617
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2468620

Change-Id: I5c3921ff63cec915ffb81e4b66ed24cc1a8b6117
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-08 05:44:59 +00:00
Peter Collingbourne
91e816aa0e Accept SEGV_MTESERR in CrasherTest.mte_async test.
This is possible when upgrading to sync mode.

Change-Id: I71c213cb9ddda87765a0dc2ff5455f0eb7b484fe
2023-03-07 21:27:09 -08:00
Zijun Zhao
e851f2d617 Merge "Suppress the error warning" 2023-03-08 05:16:57 +00:00
zijunzhao
f5e1533f2f Suppress the error warning
Bug: https://android-build.googleplex.com/builds/pending/P51300433/aosp_bramble-userdebug/latest/view/logs/build_error.log
Test: None
Change-Id: I2fbd3d8772c50ed9de1c2ba9eb2234966c7dcb84
2023-03-08 02:40:09 +00:00
Treehugger Robot
5003beff7e Merge "libsnapshot: Fix test failures on certain configurations." am: 57feb3fbbd
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2473164

Change-Id: Iad2e452f08bea3384e26e68a7381b79362d97ec9
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-07 18:34:51 +00:00
Treehugger Robot
57feb3fbbd Merge "libsnapshot: Fix test failures on certain configurations." 2023-03-07 18:02:14 +00:00
David Anderson
4c17a07053 libsnapshot: Fix test failures on certain configurations.
Due to how CF is built and tested, VABC is enabled even when not
supported by the kernel. To work around this add some logic in
libsnapshot and the test harness to recognize this situation and
silently flip off the VABC flag.

This also fixes the -force_mode option to vts_libsnapshot_test, so that
it will skip tests that aren't supported by the device.

Bug: 264279496
Test: vts_libsnapshot_test on 11-5.4 with vabc enabled
Change-Id: I4c1e88fac54732c21c88169a7e0dd664e3858b89
2023-03-06 23:21:25 +00:00
Bart Van Assche
b61674ee02 Merge "init: Combine the CheckShutdown() and set_do_shutdown() methods" am: 42908c45e5
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2444306

Change-Id: I387ff39f41579a1c61ba8f51d067652262313950
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-06 18:35:29 +00:00
Bart Van Assche
42908c45e5 Merge "init: Combine the CheckShutdown() and set_do_shutdown() methods" 2023-03-06 18:09:09 +00:00
Treehugger Robot
f00d7fd062 Merge changes Ia150604c,Id4b9565f am: b28e508220
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2470042

Change-Id: Idbfec04ef1f6597c1951e3b8c09186cb39658e61
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-06 15:53:16 +00:00
Treehugger Robot
b28e508220 Merge changes Ia150604c,Id4b9565f
* changes:
  init: Remove the DebugRebootLogging() function
  init: Combine two if-statements
2023-03-06 15:20:25 +00:00
Dmitrii Merkurev
6e7bebf99b Merge "fastboot: Introduce ParseNetworkSerial unit tests" am: 48b39ba01e
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2465172

Change-Id: I996144d25e9293a0a3c5d6de2750ef23ae002712
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-04 01:01:19 +00:00
Eric Biggers
b4738b9e5d Avoid odd behavior when clearing nonexistent SID
It's expected that clearSecureUserId is sometimes called with a userId
that doesn't currently have a Gatekeeper enrollment.  For example, this
happens whenever a user with no LSKF is removed.  gatekeeperd currently
has two odd behaviors when it's asked to do this.  First, it logs the
following message at ERROR level, which is not appropriate:

    E gatekeeperd: clear_sid: could not remove file [No such file or directory], attempting 0 write

Second, it writes 0 to the file /data/misc/gatekeeper/$userId.  This
makes this file exist even after the user has been removed, which
doesn't cause a real problem but is unexpected.

Fix both of these issues by making clear_sid() check for ENOENT.

Bug: 188702845
Bug: 268526331
Change-Id: Ib1b110f2502267004f5c945c28c98ae926b2a794
2023-03-03 23:18:15 +00:00
Bart Van Assche
071dbc1729 init: Combine the CheckShutdown() and set_do_shutdown() methods
Let the CheckShutdown() method clear the do_shutdown_ member instead of
clearing that member separately from calling CheckShutdown().

Bug: 266255006
Change-Id: Ifc1cff2be92a45db7f91be2fdb812930d2fd1ad5
Signed-off-by: Bart Van Assche <bvanassche@google.com>
2023-03-03 13:27:17 -08:00
Bart Van Assche
b4b1b75a35 init: Remove the DebugRebootLogging() function
The DebugRebootLogging() function was introduced to help with
root-causing b/150863651. Remove this function since this logging
functionality is no longer needed. Also remove the functions and methods
that are only used by DebugRebootLogging().

Change-Id: Ia150604c6cd70f42b13d655ba43b95445a55b6e2
Signed-off-by: Bart Van Assche <bvanassche@google.com>
2023-03-03 13:26:58 -08:00
Bart Van Assche
1fdbf8d0f8 init: Combine two if-statements
Combine two if-statements. This change is fine because:
* The code between the two if-statements does not queue actions.
* If an action is queued from another thread then WakeMainInitThread()
  is called after the action has been queued.

Bug: 266255006
Change-Id: Id4b9565ff4fdb3ee2a2bbca316c8c78e0f2d38dd
Signed-off-by: Bart Van Assche <bvanassche@google.com>
2023-03-03 13:26:58 -08:00
Dmitrii Merkurev
48b39ba01e Merge "fastboot: Introduce ParseNetworkSerial unit tests" 2023-03-03 18:52:33 +00:00
Daniel Zheng
d024960a3f Merge "Changed FlashTask and RebootTask to take in FlashingPlan" am: 78a0f7f1b2
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2452605

Change-Id: Ia994195298ac8beac5d91c6579ad2ea96c1c6ed2
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-03 17:56:09 +00:00
Daniel Zheng
91b886fee4 Merge "Added Flashing Plan" am: f8da682c84
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2448346

Change-Id: I3cc5eb9e575f443a6485ababbe2f3aa86fc5be44
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-03 17:46:01 +00:00
Inseob Kim
12f447e607 Merge "libprocessgroup: fix boot time performance regression" am: e89ee18b9b
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2467504

Change-Id: Iddcb0c1771b1a247732974dc6c360ce3509e8ee8
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-03 17:19:17 +00:00
Daniel Zheng
78a0f7f1b2 Merge "Changed FlashTask and RebootTask to take in FlashingPlan" 2023-03-03 07:43:03 +00:00
Daniel Zheng
f8da682c84 Merge "Added Flashing Plan" 2023-03-03 07:42:55 +00:00
Daniel Zheng
bc01da5c0d Changed FlashTask and RebootTask to take in FlashingPlan
Test: tested flash {partition} on raven and reboot {target} on raven
Change-Id: I26f4723474c3a142b086c1ac361578f8487ec3b9
Bug: 194686221
2023-03-03 06:49:34 +00:00
Daniel Zheng
7df2ab9c87 Added Flashing Plan
Fastboot has a lot of flags that are used by many different functions
including the Flashall Class and newly added FlashSuperTask. Passing all
of these flags as paramaters is cumbersome, so adding a Flashing Plan
that contains these flags simplifies the code.

Test: tested Flashall and update img.zip on raven
Change-Id: I9c842f25389a20b852d55f684e1b86040af1d86a
Bug: 194686221
2023-03-03 06:49:32 +00:00
Inseob Kim
e89ee18b9b Merge "libprocessgroup: fix boot time performance regression" 2023-03-03 05:02:29 +00:00
Suren Baghdasaryan
4f7cc8c345 libprocessgroup: fix boot time performance regression
The way processes are accounted in DoKillProcessGroupOnce has been
changed recently, which affects retries in KillProcessGroup. More specifically, initialPid was not counted before and would not
cause a retry with 5ms sleep.
Restore previous behavior to avoid boot time regressions.

Bug: 271198843
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: Ibc1bdd855898688a4a03806671e6ac31570aedf9
2023-03-03 00:11:13 +00:00
Treehugger Robot
55ba50e20f Merge "Use ro.boot.serialconsole to disable console services" am: 8dab2ef586
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2451765

Change-Id: I7885352f27b5a64cf36151c919996d73d65414e4
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-02 20:29:11 +00:00
Treehugger Robot
8dab2ef586 Merge "Use ro.boot.serialconsole to disable console services" 2023-03-02 20:04:33 +00:00
Treehugger Robot
1e9592f022 Merge "Fix the missing std" am: bb4c61aa34
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2465171

Change-Id: I699fec00c6ab0057b39d0f0582b9ae6eb3574154
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-02 01:59:01 +00:00
Treehugger Robot
bb4c61aa34 Merge "Fix the missing std" 2023-03-02 01:50:18 +00:00
Elliott Hughes
8e58ce6824 Merge "Update shell_and_utilities docs for U." am: 799550dd1f
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2464831

Change-Id: I7c2ac6e2a4a82d86e3aebe01096a564530bcdae3
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-02 01:21:56 +00:00
Krzysztof Kosiński
0cc793ef16 Merge "Fix invalid uses of PLOG." am: 0f90ba64bd
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2462673

Change-Id: Ie0177ea1595e0509ade79074d0928e3cce5c9470
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-02 01:21:45 +00:00
Elliott Hughes
799550dd1f Merge "Update shell_and_utilities docs for U." 2023-03-02 01:05:07 +00:00
Krzysztof Kosiński
0f90ba64bd Merge "Fix invalid uses of PLOG." 2023-03-02 00:52:20 +00:00
Dmitrii Merkurev
cdbfa7a3e8 fastboot: Introduce ParseNetworkSerial unit tests
Introduced positive and negative unit tests to cover
ParseNetworkSerial logic. Alongside with that move
result related stuff to the separate header.

Test: atest fastboot_test
Test: manually checked basic functionality works fine
Bug: 271155012
Change-Id: Icac6053c11b5a36daa64555209555826ea28cc61
Signed-off-by: Dmitrii Merkurev <dimorinny@google.com>
2023-03-02 00:03:49 +00:00
zijunzhao
6634c1741e Fix the missing std
Bug: b/239662094
Test: enable Wunqualified-std-cast-call locally and run m to build
Change-Id: I203af8dbbbf1d889b9fc5efd5b62fa165ee09dc2
2023-03-01 23:30:29 +00:00
Elliott Hughes
f603989156 Update shell_and_utilities docs for U.
Also add a few relevant links for anyone wanting more background.

Test: N/A
Change-Id: I31c98313f2237c93b89e7a5db44952f394604a1b
2023-03-01 22:05:37 +00:00
Treehugger Robot
c5d45ccbb0 Merge "fastboot: Fix fastboot_vendor_boot_img_utils_test mac os compilation" am: 18b6e9b819
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2463156

Change-Id: Iaf240e3f1fa981a1d49021a458cc7c0f64902a5a
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-01 17:44:55 +00:00
Treehugger Robot
18b6e9b819 Merge "fastboot: Fix fastboot_vendor_boot_img_utils_test mac os compilation" 2023-03-01 17:03:44 +00:00
Dmitrii Merkurev
95c90c6588 fastboot: Fix fastboot_vendor_boot_img_utils_test mac os compilation
Use more universal lseek instead of lseek64

Test: atest fastboot_vendor_boot_img_utils_test
Test: mm on mac os
Bug: 271152365
Change-Id: I4d094dd2c24e4ffec8ea7fe2f3b355122fd8cd19
Signed-off-by: Dmitrii Merkurev <dimorinny@google.com>
2023-03-01 15:49:56 +00:00