Age | Commit message (Collapse) | Author |
|
Add device_tree library that adds a few wrappers on top of libfdt to
help read values out of properties that can have mutiple rows of
variable sized values.
Bug: 297275002
Change-Id: Iac0f757f82d0b6f8e8c6b29cb41efd61ffeca589
|
|
Bug: 297275002
Change-Id: I40826d18011c95ce52bdf0fa7978ba6f034bb5c6
|
|
The caller passed an item to bst_search_type that did not match the
specified type without getting a compile error as long as item also had
a member with the same name. As a result the compare function would get
a pointer passed to an object with the wrong type.
Bug: 335515844
Change-Id: I85695b8aaf4463a117de1f3a9a9b0f9acb72ada1
|
|
Add api to search for a node without providing a temporary node struct.
Bug: 335515844
Change-Id: Id25f7994ce1e5fc8183bcf1507782c2c4acfdc89
|
|
This library is now an implicit dependency so we need to explicitly
declare its actual dependencies.
Test: build.py generic-x86_64-test
Bug: None
Change-Id: I967bd47a7ef6d852650c61e7fa68aa32779b3960
|
|
Implement `mod thread` by wrapping the C
`thread_create` and `thread_spawn` APIs.
`mod thread` is modeled on `std::thread`'s API,
including `Builder` and `spawn`.
Test: build.py generic-x86_64-test
Bug: 298705967
Change-Id: If78ee4748cf11fe67ca25dfdea7ad81a12759fce
|
|
Move lib/rust_support from kernel/rules.mk to implicit dependency for
rust kernel modules. It was added to kernel/rules.mk so the panic
handler was included, but this also pulls lib/rust_support into kernels
that don't have any rust modules and therefore does not need it. We also
have CLs that add features to lib/rust_support that don't yet compile on
arm/arm64 where CFI is enabled. Moving this depandency lets us extend
lib/rust_support and use it on x86, where CFI is not yet enabled, while
we wait for an updated toolchain.
Bug: 328519718
Test: trusty/vendor/google/aosp/scripts/build.py generic-x86_64-test
Change-Id: I6badf66f7b138fbbc77bdd1ace4161cf0d4cf9a6
|
|
Update timertest to need smp4
Bug: 331321891
Test: Build.py
Change-Id: I70f91580709a74269487564304509214f481d386
|
|
It appears that try_lock is only used to support formatting of the
Trusty mutex wrapper so we remove formatting for now since it is
faster than fixing the implementation and adding tests for it.
Test: build.py generic-x86_64-test
Bug: 298705967
Change-Id: Ia0f1ab7269080f8ae9543875942067ff3c375950
|
|
The old code incorrectly claimed the timer could handle a 55 ms timer,
and clamped the millisecond value to 55 before converting from ms to pit
timer ticks. The converted value overflow when then clamped to 16 bits
resulting in a timer request less than 100 microseconds into the future
instead of 55 millioseconds. This resulted in 100% cpu usage while
waiting for a timer 55ms or longer.
Improve the precision of the conversion by converting directly from nano
seconds to pit timer ticks instead of first converting to milliseconds.
Then clamp the value after the conversion instead where the boundary is
more clear.
Also remove code that starts a periodic timer on boot that had no
apparent purpose.
Bug: 311709679
Change-Id: Ia2cff162b9bf2359973356a5108de87ec860d61b
|
|
Bug: 304851081
Change-Id: Iebc3de4c684264e2f13d8f05ff9b1aea1327d7c3
|
|
Limit only disable it for external/rust. This might need to be updated
if we add otjher external rust projects.
Bug: 304585390
Change-Id: I366d45eb62d659473df31c898c48425a7cac74cd
|
|
Bug: 328206729
Test: build.py qemu-generic-arm64-test-debug
Change-Id: If3a73046f3b60454bc6edc78f1c2ed5befc30d2e
|
|
Testing aosp/2994822 immediately causes a panic because
mutex_acquire and mutex_release in the trusty kernel returns
NO_ERROR (0) on success but the rust code asserts that the
response is non zero.
Test: with appropriate patches applied, build.py generic-x86_64-test
Bug: 298705967
Change-Id: I16f4371640f4b5fa7fa77e6775df5f3ce38765fa
|
|
Implement `Mutex` by wrapping the C `mutex_t` API.
`Mutex` is modeled on `std::sync::Mutex`'s API.
Test: build.py generic-x86_64-test
Bug: 298705967
Change-Id: I2443da0757796f7859bc6ff38d99b104d40e8da0
|
|
Bug: 304850822
Change-Id: I48710688628d82ad1d377ce0b4a4ec2b50d48d0e
|
|
Bug: 304850822
Change-Id: Iee9bda4c3288ce01dc4303f7d92926d7500ddb31
|
|
Test: build.py generic-x86_64-test
Bug: 298705967
Change-Id: I8adebf527b36de7e8ca42a1e6bafa80bf1cc2679
|
|
Bug: 304851081
Change-Id: I9562025161eefaf908f241ffc69f9fa55da17a4f
|
|
Fix vmm_alloc_physical to more closly match the C version. It takes a
paddr_t argument for the physical address to map, not a pointer to a
paddr_t like vmm_alloc_physical_etc does (as that function needs an
array of physical addresses, not a single physical address).
Bug: 298705967
Change-Id: Ie4230a44c56d1896bdac6c0fa011b72ac9a435ca
|
|
vmm_alloc_physical_etc does not modify this array, so it should be const
so the caller does not have to have a writable array.
Bug: 298705967
Change-Id: Ieed94570c33763565e67a170382b3d1e10f120f2
|
|
Allows switching from cfi to kcfi.
Bug: 304585390
Change-Id: Ie7928e9d621946c12905362d03bf6eedcfd83746
|
|
Bug: 304851081
Change-Id: I5ee241a21284cc7dfdea43508e90be6f0adae61c
|
|
Bug: 304851081
Change-Id: I626574e8666b3013d4e551b70cc2d13c16cffbc1
|
|
The x86/64 build has an .init_array.90 entry pointing to
__cpu_indicator_init. No problems have been observed so far from not
calling this init function, letting the linker put it elsewhere can
cause relro related link failues. Include .init_array.* and related
symbols in .ctors to avoid these failues.
Bug: 304851081
Change-Id: Idba5a1c036602276339bfbcc1124d35052c318af
|
|
Exposes constants from mmu.h, err.h and functions from vmm.h.
Bug: 298705967
Test: build.py generic-x86_64-test
Change-Id: Id464e7884392e419ca4e4484eb530e1d3eecd4c7
|
|
Bug: 304850822
Test: build.py and inspect kernellib/rust-project.json
Change-Id: I45ea85a65c916e9e17d21c57db127ee9f95ab28a
|
|
Rust in the kernel needs to not use floating point and SSE registers.
Bug: 304850822
Test: build.py generic-x86_64-test
Change-Id: I582aaf5c1de33805ff9a41f05df20a310d30d01d
|
|
Bug: 328206729
Test: build.py --test com.android.wxntest
Change-Id: Ie888802190283b0a7a949923e0cf7f1aa26b083f
|
|
Set SCTLR.WXN so that writable pages are non-executable (NX),
independent of PTEs.
Bug: 328206729
Test: Build and run build tests.
Change-Id: I75b972393be90ba837bb094ccd518235b9dc6547
|
|
Adds a Rust panic handler for the Trusty kernel that prints the panic message
and location before calling the kernel panic API.
Bug: 328519718
Test: Manually add panic from Rust in the kernel
Change-Id: I9ed88037f9432d36e8c215994bd8c8f2bc2e9e3e
|
|
We are adding a proper Rust panic handler in
Ib01a7ffe84303f23b458a07fa3ddf2c1ecb3e702, so we should not inject a panic
handler in the top level source file. The panic_abort feature flag is only
needed for the panic_abort crate that implements a basic abort panic handler.
With our custom panic handler we don't need this dependency, so this change
removes the feature flag.
Test: build.py
Bug: 328519718
Change-Id: Ibd40ea4e2ef476237879df332350f8966852a927
|
|
Fixes a build issue where multiple crates cannot be integrated because
MODULE_RUST_STEM was not reset between modules. Also fixes a small build
dependency issue where the Rust wrapper source was depending on the wrong
filename containing crate stems.
Test: build.py
Bug: 304850822
Change-Id: I9ce00706e3524cf40d3dc06deec3347913b4c575
|
|
Bug: 304850822
Change-Id: I4c0227d0c08054af029db2250cdb2d91f2063a8c
|
|
According to clang, the right way of including file before parsing
should be one of the following format:
-include<file>, --include<file>, --include=<arg>
The current one still works, however, is causing problem when generating
compilation database with 3rd party tool (bear).
Bug: 328453446
Test: Manual build
Change-Id: Id4c8d1eb5c0c02f7a51a0d81ff4daa6b54b0005e
(cherry picked from commit 9fc92d0e423e6682a6dae3dd4e07eb5695d034c3)
|
|
Original change: https://android-review.googlesource.com/c/trusty/lk/common/+/2970316
Change-Id: Id0450b8e92b97f2d878ead6fb4961d2ef682a696
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
|
|
Bug: 304850822
Change-Id: I5a7e0d8f24099b7d6d10e594e7add3184e01d758
|
|
Original change: https://android-review.googlesource.com/c/trusty/lk/common/+/2978633
Change-Id: I4b54f3576ff5f49de4d42384bc6b8ca2da504d7e
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
|
|
Reduce the space taken by some module_config.h variables
by substituting the full build root path with the
__BUILDROOT__ placeholder. E.g. this reduces the size
of MODULE_SRCDEPS for binderRpcTest from 70K to 48K.
Bug: 285203365
Test: m trusty_generic-arm64-test-debug
Change-Id: I1f80af62eaf6cad943591ba4897147a20a28b861
|
|
680187686c
Original change: https://android-review.googlesource.com/c/trusty/lk/common/+/2961683
Change-Id: I471d11987d6084158a1f27a2538149cfa30a77cf
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
|
|
This ensures that the kernel build system fully works
for a Rust implementation of virtio vsock using the `virtio-drivers` crate.
Test: build.py generic-x86_64-test
Bug: 298705967
Change-Id: I35209881c139743bfd3481d078a93a7fdc6a39ec
|
|
Original change: https://android-review.googlesource.com/c/trusty/lk/common/+/2973675
Change-Id: I32ac8c4414272a6d710e09ae31675402b2822503
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
|
|
-ftrivial-auto-var-init=zero compile flag for non-debug builds
Bug: 325453864
Test: Build.py + CI
Change-Id: Id9bd8fb4135ba0fa6fde51c869da90b9150235d4
|
|
Original change: https://android-review.googlesource.com/c/trusty/lk/common/+/2971134
Change-Id: I3677f274bfd913fb0066517cf98c6341a6e80902
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
|
|
To help debugging of histotric builds, generate a lst file with
interleaved source and assembly for lk.elf as a build artifact.
Bug: 326190304
Test: build.py & inspect lst file
Change-Id: I98fe297b2b3592928d089f9d51129193da42958f
|
|
Original change: https://android-review.googlesource.com/c/trusty/lk/common/+/2964303
Change-Id: Ib87443a1d5a0e4383b59591bd210e122719ca9f5
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
|
|
kernel am: eed28eae38
Original change: https://android-review.googlesource.com/c/trusty/lk/common/+/2962962
Change-Id: I44608863836f81b3d83caf2bef1a2f17057a1964
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
|
|
af110228b1
Original change: https://android-review.googlesource.com/c/trusty/lk/common/+/2964302
Change-Id: I1ccc953729e0153c4b8653c5515815a343e3d86e
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
|
|
Original change: https://android-review.googlesource.com/c/trusty/lk/common/+/2939539
Change-Id: I1e525d8ed89d0ea6b6a3bf6d66f0bf63e72b4fe9
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
|
|
74ed0f4bf0
Original change: https://android-review.googlesource.com/c/trusty/lk/common/+/2940505
Change-Id: I3e2f0a977843b3c38379c7495a18cec51be62f1d
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
|