Commit Graph

250 Commits

Author SHA1 Message Date
4lDO2 a599d9b389 WIP: Store PageInfo in separate data structure. 2023-07-25 10:52:19 +02:00
4lDO2 760fc2ba5a WIP: Global page info structs. 2023-07-25 10:52:19 +02:00
4lDO2 593e21d95e Support schemes. 2023-07-25 10:52:19 +02:00
4lDO2 0a5b6ce656 Reach proc:memory access in userspace. 2023-07-25 10:52:19 +02:00
4lDO2 11fdb3bb46 Copy on writes to CoW pages. 2023-07-25 10:52:19 +02:00
4lDO2 565db7694f Add cow_refcount. 2023-07-25 10:52:19 +02:00
4lDO2 276f051d19 Further userspace progress, fix RMM bug. 2023-07-25 10:52:18 +02:00
4lDO2 8cfbc39b9f Get further in userspace. 2023-07-25 10:52:18 +02:00
4lDO2 490e1b2777 WIP: Track grant ownership. 2023-07-25 10:52:18 +02:00
4lDO2 e7d94ddff5 WIP: Lazy zeroed mapping and page fault handler. 2023-07-25 10:52:18 +02:00
4lDO2 8dfa73db35 Post-refactor fixes. 2023-07-25 10:52:18 +02:00
4lDO2 34b4512dbd Refactor Grants.
Page alignment is now verified at compile time, for example.
2023-07-25 10:52:13 +02:00
4lDO2 d4b5899c53 Remove allocator_owned hack. 2023-07-25 10:49:55 +02:00
bjorn3 e73e42be66 Replace intrinsics::abort() call in switch_finish_hook with safer abort mechanism
abort will still run the illegal instruction interrupt handler which may
not be safe.
2023-07-10 17:03:36 +02:00
bjorn3 7500ffaa5a Remove uses of the arbitrary_self_types feature 2023-07-10 17:03:36 +02:00
4lDO2 3ded84c945 Simplify x86_64 percpu and GSBASE calculation 2023-07-10 14:13:12 +00:00
4lDO2 56f88e80c2 Usercopy migration 2023-07-06 13:03:21 +00:00
uuuvn a5d4ccba57 More aarch64 stuff 2023-06-13 10:15:47 +00:00
uuuvn 63290429b2 Improve aarch64 code + memory management and crush some bugs 2023-06-12 14:46:02 +00:00
4lDO2 58c0c5d040 Remove one level of indirection for Context::name. 2023-05-27 14:27:34 +02:00
4lDO2 a451c0aa1b Fix aarch64 build. 2023-05-06 17:49:39 +02:00
Jeremy Soller 12688a929e Context switch optimization
- Contexts for other CPUs will never be evaluated for switch
- Running contexts will never be evaluated for switch
- Arc::clone is only called for previous and next context when there is a context to switch to
- Lots of cleanup to the switch function
2023-03-09 14:30:12 -07:00
4lDO2 ac913e49f9 Pin kmain contexts to corresponding CPUs. 2023-02-24 23:05:11 +01:00
4lDO2 8d14d54fa9 Support scheduler CPU affinity. 2023-02-15 14:50:01 +01:00
Jeremy Soller 33aa263deb Fixes for hpet counter read, choose better PIT divisor 2022-11-14 13:58:55 -07:00
Jeremy Soller 31868077f0 Use u128 for time, store CPU time of processes 2022-11-14 10:10:17 -07:00
Jeremy Soller 8e0f54cb31 Clippy fixes 2022-11-11 13:19:14 -07:00
Jeremy Soller 515a03b870 Fix warnings 2022-11-11 12:51:07 -07:00
Jeremy Soller 6753251af3 Do not allow mmap with page_count 0 2022-08-31 16:14:27 -06:00
Jeremy Soller 80b8382cd7 Fix aarch64 kfx size 2022-08-25 18:40:19 -06:00
Jeremy Soller 82ac7a66f7 Only save preserved regs in aarch64 context switch 2022-08-25 18:23:51 -06:00
Jeremy Soller afd82ba4bb Save/restore aarch64 FPU regs 2022-08-25 09:30:53 -06:00
Jeremy Soller 31680bf5b9 Do not set tpidr_el0 from kernel 2022-08-25 08:46:26 -06:00
Jeremy Soller f7e8026494 Set aarch64 thread pointers 2022-08-24 19:21:36 -06:00
Jeremy Soller b20a71113c Implement aarch64 switch_to_inner using naked function 2022-08-24 13:24:37 -06:00
Jeremy Soller 0ed9f03317 Use push/pop scratch for aarch64 signal handler 2022-08-24 12:29:48 -06:00
Jeremy Soller 613968dc30 Use push/pop scratch for x86 signal handler 2022-08-24 11:39:31 -06:00
Jeremy Soller 113a7164bb Use push/pup scratch for x86_64 signal handler 2022-08-24 11:11:50 -06:00
Jeremy Soller c750ee26a8 Implement setting FS/GS offset on x86 2022-08-20 21:21:32 -06:00
Jeremy Soller 01e4bc899e Fix compilation on x86 2022-08-20 18:11:57 -06:00
Jeremy Soller 9dd069c8ca Support proc partially with aarch64 2022-08-20 14:45:45 -06:00
Jeremy Soller 44d5e6573a Updated utable switching code for aarch64 2022-08-20 13:31:20 -06:00
Jeremy Soller fe7def2797 Update to use TableKind on x86_64 2022-08-20 13:16:23 -06:00
Jeremy Soller 01df1c20da Use TableKind everywhere 2022-08-20 13:06:52 -06:00
Jeremy Soller c7e5466bd7 Fix aarch64 switch_to_inner functino definition 2022-08-20 09:15:26 -06:00
Jeremy Soller 157dbc7b4d Convert aarch64 context switching to asm macro 2022-08-20 09:08:14 -06:00
Jeremy Soller 49fcafac45 Fix building on aarch64 2022-08-19 16:12:42 -06:00
Jeremy Soller 6b2439f1b9 Improved 32-bit x86 support 2022-08-18 14:57:15 -06:00
Jeremy Soller c09be1770b Use registers for switch_to_inner instead of stack 2022-08-18 09:09:11 -06:00
Jeremy Soller 4bd137f36e Fixes for x86 32-bit 2022-08-17 10:48:23 -06:00