Commit Graph

162 Commits

Author SHA1 Message Date
K. Lange
a66f5c5f39 kernel: fix cast 2023-12-07 09:30:54 +09:00
K. Lange
8db7b3594b mbi2: Set normal load address 2023-12-07 09:29:36 +09:00
K. Lange
a8b506ad33 kernel: experiment with static-pie 2023-11-10 15:40:41 +09:00
K. Lange
b724489609 kernel: cleanup legacy stuff 2023-11-05 15:25:12 +09:00
K. Lange
d88712e956 kernel: support syscall/sysret 2023-11-05 14:32:47 +09:00
K. Lange
cf04ba62e8 syscall: Change x86-64 syscall register ABI 2023-11-05 10:40:12 +09:00
K. Lange
613bc73dfd kernel: properly track time in kernel when returning to userspace 2023-11-02 10:21:00 +09:00
K. Lange
55e873bd6b x86_64: Fixup error codes for rare/new exceptions 2023-10-25 12:46:36 +09:00
K. Lange
afcf36de70 rpi: advertise correct default speed of miniuart
Does not implement setting the baud rate yet, but correctly
advertises that we set it to 921600 by default.
2023-10-09 14:05:36 +09:00
K. Lange
bda8c8d67b pty: initial support for setting line control 2023-10-08 14:52:34 +09:00
K. Lange
4f36cac62c kernel: get rid of unused interrupt_registers
process_t member was never set, but was referenced in ptrace
core-local member was set in x86-64 but never used
2023-10-06 07:46:11 +09:00
K. Lange
d45a0f2b13 virtio: name worker threads with square brackets 2023-07-22 23:17:39 +09:00
K. Lange
d4315dcb53 aarch64: don't set debug output as primary so we can print early log to framebuffer 2023-07-15 19:25:08 +09:00
K. Lange
7691b1691f aarch64: don't print every time we do a dtb lookup 2023-07-15 19:24:21 +09:00
K. Lange
e9811a0708 virtio: handle queue overflow 2023-04-30 19:09:49 +09:00
K. Lange
ffb7bc36bb aarch64: ensure module base address starts aligned 2023-04-18 22:45:19 +09:00
K. Lange
6d2d6edffc boot: CONSOLE_FLAGS mb2 tag is optional 2023-04-11 17:35:30 +09:00
K. Lange
a4a73a0835 boot: Don't jump back to protected mode in EFI loader 2023-01-05 15:39:44 +09:00
K. Lange
940d82f0f4 terminal: Bitmap font can use uint8_t
The baked Deja Vu Sans Mono is 8 pixels wide, so we don't need
to use uint16_t to hold rows of pixel data. Also, splash-log
doesn't render text anymore (it defers to the kernel console),
so we don't need to include the font there any more.
2022-12-13 15:08:56 +09:00
K. Lange
bf2c51426d kernel: proc->group may have exited
Handling of thread parents needs to be better... the initial thread
of a process can disappear, and with pid reuse it could even be
replaced by a different process... this needs to be cleaned up more.
2022-10-29 17:27:05 +09:00
K. Lange
ce625f2137 aarch64: enable userspace access to timer physical counter 2022-08-30 17:12:49 +09:00
K. Lange
1960006ec7 aarch64: dump regs on unknown fatal exceptions 2022-08-30 17:12:18 +09:00
K. Lange
ecbe7f6cbb aarch64: don't be so intent on running driver bringup on cpu0 2022-08-30 17:11:42 +09:00
K. Lange
c554bf581c kernel: Support SA_NODEFER 2022-08-06 18:24:06 +09:00
K. Lange
2906476825 kernel: Add sigaction 2022-08-06 18:03:39 +09:00
K. Lange
5ed3dc0640 virtio: Remove unused PCI cap parsing 2022-04-18 10:03:19 -04:00
K. Lange
f44a6bbe9a aarch64: read rtc time again on qemu 2022-04-17 18:22:53 -04:00
K. Lange
9ecad97b64 virtio: these F keys should work too 2022-04-13 22:20:12 -04:00
K. Lange
71ce811a65 virtio: map command to left super 2022-04-13 18:18:13 -07:00
K. Lange
f144266bc5 aarch64: ac97 driver as module 2022-04-13 16:19:56 -07:00
K. Lange
7fbb7d64d7 aarch64: e1000 driver as module 2022-04-13 16:19:56 -07:00
K. Lange
bea3854b00 aarch64: (wip) support kernel modules 2022-04-13 16:19:56 -07:00
K. Lange
de09abf2dd x86-64: fixup serial receive loop as this one was kinda bad 2022-03-22 14:13:21 +09:00
K. Lange
5caf43d90a kernel: x86-64: copy over unmap improvements from aarch64 2022-03-16 08:39:33 +09:00
K. Lange
00075494e6 kernel: aarch64: initial pass at clearing upper page structures on unmap
This still has thread issues, but a lot of other things need to be
redesigned to correct them.

Particularly, we have a lot of callers that use `mmu_get_page` without
acquiring any locks on the page directory, so in a multithreaded process
one core may be trying to acquire pages while another is unmapping. In
the normal sbrk setup, this shouldn't happen, especially with the locks
in userspace around malloc, and it shouldn't happen with shm as we avoid
dealing with shm pages in the unmap right now, but from the raw API we
provide it's possible for a crafted program to run into it.

The whole memory management API really needs a redesign, much of what we
expose comes from toaru32, and still leaks details about page size into
other code that shouldn't care.
2022-03-16 08:19:36 +09:00
K. Lange
58a1b6e999 pthread: Remove magic thread exit; pthread_exit() is just syscall_exit 2022-03-12 18:46:28 +09:00
K. Lange
4bcd1b4b89 aarch64: apply e1000 permission changes 2022-03-07 18:08:54 +09:00
K. Lange
2700849ca2 aarch64: clear instruction cache on new pages when forking 2022-03-07 09:20:19 +09:00
K. Lange
4c2ec1f0a0 kernel: add a temporary 'munmap' sysfunc 2022-03-06 15:58:38 +09:00
K. Lange
49fd67bf2d kernel: relocate some user virtual addresses 2022-03-06 15:58:08 +09:00
K. Lange
f778967edb aarch64: disable lock debugging 2022-03-06 15:56:53 +09:00
K. Lange
cd04af0a75 aarch64: remove some debug messages 2022-03-04 22:08:05 +09:00
K. Lange
d932559d79 kernel: ensure we're saving/restoring all process state on signals 2022-03-04 22:04:11 +09:00
K. Lange
63fbbec928 kernel: Don't let things clear frames without holding the frame alloc lock 2022-03-04 22:00:37 +09:00
K. Lange
3852646174 kernel: Restart some signals, fix up suspend to work with new signal management 2022-03-04 18:39:38 +09:00
K. Lange
bbebc7c128 kernel: complete redesign of signal handling 2022-03-04 16:12:16 +09:00
K. Lange
b3f6728339 date: add rudimentary support for setting date/time 2022-02-25 21:16:30 +09:00
K. Lange
7d2beb443b aarch64: expose dtb as a device file 2022-02-23 20:40:53 +09:00
K. Lange
b29edb0db3 rpi400: mini uart driver 2022-02-23 16:33:30 +09:00
K. Lange
94b86558d3 aarch64: cleanup, fix warnings 2022-02-23 10:27:47 +09:00