Commit Graph

49 Commits

Author SHA1 Message Date
wnstngs 91491d825b kernel: remove the list_t alias since it's just a typedef for node 2026-10-07 14:08:36 +03:00
wnstngs 3894be1a15 kernel: use list.h for DPC queues 2026-10-07 10:23:18 +03:00
Matheus e4a4896b4b kcov: initial implementation
Implement a device (/dev/kcov) that exposes coverage info for the
kernel. This will be especially useful for coverage-based fuzzing (e.g.
syzkaller).

Exclude a lot of functions which would crash/otherwise interfere in the
coverage, including only processing coverage callbacks when not handling
an irq.
2026-10-06 11:51:02 -03:00
Matheus 011309d43d cpu: add irq depth counting
Add a way of checking if a cpu is in the middle of handling an irq and
how deep it is into it. This will allow for future code to conditionally
run only in/outside interrupts.
2026-10-06 11:51:01 -03:00
Matheus efe699bd2f x86_64 cpu: always inline asm helpers 2026-10-06 11:50:57 -03:00
Matheus babc6f3e06 cpu: cpu_cache_line_size 2026-07-17 18:06:03 -03:00
Matheus 239c267ed3 mm: rename vmm api to mm 2026-07-01 15:00:46 -03:00
Matheus f9912b8970 kernel: fix taking smep/smap path on unsupported systems 2026-05-14 12:03:11 -03:00
Matheus 71dd6d1125 x86-64: enable smep and smap 2026-04-23 15:29:43 -03:00
Matheus 5b164793cf syscall: do not use cr2 as a scratch register 2026-04-02 01:51:06 -03:00
Matheus 41f97c6c61 kernel: ldt support 2026-03-20 21:23:59 -03:00
Matheus 40bbf217ee kernel: profiling infrastructure 2025-12-05 18:19:42 -03:00
Matheus 2fa040096c slab: rewrite slab allocator 2025-09-04 22:55:19 -03:00
Matheus 3f03b4a467 mmu: make shootdown data per cpu 2025-08-31 23:27:03 -03:00
Matheus a11406a600 scheduler: load balancing initial implementation 2025-08-25 22:41:20 -03:00
Matheus 7a890ac41d scheduler: continue work 2025-08-23 13:54:45 -03:00
Matheus c024e1abb7 scheduler: little bit of cleanup 2025-08-20 22:15:09 -03:00
Matheus 136c86354c scheduler: continue rework 2025-08-20 22:00:25 -03:00
Matheus 607566531d kernel: rework init 2025-08-14 20:25:43 -03:00
Matheus a2f133b346 timekeeper: try to sync base time between cpus 2024-10-02 19:43:32 -03:00
Matheus b8acbc5bcd timekeeper: redo timekeeping 2024-09-29 11:20:40 -03:00
Matheus 0585eff9a2 x86_64 cpu: find topology 2024-09-24 23:08:58 -03:00
Matheus 749f945205 scheduler: slightly redo how the preemption dpc is enqueued and add a skeleton for a rescheduling ipi 2024-09-17 22:29:06 -03:00
Matheus 9974746c6c cpu: _bsp() -> get_bsp() 2024-09-15 22:52:24 -03:00
Matheus 16b6c86a5f cpu: rename _cpu() to current_cpu() 2024-09-15 19:03:09 -03:00
Matheus 56d665d5a0 kernel: fix remaining _cpu() races 2024-09-15 18:39:59 -03:00
Matheus 32392573cc cpu: change all _cpu()->vmmctx to current_vmm_context 2024-09-15 18:07:05 -03:00
Matheus e058d62261 cpu: change _cpu()->thread calls to current_thread() to fix smp race 2024-09-15 17:47:26 -03:00
Matheus 5382a8249b x86_64 cpu: change how the current cpu pointer is found 2024-09-15 15:26:40 -03:00
8infy 6154318ab3 kernel: add a helper to retrieve the bsp CPU
This is useful to be able to e.g. set affinity for the BSP CPU.
2024-09-01 19:37:09 +03:00
Matheus 04d8431b32 cpu: better _cpu() function 2024-05-27 22:03:44 -03:00
Matheus 890f6ba3ac dpc: fix smp 2024-05-26 17:18:41 -03:00
Matheus 27d24f3e20 cpu: dont access cpu local storage using rdmsr 2024-04-29 21:26:47 -03:00
Matheus de3226d23b cpu: more byte swap functions 2024-03-30 18:38:12 -03:00
Matheus 91f69e184d cpu: byte ordering swapping functions 2024-03-29 13:37:11 -03:00
Matheus ba16aa366f logging: make term and printf smp safe 2023-10-01 19:09:28 -03:00
Matheus 8f0b318238 CPU: EOI macro 2023-07-19 15:10:24 -03:00
Matheus 99a7eccbe4 kernel: DPC support 2023-06-25 21:00:14 -03:00
Matheus 80671b6e11 interrupts: execute pending interrupts 2023-06-25 16:00:08 -03:00
Matheus ca80c22f50 x86_64 cpu: syscall instruction 2023-05-07 19:31:36 -03:00
Matheus b5d4fc07e2 scheduler: have a separate stack for yield 2023-05-03 19:11:40 -03:00
Matheus a30a0b1d19 cpu: remove unused header include 2023-05-01 14:14:26 -03:00
Matheus 5d33fe828f scheduler: initial implementation 2023-04-27 23:34:57 -03:00
Matheus 5f84cdec3c interrupt: basic ipl handling 2023-04-23 15:42:39 -03:00
Matheus fefde1793e interrupt: interrupt_set() 2023-04-23 15:06:07 -03:00
Matheus 89c867fc3b apic: local apic initialisation 2023-04-21 21:23:11 -03:00
Matheus 30d64485fd kernel: initial vmm implementation 2023-04-16 20:47:41 -03:00
Matheus a9f490b431 kernel: initial interrupt abstraction implementation 2023-04-08 20:16:16 -03:00
Matheus 1555becce5 move arch include dir 2023-04-08 19:29:22 -03:00