Commit Graph

613 Commits

Author SHA1 Message Date
Kevin Lange
15c0208e99 Show user EIP for segfaults in kernel 2014-05-03 15:35:03 -07:00
Kevin Lange
ce48da7973 Fix debug_shell module 2014-05-03 00:15:07 -07:00
Kevin Lange
edd086b4aa Bump version to 0.7.2 2014-05-02 23:28:27 -07:00
Kevin Lange
10e241e982 Fix non-syscall validate 2014-05-02 19:28:14 -07:00
Kevin Lange
976c086e9c Define num_syscalls at compile time 2014-05-02 18:52:43 -07:00
Kevin Lange
fe19f4ad19 Extensive syscall table cleanup 2014-05-02 18:47:41 -07:00
Kevin Lange
bff1314c29 Add a header with syscall numbers 2014-05-02 18:34:38 -07:00
Kevin Lange
ac32220090 Remove disabled block of unneeded code in fork 2014-05-02 18:34:25 -07:00
Kevin Lange
bd73b07da9 Drop a few more legacy syscalls 2014-05-02 10:58:28 -07:00
Kevin Lange
e16043684a Only bother to deliver non-ignored blocked signals
So we don't accidentally interrupt a read or something.
2014-04-29 00:52:36 -07:00
Kevin Lange
4d8335ad75 Implement proper wait/waitpid.
This is a pretty big commit, so let's run through it in parts:

- All of the userspace changes are to switch away from syscall_wait
  Mostly, this is to waitpid; some things were tweaked to do things
  "properly" instead of waiting for particular processes. Init has
  been fixed to do a proper spin wait.
- syscall_wait is gone - as are its uses. newlib bindings have been
  using just waitpid for a while now.
- waitpid now performs like a Unix waitpid
- process reaping is no longer a "do this on next change thing":
  it happens when a process is waited on, like it should
  (That means we can have real zombies: terminated processes that
  have not yet been waited on)
- Reparenting of children to init has been implemented, so you
  can fork-daemonize!

Overall, this is pretty big... So I hope it doesn't break everything.
2014-04-27 01:37:33 -07:00
Kevin Lange
1c65d3d663 Include git short sha in version string instead of -dev 2014-04-26 22:17:30 -07:00
Kevin Lange
2db3fccd24 Do a better job with page table management 2014-04-25 23:17:20 -07:00
Kevin Lange
f9db32ec99 Bump version 2014-04-25 20:39:09 -07:00
Kevin Lange
1f235bb3e7 Don't forget to invalidate page directories after we free everything 2014-04-25 20:02:30 -07:00
Kevin Lange
8a786b6ffe Fix some potential mapping issues 2014-04-25 19:48:43 -07:00
Kevin Lange
4beb3a42dc throw frame allocation behind a lock so it's atomic 2014-04-25 00:15:08 -07:00
Kevin Lange
dedc201bc1 Ensure {0,0} auxv makes it into memory 2014-04-24 23:02:28 -07:00
Kevin Lange
e2a6ce072d Fix call to external malloc from klrealloc 2014-04-24 22:38:12 -07:00
Kevin Lange
e3ffd36083 Fix critical exec issue with not freeing old dir
We weren't freeing old page directories on exec, so regardless of the
actual size needed for the new process, we ended up with a huge address
space usage. Now, all of the memory from the other process is going to
be copied on the fork, and we can't do anything about that (beyond
writing a separate syscall that forks+replaces without the copy, or
implementing CoW, the latter being preferred) but that's at least a
well-know "problem".
2014-04-24 00:03:55 -07:00
Kevin Lange
c31bedd69e Let's just ... not do that 2014-04-21 19:40:28 -07:00
Kevin Lange
d0bfc0a5bb Efficient reallocation of SHM chunks (mostly) 2014-04-20 17:11:35 -07:00
Kevin Lange
d967fae3a5 Track down the root of that malloc problem 2014-04-20 13:19:52 -07:00
Kevin Lange
d99dc5688e Fix a glitch with signal handling 2014-04-19 19:10:22 -07:00
Kevin Lange
ff56f48ed5 Handle common symbols in module loader 2014-04-19 13:21:56 -07:00
Kevin Lange
3459f19443 List all undefined symbols before bailing when loading modules 2014-04-19 00:08:42 -07:00
Kevin Lange
ead93c5307 Probably as good a time as any to mark off 0.7.0 2014-04-18 20:40:25 -07:00
Kevin Lange
9b3cfc7fe6 More gracefully handle cases where ramdisk is big 2014-04-15 23:10:00 -07:00
Kevin Lange
6c6c3e18c1 Don't spam the log when increases the kernel heap 2014-04-15 19:57:25 -07:00
Kevin Lange
9ad1b50cb8 Change how we determine that a process is in a queue 2014-04-13 02:05:12 -07:00
Kevin Lange
d43f517464 Remove a lock from something that shouldn't be locking anyway 2014-04-13 02:05:01 -07:00
Kevin Lange
7d2083cae9 handle printf("%s", NULL) without crashing 2014-04-13 02:04:34 -07:00
Kevin Lange
20a1c56023 Fix some major paging issues 2014-04-13 02:04:01 -07:00
Kevin Lange
c1a2c312bb Fix a typo and a potentially crash with timers 2014-04-13 02:03:11 -07:00
Kevin Lange
d25e66b4bf Fix a null dereference from lists/trees 2014-04-13 02:02:17 -07:00
Kevin Lange
bf5d607a83 Fix extern declaration of isrs table 2014-04-13 02:01:56 -07:00
Kevin Lange
1f4d108c6c Don't allocate buffer on stack 2014-04-13 02:01:31 -07:00
Kevin Lange
0033d16cfa Fix a bad printf in syscalls 2014-04-13 02:01:20 -07:00
Kevin Lange
402392c109 Fix a potential crash on kernel tasklet startup 2014-04-13 02:01:08 -07:00
Kevin Lange
5a5cb62ce0 kill sockfs, what even is this 2014-04-13 00:51:37 -07:00
Kevin Lange
367c31c687 Restructuring intial paging setup 2014-04-12 23:03:56 -07:00
Kevin Lange
5673c2ee8f Cleanup fault handling 2014-04-12 23:03:44 -07:00
Kevin Lange
8cd386ba5b Set up a fake device for early boot logging 2014-04-12 23:02:03 -07:00
Kevin Lange
9e50872d5e Add multiboot mem map struct 2014-04-12 23:01:38 -07:00
Kevin Lange
e11edbbfd4 Don't calculate syscall table size at runtime 2014-04-12 23:00:59 -07:00
Kevin Lange
5a134e9a67 Fix missing header include 2014-04-12 18:46:25 -07:00
Kevin Lange
bf5409d0da Fix a problem with list merging / trees 2014-04-12 18:30:42 -07:00
Kevin Lange
7cb739b7cd Fix signalled wakeups from timed sleeps 2014-04-12 18:25:56 -07:00
Kevin Lange
ed6dc9507d Fix signal wakeups from existing sleeps 2014-04-12 18:15:28 -07:00
Kevin Lange
597a17949e Lists should have owners. 2014-04-12 18:15:10 -07:00