4lDO2
de23cd447e
Fix aarch64 build.
2023-08-08 12:01:43 +02:00
4lDO2
ca92eda5e6
Remove TLS on aarch64 too.
2023-08-08 12:01:42 +02:00
4lDO2
ed2febb289
Disable thread-local storage entirely.
2023-08-08 12:01:42 +02:00
4lDO2
a78d6e42f8
Stop using #[thread_local] on x86_*.
2023-08-08 12:01:42 +02:00
4lDO2
bdd5c954dc
Move PIT_TICKS to context::switch.
2023-08-08 12:01:42 +02:00
4lDO2
0c90802ae0
Fix RaiiFrame deallocation.
2023-08-08 11:57:57 +02:00
4lDO2
4688090dea
Fix RaiiFrame typo.
2023-08-03 16:46:42 +02:00
4lDO2
8f98d5b987
Extend mremap, eager mappings for real hardware.
2023-08-03 12:37:58 +02:00
4lDO2
c7714992f3
Fix clone_grant_using_fmap test.
2023-08-02 14:17:26 +02:00
4lDO2
2070fa44b7
Fix warnings.
2023-08-02 13:07:49 +02:00
4lDO2
05a9530ac7
Temporarily disable CoW fmaps.
2023-08-01 17:29:36 +02:00
4lDO2
34708bd1be
Temporarily disable MAP_LAZY.
2023-08-01 15:44:41 +02:00
4lDO2
fe88b23d09
Use a single cow zeroed page for RO maps + eager mapping.
2023-08-01 13:11:00 +02:00
4lDO2
1e670645e4
Bypass kernel heap for storing PageInfo.
...
Since these are stored in arrays that are typically 512 KiB each
(i.e. which in turn typically store metadata for 128 MiB), they will
certainly be a page-size multiple, and large contiguous allocations are
allowed at least at boot time. Not only is the linked-list allocator
less efficient for that, but this change will also help reduce TLB
overhead.
2023-08-01 11:22:42 +02:00
4lDO2
8a8c04685e
Merge adjacent frame sections.
2023-08-01 10:55:01 +02:00
4lDO2
0cdfb886c0
Fix debugger for x86_64, disable sc debug.
2023-07-28 13:40:00 +02:00
4lDO2
e28fef09e3
Improve aarch64 debugger.
2023-07-28 13:23:44 +02:00
4lDO2
d16569110e
Don't mess up x18 in aarch64 exc handler.
2023-07-28 12:56:55 +02:00
4lDO2
ce35deed4b
Support aarch64 page consistency checking.
2023-07-28 12:38:25 +02:00
4lDO2
f454df38eb
Fix get_page_info.
2023-07-28 10:47:18 +02:00
4lDO2
ec9c24f841
WIP: aarch64
2023-07-27 19:05:33 +02:00
4lDO2
8b7fc8a468
Compile and mostly run properly on i686.
2023-07-27 16:45:36 +02:00
4lDO2
f4bdb5388e
Remove AtomicU64 requirement for starting APs.
2023-07-27 16:44:52 +02:00
4lDO2
885f88b777
Fix futex for non-AtomicU64-capable targets.
2023-07-27 16:44:26 +02:00
4lDO2
25d26b3b93
Arch-independent x86-modeled page fault handler.
2023-07-27 15:56:45 +02:00
4lDO2
7a3b453fbb
Declare __usercopy_{start,end} as functions.
2023-07-27 15:34:33 +02:00
4lDO2
4d2cd6ce0f
Remove redundant log msg.
2023-07-27 15:25:51 +02:00
4lDO2
a4a84775d6
Fix MMAP_PREP order.
2023-07-26 22:31:56 +02:00
4lDO2
d6e1732d44
Stop using feature(arbitrary_self_types).
2023-07-25 11:22:36 +02:00
4lDO2
3cfec39b47
Pass MunmapFlags to scheme.
2023-07-25 10:52:24 +02:00
4lDO2
c9aa5ca851
WIP: Add SYS_MREMAP.
2023-07-25 10:52:24 +02:00
4lDO2
2660c3e07a
WIP: Pin fmap grants that are borrowed too.
...
This might not be the most ideal solution, since a GiB grant can be
EBUSY blocked if a single page is used by an indefinitely-blocking
UserScheme. But, the alternatives would impose lots of additional
complexity, such as increasing the PageInfo size, adding more
refcounting arrays to grants, etc.
2023-07-25 10:52:24 +02:00
4lDO2
e054a5b211
Add debugger checks for correct CoW page flags.
2023-07-25 10:52:24 +02:00
4lDO2
37579601b2
Remove one level of indirection in get_page_info.
2023-07-25 10:52:24 +02:00
4lDO2
e2b736140f
Make PageInfo atomic once again.
2023-07-25 10:52:24 +02:00
4lDO2
d58ddc35fe
Complete PageInfo cleanup.
...
This enables proper CoW ^ shared enforcement, so that e.g. acquiring a
new CoW page from already shared memory, or vice versa, will enforce
that they aren't both simultaneously.
2023-07-25 10:52:23 +02:00
4lDO2
0f1b5b9b6f
WIP: Make cow/shared refcounts mutually exclusive.
2023-07-25 10:52:23 +02:00
4lDO2
113cb5ed4e
Ensure pages cannot be both CoW and shared.
2023-07-25 10:52:23 +02:00
4lDO2
d3ecedefd9
Notify schemes when mmaps are unmapped.
2023-07-25 10:52:23 +02:00
4lDO2
02f04752e8
Use proper locks for PageInfo.
2023-07-25 10:52:23 +02:00
4lDO2
7bdf5e9af3
Pass unaligned length to scheme for fmap.
2023-07-25 10:52:23 +02:00
4lDO2
afa3d7dc7b
Support anonymous MAP_SHARED mmaps.
2023-07-25 10:52:23 +02:00
4lDO2
70b4d99c96
Implement MAP_FIXED without MAP_FIXED_NOREPLACE.
2023-07-25 10:52:23 +02:00
4lDO2
f0341280f7
Fix frame deallocation.
2023-07-25 10:52:23 +02:00
4lDO2
3a80528d13
Fix MAP_LAZY mappings.
2023-07-25 10:52:23 +02:00
4lDO2
cbec83215a
Lazy-evaluate pages returned by fmap.
2023-07-25 10:52:22 +02:00
4lDO2
9182722f84
WIP: Allow listing address space grants again.
2023-07-25 10:52:22 +02:00
4lDO2
0466e87e59
Error if scheme fmap returns unaligned address.
2023-07-25 10:52:22 +02:00
4lDO2
ba62c0606e
Pin PhysBorrowed head/tail UserScheme grants too.
2023-07-25 10:52:22 +02:00
4lDO2
329d60848c
WIP: Support CoW fmap.
2023-07-25 10:52:22 +02:00