aboutsummaryrefslogtreecommitdiff
path: root/src/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* Remove VFS entirely (#56)Himbeer2024-07-273-893/+1
|
* kernel: Update general panic message to include sepc and stval CSRsHimbeer2024-07-271-0/+1
|
* Rephrase panic messagesHimbeer2024-07-273-23/+18
| | | | Fixes #62.
* syscall: Support termination of other processes or (individual) threadsHimbeer2024-07-272-7/+34
| | | | Closes #57.
* kernel: Remove PCI(e) driverHimbeer2024-07-271-758/+0
| | | | Closes #58.
* kernel: Remove all builtin resources (/userinit) (#60)Himbeer2024-07-271-133/+0
|
* resources: Remove VFS stream /io/debug, use uprint instead (#60)Himbeer2024-07-271-42/+0
|
* syscall: Convert VFS hook /process/create => launch(bytes: ↵Himbeer2024-07-272-152/+16
| | | | [*]align(@alignOf(std.elf.Elf64_Ehdr)) const u8, len: usize) !usize (#60)
* syscall: Restrict processId() and threadId() proc parameter to const pointerHimbeer2024-07-271-2/+2
|
* syscall: Revert VFS hook /process/self/thread_id => threadId() usize (#60)Himbeer2024-07-272-22/+6
|
* syscall: Revert VFS hook /process/self/id => processId() usize (#60)Himbeer2024-07-272-28/+20
| | | | Includes switching to a new return system, allowing syscall handlers to have regular function signatures.
* syscall: Revert VFS hook /process/self/terminate => terminate() void (#60)Himbeer2024-07-272-19/+9
|
* paging: Mark pages -rw- during zeroed allocation to ensure that reusing a ↵Himbeer2024-07-261-1/+10
| | | | | | page doesn't fault Write access applies to the current page table configured in the SATP CSR and is only granted to S-mode. It can either be overwritten by the caller or be made irrelevant by switching to a different page table, and all allowed accesses are from trusted code anyway.
* vfs: Annotate all problematic directory hook usages with fixmeHimbeer2024-07-251-0/+2
|
* vfs: Implement directory (hook) listingHimbeer2024-07-252-23/+98
|
* sysexchange: Handle invalid and user-provided Status codesHimbeer2024-07-251-0/+17
| | | | Fixes #52.
* vfs: Alias sysexchange.Result to ResultHimbeer2024-07-251-9/+10
| | | | Fixes #53.
* vfs+syscall: Flatten nested control flowHimbeer2024-07-252-138/+147
| | | | Fixes #54.
* vfs: Make callbacks to provide or remove resources optional for DirHooksHimbeer2024-07-243-12/+27
|
* vfs: Require listing implementation for DirHooksHimbeer2024-07-242-1/+6
|
* syscall: Update provideFile signature to new OpenFn-less context systemHimbeer2024-07-211-4/+6
|
* vfs: Fix File.closeFn callback not being invoked if the file is provided by ↵Himbeer2024-07-211-1/+6
| | | | the kernel (builtin resource)
* vfs: Fix File.closeFn callback not being calledHimbeer2024-07-211-0/+7
|
* vfs: Don't set FileContext.inner initially but provide FileContext.initializerHimbeer2024-07-212-6/+8
| | | | This allows file providers to know whether an interaction is the first one made with a specific resource descriptor.
* process: Switch to kernel page table before (potentially) unmapping current ↵Himbeer2024-07-212-1/+10
| | | | | | page table on termination Fixes hanging with high CPU usage on process termination.
* process: Increment PID after creating a processHimbeer2024-07-211-0/+2
| | | | Previously all processes shared the same ID because of this bug.
* resources: Fix /process/create executable buffer length not being expanded ↵Himbeer2024-07-211-0/+6
| | | | | | after initial resource read It is now possible to start other programs successfully.
* sbi: Rename Unknown error to SbiUnknown to distinguish it from an error not ↵Himbeer2024-07-212-4/+4
| | | | mapped to a status code
* resources: Fix zero-length buffer being passed to readHookedHimbeer2024-07-211-6/+35
|
* resources: Fix integer overflow due to using tar files after iterationHimbeer2024-07-211-7/+18
|
* vfs: Get rid of File OpenFn callbackHimbeer2024-07-213-29/+38
| | | | Context initialization is now left to the provider, allowing the kernel itself to interact with resources of this kind.
* vfs: Support reading and writing filesHimbeer2024-07-211-14/+53
|
* resources: Fix userinit inode names pointing to undefined stack memoryHimbeer2024-07-211-5/+5
| | | | Userinit contents can now be accessed successfully without getting a NotFound error for resources whose names got corrupted.
* vfs: Support opening hooks provided by the kernelHimbeer2024-07-212-9/+27
|
* resources: Enable user memory access temporarily for /process/create path ↵Himbeer2024-07-201-1/+6
| | | | reading
* resources: Add /process/self/{id,thread_id} VFS hooksHimbeer2024-07-201-0/+30
|
* resources: Add /process/create VFS hookHimbeer2024-07-201-2/+112
|
* vfs: Add limited abilities to interact with U-mode-provided resources from ↵Himbeer2024-07-202-15/+32
| | | | | | within the kernel This is required for VFS-based process creation.
* process: Add allowResume convenience function to increment the program ↵Himbeer2024-07-201-0/+5
| | | | counter and restore the process to the 'waiting' state
* mem: Annotate page_allocator with explicit Allocator typeHimbeer2024-07-201-1/+1
| | | | This makes it possible to use the allocator in some code locations that would otherwise require local type annotations.
* vfs: Offer low-level readHooked and writeHooked ResourceDescriptor methodsHimbeer2024-07-202-4/+18
|
* syscall: Replace terminate() with /process/self/terminate VFS hookHimbeer2024-07-175-14/+55
|
* rethooks: Move functions from Container struct(s) into their own file (for ↵Himbeer2024-07-172-11/+13
| | | | readability)
* vfs: Check for path collisions, performing a reclaim if allowedHimbeer2024-07-172-0/+18
| | | | | | Fixes #49. Does not apply to directory hooks because of design issues that need to be resolved first.
* process: Detach or orphan provided resources on terminationHimbeer2024-07-175-24/+113
| | | | Fixes #42.
* process: Deinitialize resource descriptors on terminationHimbeer2024-07-171-8/+4
| | | | Fixes #38.
* process: Enforce W^X on ELF memory regionsTheodorSmall2024-07-162-0/+7
| | | | Fixes #46.
* sbi: Add new error variants INVALID_STATE and BAD_RANGETheodorSmall2024-07-122-0/+10
| | | | Fixes #47.
* resources: Page-translate user buffer before passing it to OpenSBIHimbeer2024-07-121-1/+11
|
* vfs: Fix read and write operations panicking for kernel-provided resourcesHimbeer2024-07-121-4/+12
| | | | Fixes #48.