Age | Commit message (Collapse) | Author | |
---|---|---|---|
2021-09-05 | Kernel: Make all Spinlocks use u8 for storage, remove template | Brian Gianforcaro | |
The default template argument is only used in one place, and it looks like it was probably just an oversight. The rest of the Kernel code all uses u8 as the type. So lets make that the default and remove the unused template argument, as there doesn't seem to be a reason to allow the size to be customizable. | |||
2021-09-05 | RequestServer: Exit early to avoid executing protocol destructors | Brian Gianforcaro | |
I broke this when I made the protocol objects be wrapped by smart pointers to appease static analysis. The Protocol base class currently VERIFY's that it's never called. So to have the best of both worlds until someone actually fixes the code to do proper de-registration, just call `exit(..)` so the smart pointers never go out of scope. | |||
2021-09-05 | Documentation: Add Patterns.md | Brian Gianforcaro | |
The purpose of this document is to track and describe the various patterns used through the SerenityOS code base. | |||
2021-09-05 | Userland: Switch static_assert of type sizes to AK::AssertSize | Brian Gianforcaro | |
2021-09-05 | Kernel: Switch static_asserts of a type size to AK::AssertSize | Brian Gianforcaro | |
This will provide better debug ability when the size comparison fails. | |||
2021-09-05 | AK: Add AssertSize utility template to provide rich type size assertions | Brian Gianforcaro | |
This type is useful, as the sizes will be visible in the compiler error messages, as they will be part of the template parameters. This is not possible with a normal static_assert of the sizeof a type. | |||
2021-09-05 | Kernel: Use TRY() in DevFSLinkInode::write_bytes() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in ProcFS | Andreas Kling | |
2021-09-05 | Kernel: Make FileSystem::get_inode() return KResultOr<NRP<Inode>> | Andreas Kling | |
This allows for natural error propagation in a bunch of new places. | |||
2021-09-05 | Kernel: Use TRY() in sys$waitid() | Andreas Kling | |
2021-09-05 | Kernel: Simplify sys$inode_watcher_remove_watch() a little bit | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$create_inode_watcher() and friends | Andreas Kling | |
2021-09-05 | Kernel: Make file description lookup return KResultOr | Andreas Kling | |
Instead of checking it at every call site (to generate EBADF), we make file_description(fd) return a KResultOr<NonnullRefPtr<FileDescription>>. This allows us to wrap all the calls in TRY(). :^) The only place that got a little bit messier from this is sys$mount(), and there's a whole bunch of things there in need of cleanup. | |||
2021-09-05 | Kernel: Use TRY() in sys$sethostname() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$mount() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$umount() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$set_process_name() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$set_coredump_metadata() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$create_thread() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$set_thread_name() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$write() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$perf_register_string() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$recvfd() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$pledge() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() even more in sys$mmap() and friends :^) | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$dbgputstr() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$map_time_page() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$setkeymap() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$realpath() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$statvfs() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$stat() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$unlink() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$readlink() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$rmdir() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$rename() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$utime() | Andreas Kling | |
2021-09-05 | Kernel: Use copy_typed_from_user<T> for fetching syscall parameters | Andreas Kling | |
2021-09-05 | Kernel: Add copy_typed_from_userspace<T>(Userspace<T const*>) | Andreas Kling | |
This allows easy retrieval of typed POD values from userspace with implicit error propagation. | |||
2021-09-05 | Kernel: Make copy_{from,to}_user() return KResult and use TRY() | Andreas Kling | |
This makes EFAULT propagation flow much more naturally. :^) | |||
2021-09-05 | Kernel: Use TRY() in sys$read() and sys$readv() | Andreas Kling | |
2021-09-05 | Kernel: Reorder sys$pipe() to fail more nicely | Andreas Kling | |
Try to do both FD allocations up front instead of interleaved between assigning them to the descriptor table. This prevents us from failing in the middle of setting up the pipes. | |||
2021-09-05 | Kernel: Use TRY() in sys$open() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$mknod() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$mkdir() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$lseek() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$fork() | Andreas Kling | |
There's a lot of work to do on improving error propagation in the fork system call. This just scratches the surface. | |||
2021-09-05 | Kernel: Use is_error() in sys$fcntl() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$chown() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in sys$chmod() | Andreas Kling | |
2021-09-05 | Kernel: Use TRY() in AnonymousVMObject | Andreas Kling | |