bjorn3
b0b0ec2d71
Deduplicate definition of FLAG_SINGLESTEP between x86 and x86_64
2026-04-09 15:23:34 -06:00
Speedy_Lex
ee1260363c
Fix many clippy lints
2026-04-08 19:40:41 +01:00
bjorn3
62f220b1b9
Use cfg! rather than #[cfg] for ACPI enabling
2026-04-04 13:49:07 +02:00
bjorn3
7aa7aa463f
Use map_device_memory where possible
2026-04-04 13:10:05 +02:00
bjorn3
dee230ffca
Use map_linearly in many places
2026-04-04 13:10:04 +02:00
bjorn3
1352fafd00
Remove unused InactiveFlusher
2026-04-03 22:15:00 +02:00
bjorn3
ab4abf63c9
Deduplicate Page and other paging related things between architectures
2026-04-03 22:15:00 +02:00
bjorn3
3cbce1b9ac
Move BSP_READY and AP_READY to platform-independent code
2026-04-02 20:29:36 +02:00
bjorn3
dc7e823f70
Deduplicate kernel page flags
2026-04-02 20:29:36 +02:00
bjorn3
c8879531ae
rmm: Add device_memory and uncachable flags to PageFlags
2026-03-30 20:34:45 +02:00
bjorn3
6e5c25b7a0
Move PAT initialization to rmm
...
Rmm needs to know the exact PAT configuration to produce the correct
bits in the page table.
2026-03-30 18:59:42 +02:00
bjorn3
c4b064ea44
Move arch specific EntryFlags into rmm
2026-03-30 18:49:15 +02:00
bjorn3
c51aa1ef86
rmm: Make a couple of methods safe
2026-03-29 14:16:53 +02:00
bjorn3
abf710b4a2
Move handling of kernel page table entry copying to RMM
...
This way it can ensure those page table entries never get unmapped,
ensuring they are kept in sync between all processes.
2026-03-29 14:16:53 +02:00
bjorn3
b5603422be
Check at compile time that KernelMapper is writable if necessary
2026-03-28 23:22:19 +01:00
Wildan M
c4e86bfffd
Change time offset to RwLock
2026-03-10 05:58:26 +07:00
auronandace
14b8c2b0c1
enforce two lints and collapse some ifs
2026-03-03 14:51:32 +00:00
auronandace
f7b0f5ec37
eliminate an unwrap in gdt for x86_shared
2026-03-02 10:56:28 +00:00
Wildan M
3c2b1a11c5
Add ordered lock for time offset mutex
2026-02-25 11:42:17 +07:00
bjorn3
858b712df5
Use naked_asm!() instead of global_asm!() where possible
2026-02-09 22:28:38 +01:00
Pascal Reich
a919d2626b
Inline Documentation Fixes
2026-01-10 16:19:34 -07:00
Wildan M
92132132c1
Implement clock_getres and handle path to time scheme
2025-12-21 05:24:13 +07:00
Jeremy Soller
01ec650b1e
Add support for userspace stack traces using usercopy
2025-11-10 08:54:06 -07:00
Jeremy Soller
91b835d29f
Reduce logging significantly
2025-11-01 20:24:11 -06:00
bjorn3
0f7b16d89d
Partially use cfg!() rather than #[cfg] for controlling the profiling module
...
This only adds a pointer worth of overhead per cpu core in the
PerCpuBlock struct.
Also fix a bunch of unsafe_op_in_unsafe_fn warnings in the profiling
code.
2025-10-26 18:27:29 +01:00
bjorn3
1498376360
Unify generic irq handling between x86 and x86_64
2025-10-25 19:44:03 +02:00
bjorn3
021cdf47f4
Fix a bunch of warnings
2025-10-19 14:27:43 +02:00
bjorn3
9d5ad06b30
Move some code from the trampoline to global_asm!()
2025-10-19 06:23:39 -06:00
bjorn3
ff65afd003
Don't depend on the stack setup by the bootloader
...
This way we can choose our own size for the stack and don't have to
identity map it manually. Also this way the bootloader doesn't have to
change the stack pointer right before calling into the kernel (which it
currently does in an unsound way)
2025-10-19 06:23:39 -06:00
Speedy_Lex
0931a7f49f
Resolve a huge portion of the clippy lints
2025-10-06 06:30:23 -06:00
Speedy_Lex
d38002969c
Fixes for rust update
2025-10-04 00:55:26 +02:00
bjorn3
ede9a47f9c
Move .bss and .data tests to inline asm
...
If .bss is not properly cleared or .data is incorrectly cleared, there
is no way to tell what will happen if we try to run Rust code.
2025-09-25 09:46:17 -06:00
Jeremy Soller
b6a5245556
Require passing loopback test for hard-coded serial
2025-09-23 11:33:37 -06:00
Jeremy Soller
5dc6f7c3ba
lock ordering
2025-09-22 07:48:48 -06:00
bjorn3
e7358e3e5b
Deduplicate a bunch of things that use KernelArgs between archs
2025-09-20 19:10:19 +02:00
bjorn3
3f385ba79d
Unify KernelArgs type between architectures
2025-09-20 19:10:19 +02:00
bjorn3
b36deffa61
Replace scrolling with wraparound in graphical debug
...
Inspired by how Haiku does printing for its kernel debugger, this commit
gets rid of the scrolling when the bootlog reaches the end of the screen
and instead wraps around to the start of the screen. Between the last
written line and the first visible written line there is always a blank
line to provide visual separation.
Getting rid of the scrolling significantly simplifies the implementation
of graphical debug and removes the need for double buffering for
performance as we no longer need to read back the framebuffer when
scrolling which is very expensive on write-combining memory like the
framebuffer.
2025-09-20 17:15:02 +02:00
bjorn3
f58bcd584e
Separate logical and hardware cpu ids
2025-09-20 15:33:08 +02:00
bjorn3
3a47c3becc
Move most HPET logs to the trace log level
...
This significantly reduces the amount of boot logs produced by the
kernel by default on x86. With this the full kernel boot logs now fit on
a single screen on my system.
2025-09-20 15:21:54 +02:00
bjorn3
081efd6cfa
Allocate IDT for APs on the BSP and statically allocate BSP IDT
...
This allows them to be immediately installed by kstart/kstart_ap without
having to wait for the page tables to be set up correctly. This removes
the initial IDT.
2025-09-17 21:03:36 +02:00
bjorn3
e81db007b7
Couple of cleanups to the IDT handling
2025-09-17 21:03:36 +02:00
bjorn3
742a7f4492
Remove Option around IDTs HashMap
2025-09-17 21:03:36 +02:00
bjorn3
25d526e9a1
Inline load_segments
2025-09-16 19:58:56 +02:00
bjorn3
647c87c5a0
Allocate PCR for APs on the BSP
...
This allows them to be immediately installed by kstart_ap without having
to wait for the page tables to be set up correctly. This removes the
initial GDT.
2025-09-16 19:57:31 +02:00
bjorn3
dbe25b78e3
Make it possible to change KernelArgsAp without changing the trampolines
2025-09-16 19:33:07 +02:00
bjorn3
019564ee0e
Statically allocate PCR for the BSP
2025-09-15 22:01:15 +02:00
bjorn3
4884d749af
Make PercpuBlock const constructable
2025-09-15 19:00:03 +02:00
bjorn3
3329a41121
Unify set_tss_stack and set_userspace_io_allowed signatures between x86 and x86_64
2025-09-15 18:37:27 +02:00
bjorn3
05e344bd9e
Unify tss alignment method between x86 and x86_64
2025-09-15 18:23:29 +02:00
bjorn3
9a14f9a80d
Unify gdt handling between x86 and x86_64
2025-09-14 20:30:57 +02:00