Daniel Zheng
952e351dbb
Merge "should_flash_in_userspace signature change" into main am: ac758f2ccc am: 12c7d42a55
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2759691
Change-Id: Iaba69608f119dba4e841334da6b538f316d43698
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-27 01:18:22 +00:00
Daniel Zheng
12c7d42a55
Merge "should_flash_in_userspace signature change" into main am: ac758f2ccc
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2759691
Change-Id: I308999d3ef0a9a5b75c089f5357156203866a713
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-27 00:19:59 +00:00
Daniel Zheng
ac758f2ccc
Merge "should_flash_in_userspace signature change" into main
2023-09-26 23:55:25 +00:00
Daniel Zheng
7a8f82acbd
should_flash_in_userspace signature change
...
We should change should_flash_in_userspace to work without
$ANDROID_PRODUCT_OUT being set and fall back on $OUT directory when
source isn't specified
This also fixes the flashing issue of flashing retrofit devices without
$ANDROID_PRODUCT_OUT set. If we
call fastboot update on a retrofit device, copy_avb_footer will resize
buf->sz of secondary partitions to the partition size, causing us to
send the unsparsed payload to the device -> "Invalid Size" issue.
This is because secondary partitions are considered physical partitions
on retrofit devices && should_flash_in_userspace wouldn't work if
$ANDROID_PRODUCT_OUT is set, so our first return clause in
copy_avb_footer doesn't catch this edge case causing us to resize the
buf-> sz incorrectly.
Did some testing, and also observed a case where flashing is able to
succeed despite $ANDROID_PRODUCT_OUT not being set before, so there
might still be some other edge case that we are still missing.
Test: fastboot update on sargo without $ANDROID_PRODUCT_OUT
Change-Id: I0e4781d96709b712f7d71657ec0d16d99b90214d
2023-09-26 16:55:06 -07:00
Elliott Hughes
edb21216e2
Merge "Stop duplicating <linux/capabilities.h>." into main am: 8d983ee878 am: a441e2ef67
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2760169
Change-Id: Ib3fe0d6b3142583a50f7784cad7f865c04b682af
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-26 20:42:21 +00:00
Elliott Hughes
a441e2ef67
Merge "Stop duplicating <linux/capabilities.h>." into main am: 8d983ee878
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2760169
Change-Id: Ie51e9e5f2cd6d37928a37b0b1bb3870621ac51d3
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-26 19:14:58 +00:00
Elliott Hughes
8d983ee878
Merge "Stop duplicating <linux/capabilities.h>." into main
2023-09-26 17:59:53 +00:00
Elliott Hughes
94ccdc06d0
Stop duplicating <linux/capabilities.h>.
...
This doesn't help the person who wants CAP_BPF, but we can fix that
better by adding it to our stale glibc (and our future switch to musl
will mean we'll never have similar problems again).
I think this just dates from when we still supported building the OS on
darwin, but those days are long gone, and I think this hack can be put
to rest now...
Test: treehugger
Change-Id: I3c2e56c68a5b00c1ad0aed422c6ce60886063f50
2023-09-25 20:33:02 +00:00
Daniel Zheng
599b6b0f34
Merge "is_retrofit_device to work in bootloader" into main am: d774be9b05 am: d545b31663
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2759543
Change-Id: I8c4ffdc9cd0e78a379f1bfbd96ced25a0e2175c9
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-25 20:03:44 +00:00
Daniel Zheng
d545b31663
Merge "is_retrofit_device to work in bootloader" into main am: d774be9b05
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2759543
Change-Id: If431856a2ad838d2f7393c05600a24ddb610a0ba
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-25 19:04:30 +00:00
Daniel Zheng
d774be9b05
Merge "is_retrofit_device to work in bootloader" into main
2023-09-25 18:21:36 +00:00
Thiébaud Weksteen
604fa2a557
Merge "Skip /metadata/sepolicy creation" into main am: 911d309224 am: 9229827386
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2761545
Change-Id: I40ff772e8817ecb25bea9745422fcca19fb456aa
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-25 09:10:18 +00:00
Thiébaud Weksteen
9229827386
Merge "Skip /metadata/sepolicy creation" into main am: 911d309224
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2761545
Change-Id: I7acfa6f5cb28f051ca5fae7d641d216fe5254fcf
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-25 08:12:00 +00:00
Thiébaud Weksteen
911d309224
Merge "Skip /metadata/sepolicy creation" into main
2023-09-25 07:40:02 +00:00
Thiébaud Weksteen
a6b5f94687
Skip /metadata/sepolicy creation
...
Bug: 297794885
Test: presubmit
Change-Id: I93f94f319d0f86e1cad6f2a4912b5df3aae09cec
2023-09-25 16:07:47 +10:00
Treehugger Robot
66d0face55
Merge "Create_cow: Hash of target blocks should not be stored." into main am: a2cd2202f0 am: 8cd8ce3fc0
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2759698
Change-Id: Icd75426d986ce26ae39e684d49c951732e334bed
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-24 02:57:52 +00:00
Treehugger Robot
8cd8ce3fc0
Merge "Create_cow: Hash of target blocks should not be stored." into main am: a2cd2202f0
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2759698
Change-Id: Ib652154e55c271260cbf0070af9c96f674c31709
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-24 01:59:18 +00:00
Treehugger Robot
a2cd2202f0
Merge "Create_cow: Hash of target blocks should not be stored." into main
2023-09-24 00:46:55 +00:00
Treehugger Robot
fcdbce7f33
Merge "Do not check with vendor vndk version" into main am: 6d01651ab9 am: 9062abf0e5
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2758806
Change-Id: Ibee9120ac34b201daf0c2b793207477a3a3a9719
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-23 15:11:19 +00:00
Treehugger Robot
9062abf0e5
Merge "Do not check with vendor vndk version" into main am: 6d01651ab9
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2758806
Change-Id: I50e76816f0a8b1b679d83bc382b9b3c8bd1e2bc4
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-23 14:09:27 +00:00
Treehugger Robot
6d01651ab9
Merge "Do not check with vendor vndk version" into main
2023-09-23 13:06:15 +00:00
Kiyoung Kim
45d88d496e
Do not check with vendor vndk version
...
Current libcutils checks if memfd is supported with vendor VNDK version,
but this is no longer valid if VNDK is deprecated. As we can assume that
any vendor using this code is supported as long as it is treblelized,
simplify logic to check if memfd is valid to vendor only with
'ro.treble.enabled' property.
Bug: 290159430
Test: Cuttlefish with VNDK deprecated worked without error from
libcutils
Change-Id: I351f0798da99cb4827bc3e424b63a2eaee5c7461
2023-09-23 21:06:57 +09:00
Akilesh Kailash
810274071d
Create_cow: Hash of target blocks should not be stored.
...
Target block hash was in-correctly getting added to map thereby
overriding the source-hash.
Bug: 299011882
Test: Flash Pixel 6 Pro from A->B and from B->A
Change-Id: Ib3887c29cd6b8f2abd50e932273a5cfc2a096bd5
Signed-off-by: Akilesh Kailash <akailash@google.com>
2023-09-23 01:07:47 -07:00
Elliott Hughes
c1342bc826
Merge "Remove Windows workaround in file not built for Windows." into main am: d091aa44b3 am: 503121ccea
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2760267
Change-Id: I37fdad811e29e514bdc7aaaf68dd81314dcf28cc
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 23:37:35 +00:00
Treehugger Robot
fe743c5704
Merge "Only skip _16k/_64k kernel modules dirs on 4K builds" into main am: 73fcd754ee am: 6b38c7ed6f
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2758048
Change-Id: I9b5a34c3195617ebfb5a8ac48c6d5d1fad97ceea
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 23:36:48 +00:00
Elliott Hughes
503121ccea
Merge "Remove Windows workaround in file not built for Windows." into main am: d091aa44b3
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2760267
Change-Id: Id05b4a3222f5f17b2f55c9500a64f4763b59cd70
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 23:32:23 +00:00
Elliott Hughes
d091aa44b3
Merge "Remove Windows workaround in file not built for Windows." into main
2023-09-22 22:56:38 +00:00
Treehugger Robot
6b38c7ed6f
Merge "Only skip _16k/_64k kernel modules dirs on 4K builds" into main am: 73fcd754ee
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2758048
Change-Id: I00811eee37bd2009cae6d793e8bab44fbafd0a81
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 22:38:06 +00:00
Treehugger Robot
73fcd754ee
Merge "Only skip _16k/_64k kernel modules dirs on 4K builds" into main
2023-09-22 21:55:11 +00:00
Daniel Zheng
c3b91645ce
Merge "Removing extra includes" into main am: c4463ebee6 am: d1acda3833
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2759542
Change-Id: I391adf98d275f9004af660431456ea9ec3efc3bf
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 21:49:55 +00:00
Daniel Zheng
1ed9fa5522
Merge changes I343272f4,I5481893a into main am: 3d0d8e4b8f am: f9098ffba4
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2755691
Change-Id: If449ffa2afc453a79b1dc91d4f6dd8d56e98544a
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 21:49:47 +00:00
Ryan Prichard
96430be4a3
Merge changes I7790dde8,I065907a5,Id2e82024 into main am: 532a608f58 am: 4570cf0ce2
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2758070
Change-Id: Ia9ce264b48b8075d14876460bdfb18deb89212aa
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 21:48:50 +00:00
Daniel Zheng
d1acda3833
Merge "Removing extra includes" into main am: c4463ebee6
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2759542
Change-Id: I8c072e07b63995c28ed97b0db4801e1b4e15fa13
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 20:52:10 +00:00
Daniel Zheng
f9098ffba4
Merge changes I343272f4,I5481893a into main am: 3d0d8e4b8f
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2755691
Change-Id: I8be48fac668ba07a2caadedb55bcf2fd6e1fca28
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 20:51:55 +00:00
Ryan Prichard
4570cf0ce2
Merge changes I7790dde8,I065907a5,Id2e82024 into main am: 532a608f58
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2758070
Change-Id: I654dd3283ac4d072649d17afa6e091da35263be1
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 20:50:27 +00:00
Daniel Zheng
5cbcdfae4e
is_retrofit_device to work in bootloader
...
Changing is_retrofit_device() to work in bootloader. Previously flashall
flow was to boot into fastbootd and then make a call to get
"super-image-name", however this does not work in bootloader. Since all
tasks are generated ahead of time, this old check will now fail and we
will fail to add the correct delete tasks in collectTasks(). This change
does make it so that is_retrofit check only works during fastboot
flashall + fastboot update (since this function is only used here,
nothing is currently affected).
To determine if a device is retrofit, it must satisfy two conditions -> Has
dynamic partitions && does not contain a super partition. The check for
if source has super_empty.img is sufficient for determining if a device
has dynamic partitions and if any single partition has
LP_PARTITION_ATTR_SLOT_SUFFIXED it is determined to be retrofit
Test: logs from fastboot update on sargo device confirms this check
returns true. Fastboot update on sargo
Bug: 300287332
Change-Id: Iadf5c56de51993a79307c60e45d6cc4988436f23
2023-09-22 13:22:57 -07:00
Treehugger Robot
e2145d2fbb
Merge "Remove unused files." into main am: 59a2cde894 am: 1a262a11d4
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2759693
Change-Id: I846553ace3c28ec76772ce248e59752b6d87f7bc
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 20:01:59 +00:00
Treehugger Robot
ab62e7d3b0
Merge "Don't duplicate uapi ioprio constants." into main am: 46c366b0ed am: de1aeee88d
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2759694
Change-Id: I75c2bdd4423158ad9749212cf1fa35726ecd97c8
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 20:01:51 +00:00
Treehugger Robot
7a1d3efb41
Merge "Remove redefinition of uapi constant added in R." into main am: d5b09b4b97 am: c3bbf8237a
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2760268
Change-Id: Icc73bfcb93772b2cdb3c247ff02987f123f99aca
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 20:01:41 +00:00
Daniel Zheng
c4463ebee6
Merge "Removing extra includes" into main
2023-09-22 19:51:59 +00:00
Daniel Zheng
3d0d8e4b8f
Merge changes I343272f4,I5481893a into main
...
* changes:
Removing headers + using string
Removing double delete from flashall
2023-09-22 19:51:25 +00:00
Ryan Prichard
532a608f58
Merge changes I7790dde8,I065907a5,Id2e82024 into main
...
* changes:
Add missing <assert.h> include
Add missing <functional> and <vector> includes
snapuserd_test: don't discard result of std::async
2023-09-22 19:42:45 +00:00
Treehugger Robot
1a262a11d4
Merge "Remove unused files." into main am: 59a2cde894
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2759693
Change-Id: I010f21c81092ee51bce7c7c5fdca39acef377826
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 19:03:33 +00:00
Treehugger Robot
de1aeee88d
Merge "Don't duplicate uapi ioprio constants." into main am: 46c366b0ed
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2759694
Change-Id: I6bfe444c1ed43240506d9031796bd1cf03a97ef8
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 19:03:19 +00:00
Treehugger Robot
c3bbf8237a
Merge "Remove redefinition of uapi constant added in R." into main am: d5b09b4b97
...
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2760268
Change-Id: I7301abb110d029f8bda465fe0fd569924f52b766
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-09-22 19:02:32 +00:00
Treehugger Robot
59a2cde894
Merge "Remove unused files." into main
2023-09-22 18:01:48 +00:00
Treehugger Robot
46c366b0ed
Merge "Don't duplicate uapi ioprio constants." into main
2023-09-22 18:00:19 +00:00
Treehugger Robot
d5b09b4b97
Merge "Remove redefinition of uapi constant added in R." into main
2023-09-22 17:58:03 +00:00
Kelvin Zhang
b4987345ff
Only skip _16k/_64k kernel modules dirs on 4K builds
...
The initramfs.img from kernel builds do not store kernel modules under
_16k directory. Currently, init is programmed to only load kernel
modules from _16k dir if running on 16K page size kernel. Relax this
restriction so that booting on custom 16K kernel would work without
going through platform rebuild.
Test: th
Bug: 293313353
Bug: 300184677
Change-Id: I9ee3c74066ad9ec5127f1e8662f7c1273445994c
2023-09-22 09:14:43 -07:00
Elliott Hughes
f6a84e4462
Remove Windows workaround in file not built for Windows.
...
Test: treehugger
Change-Id: I311cfbc9245cbe90ed6fc4fa379ff5b9abdf21e7
2023-09-22 15:44:42 +00:00