Commit graph

84775 commits

Author SHA1 Message Date
Kalesh Singh
5a2b8794fc trusty: tipc_fuzzer: Remove use of PAGE_SIZE
tipc_fuzzer writes random data of length 'size' and then
attempts to read back data up to 'TIPC_MAX_MSG_SIZE' in length.

Since 'size' is unrestricted we can always write more than the
subsequent read; and in effect the fuzzer only checks that we
can read something.

Remove the read buffer's dependency on PAGE_SIZE.

Bug: 294914413
Test: mma
Change-Id: I909b49fda4e6ebf49f69b3c09ac29ff8629215ef
Signed-off-by: Kalesh Singh <kaleshsingh@google.com>
2023-10-12 20:02:34 +00:00
Yi-Yo Chiang
c519d1dde2 Merge "Revert "init_first_stage: Disable ThinLTO"" into main 2023-10-12 10:33:54 +00:00
Treehugger Robot
f7d982ec7f Merge "Skip android14-tests-dev" into main 2023-10-12 06:06:07 +00:00
Raymond Hernandez
786aabd706 Add monicamwang and rayhdez to system/core/libstats/OWNERS
Test: m -j
Bug: N/A
Change-Id: Ifb866dc90818423260c8ff4337edaa2e622d9d56
2023-10-11 17:52:25 -07:00
Steven Moreland
cd9556cb96 Merge "libutils: use log/log.h internally" into main 2023-10-11 22:02:18 +00:00
Kelvin Zhang
d6fe3032a9 Merge "Revert "Shove type into source_info"" into main 2023-10-11 20:50:02 +00:00
Kelvin Zhang
b6153adde1 Revert "Shove type into source_info"
This reverts commit e90a39aee2.

Reason for revert: 304602386

Change-Id: Ib9d31bdadc7511e67f4c7e5731d18e7bf0162bfc
2023-10-11 19:44:38 +00:00
Nolen Johnson
cb33fb4008 fs_mgr: Don't run clean_scratch_files on non-dynamic devices
* This results in a metric ton of denials on some devices and
  eats up valuable resources on boot, plus there's 0 need for it,
  so kill it.

Change-Id: Ic52d5b3f06724430e9505345024cf0041b37ca49
2023-10-11 13:58:40 -04:00
Edward Liaw
da3caeab43 Merge "liblp_test: Add to kernel-presubmit" into main 2023-10-11 16:53:26 +00:00
Edward Liaw
f5736cb42a Merge "libdm_test: Add to kernel-presubmit" into main 2023-10-11 16:53:10 +00:00
Yi-Yo Chiang
1a3dd7eb4b Revert "init_first_stage: Disable ThinLTO"
This reverts commit 4d6fa8ccaf.

Reason for revert: b/295944813 is fixed

Bug: 304290959
Change-Id: I2d6f5216800d6ee26b25623898836dc216c8be18
Test: adb-remount-test.sh
2023-10-11 02:06:26 +00:00
Harry Pan
06949876be Merge "Add new fastbootd battery-soc variable" into main 2023-10-11 00:28:28 +00:00
Xin Li
8f3b94818a Skip android14-tests-dev
Bug: 263910020
Merged-In: Iedb7c32a594c3b1fca2904f3441029aaed7edf2a
Change-Id: Ied477b08d7d23de298ace72ae7ee69dda7c0671b
2023-10-10 16:18:22 -07:00
Edward Liaw
eafffc0c9c liblp_test: Add to kernel-presubmit
Bug: 284307085
Test: atest :kernel-presubmit
Change-Id: I2a138cf55a2af07b5c231f163196266f8b3dd524
Signed-off-by: Edward Liaw <edliaw@google.com>
2023-10-10 23:13:30 +00:00
Edward Liaw
942a31e7be libdm_test: Add to kernel-presubmit
Bug: 284307085
Test: atest :kernel-presubmit
Change-Id: I13ae25f17c943825bdf5ee67c00b7d297cf6e319
Signed-off-by: Edward Liaw <edliaw@google.com>
2023-10-10 23:05:09 +00:00
Daniel Zheng
dd3d34ffa7 Merge changes Ibe310d58,If88dceda into main
* changes:
  Move Cow Header child writer
  Add v3 Cow Header
2023-10-10 22:50:11 +00:00
Treehugger Robot
c2671853ae Merge "rpc_binder: Change trusty_tipc_fuzzer to support multiple connections and messages" into main 2023-10-10 22:13:42 +00:00
Daniel Zheng
bb45742ba1 Move Cow Header child writer
v2 writer and v3 writer will write different versions of the header.
It's better to have each writer hold it's own header.

Test: th
Change-Id: Ibe310d58b830950ad556aabcd0c1009483fc8d86
2023-10-10 15:06:26 -07:00
Daniel Zheng
ed1a7d5faf Add v3 Cow Header
Adding Version 3 of CowHeader. This will inherit from original
CowHeader and add a compression field. We are no longer supporting
different compressions per operation so having this one field is enough.

Test: cow_api_test
Change-Id: If88dceda139807cc5e647b706ddeb2b3e83c024f
2023-10-10 15:06:26 -07:00
Daniel Zheng
b3cd361bfd Merge "Rename BLOCK_SZ to block_size" into main 2023-10-10 21:56:16 +00:00
Daniel Zheng
f5f0a10541 Merge "Move ReadCowHeader to CowReader" into main 2023-10-10 21:56:11 +00:00
Daniel Zheng
a3646037c2 Merge "Shove type into source_info" into main 2023-10-10 21:11:33 +00:00
Daniel Zheng
73b3428e1c Rename BLOCK_SZ to block_size
BLOCK_SZ name to block_size as we should reserve all caps for compile
time constants

Test: th
Change-Id: I542632662e81b272ffec50d6b50c290d701b08e3
2023-10-10 12:55:28 -07:00
Daniel Zheng
e90a39aee2 Shove type into source_info
We can shove type into source info to save 8 bits in per cow operation.
We only need 4 bits inside of source_info to enumerate all the types of
Cow Operation:

static constexpr uint8_t kCowCopyOp = 1;
static constexpr uint8_t kCowReplaceOp = 2;
static constexpr uint8_t kCowZeroOp = 3;
static constexpr uint8_t kCowLabelOp = 4;
static constexpr uint8_t kCowClusterOp = 5;
static constexpr uint8_t kCowXorOp = 6;
static constexpr uint8_t kCowSequenceOp = 7;
static constexpr uint8_t kCowFooterOp = -1;

Test: critical ota paths on pixel
Change-Id: I22049db0b39a55bd8f863339f3751d3146d5c1e9
2023-10-10 12:55:27 -07:00
Daniel Zheng
76b1e83fad Move ReadCowHeader to CowReader
Moving this function to cow reader first we have to read the version of
cow from the header before deciding which parser to use. This is a more
logical place for this code to be in

Test: th
Change-Id: Ie5ba53439b4fc3c4c409426b818a2d53c0cbc3e5
2023-10-10 12:55:27 -07:00
Daniel Zheng
a065e8739e Merge "Update API usage for source" into main 2023-10-10 19:29:10 +00:00
Daniel Zheng
2d5ec079be Merge "Move Sync to base class" into main 2023-10-10 03:17:38 +00:00
Daniel Zheng
c197df70d8 Update API usage for source
replacing any instance of op->source_info with GetCowSourceinfoData as
that's what we're really looking for. This function will return the 48
bits associated with the source and not the extra bits that will store
type + other information. We should never be making a reference to
op->source_info directly as that has no real meaning, we should be
masking for the data that we really need

Test: cow_api_test
Change-Id: I259c790efdd13c61a4599e9edfc75cf0ba000c61
2023-10-09 20:15:34 -07:00
Daniel Zheng
f9f833066d Move Sync to base class
This function will be called in header write for both v3 and v2 writer.
Seems okay to move to base class as theres no unique functionality to
the v2 writer.

Test: cow_api_test

Change-Id: I70c1b08ce67127c9dcbd0f54b574d2cd5ad1d0b5
2023-10-09 20:15:34 -07:00
Daniel Zheng
f7f3b62f24 Merge "Removing compression bit from v3 op" into main 2023-10-10 03:09:58 +00:00
Daniel Zheng
3062a64f06 Merge "Add v3 writer" into main 2023-10-10 02:25:38 +00:00
Treehugger Robot
1258dabac7 Merge "init: Remove arbitrary delay in async persist writes." into main 2023-10-10 00:32:04 +00:00
Steven Moreland
7a1ca59839 libutils: split out libutils_binder
Dependencies of libbinder, so we can build
a core libbinder library, libbinder_sdk.

This is preparing the way to move this part of libbinder
together with binder code into a single project.

Bug: 302720583
Change-Id: Icff078ac6e36c7f2b91cf815d5b9ed19b2e706e1
2023-10-09 21:56:15 +00:00
Daniel Zheng
ce57c58e6b Removing compression bit from v3 op
We don't need the compression bit in v3 op since all operations will
have the same compression per COW Device and it will be stored within the COW header.
We can check to see if an operation contains compressioned data by
checking data_length and see if it's less than BLOCK_SZ

Test: 4 critical OTA paths
Change-Id: I3f86756d83bf54bf6efd15d9cb7ac064eefdd949
2023-10-09 13:31:20 -07:00
Daniel Zheng
04e4c2a6c2 Add v3 writer
Adding v3 writer that works off of Cow Operation v3. Adding test file
that will test this new writer. Adding in stub implementations to v3 writer. None of these functions
have to work yet, we just need the implementations here to compile.

Test: m libsnapshot
Change-Id: If86437d5ceb2c33520d4ca26dea5193984f86546
2023-10-09 13:31:19 -07:00
Yurii Shutkin
a7dd77670e Merge "acvp: handle flush commond in modulewrapper as stated in BoringSSL." into main 2023-10-09 15:36:47 +00:00
Yurii Shutkin
f75464d65e acvp: handle flush commond in modulewrapper as stated in BoringSSL.
Change-Id: Ife655f0764851cf2d9677abd507daec3f531031e
Bug: 287626912
Test: ACVP test
2023-10-09 15:37:29 +02:00
Steven Moreland
0666c3a632 libutils: remove unused 'CALLSTACKS'
This macro is set, but it doesn't exist.

Bug: 302720583
Test: build
Change-Id: I88032c24b8bc8dc52d521e769149cbd8f619dde8
2023-10-07 00:35:38 +00:00
T.J. Mercier
af5de39039 Merge "libprocessgroup: Don't sleep after last cgroup removal attempt" into main 2023-10-07 00:34:39 +00:00
Steven Moreland
066e625b6b libutils: use log/log.h internally
utils/Log.h is one less file we need if we're
splitting up this library for binder.

Bug: 302720583
Test: build
Change-Id: Ibc7ec5402df342627f465354d7cf59e98f450a31
2023-10-07 00:29:44 +00:00
T.J. Mercier
b02f94490d libprocessgroup: Don't sleep after last cgroup removal attempt
Currently we sleep for 5ms before decrementing retries for the last
time. This is a waste of time, so bail out of the loop if the last
rmdir attempt fails.

Change-Id: Ia20840d27592b4eb3d9762647b19c111ff94209f
2023-10-06 23:11:09 +00:00
David Anderson
d8a9a0c81c init: Remove arbitrary delay in async persist writes.
Bug: 297093092
Test: manual test
Change-Id: Ia80b33d2fe87aa5da64b4f156fefeb474e68dc93
2023-10-06 14:52:08 -07:00
Sophia Coldren
d32b562ee9 Merge "Add an include" into main 2023-10-06 21:14:22 +00:00
Sophia Coldren
5880692ae2 Add an include
Change-Id: I0a6c64d9f1ddd9211de994fd4c6c44d53499775f
2023-10-06 18:46:17 +00:00
Xin Li
37e9952c93 Merge "Merge Android 14" into main 2023-10-06 05:34:13 +00:00
Xin Li
4f9ed9366f Merge Android 14
Bug: 298295554
Merged-In: Id86bcb915c8e2857bda26f64738dd5b643048e98
Change-Id: I6315e675753ec07fa1f67b69bcd05b831eeae6f0
2023-10-05 15:45:15 -07:00
Daniel Zheng
ad1ee13cec Merge "Removing is_retrofit code path" into main 2023-10-05 20:58:50 +00:00
Daniel Zheng
7248d1b0d8 Merge "Refactor off V2 Cow Ops" into main am: adad3dbefe
Original change: https://android-review.googlesource.com/c/platform/system/core/+/2736101

Change-Id: I0344daaa43ed555c0bcdd377629c70a167f2afa4
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-05 19:39:28 +00:00
Daniel Zheng
3e9b88d504 Removing is_retrofit code path
This code path was never invoked. is_logical will return false on
secondary partitions in retrofit devices, so nothing actually is ever
deleted. If we manage to call the delete, the device side code will
fail with "cannot open the super partition"

Test: fastboot flashall on sargo device
Change-Id: I20b430c5c30bf992506190ea4e00b0b69c7b1005
2023-10-05 12:37:57 -07:00
Daniel Zheng
adad3dbefe Merge "Refactor off V2 Cow Ops" into main 2023-10-05 19:12:56 +00:00