583504ebe0
Kernel: Inode rename directory functions
2023-07-10 11:48:11 +03:00
b354b77f8b
Kernel: Mark Ext2 classes final
2023-07-10 11:48:11 +03:00
19dab08275
Kernel: add more functionality to PCI
2023-07-09 23:04:11 +03:00
78c091f7f8
Kernel: Move open file descriptors to their own class
...
This simplifies code a lot :)
2023-07-07 23:11:37 +03:00
a549336530
Kernel/LibC: add basic dup2
2023-07-06 23:17:54 +03:00
4eb95c963d
Kernel/LibC: Add basic pipe() syscall and command
...
You can now create pipes :)
2023-07-06 22:16:26 +03:00
3c068aa0ae
Kernel/LibC: add clock_gettime() for CLOCK_MONOTONIC
...
This gets the number of milliseconds since boot
2023-07-06 00:38:29 +03:00
86df258365
Kernel: rework the whole PageTable structure
...
We now have page table structure for kernel memory which is shared
between all processes.
2023-07-05 23:41:35 +03:00
0d620f3e0f
Kernel: Rewrite and optimize DiskCache
...
DiskCache now consists of PageCaches which are caches of contiguous
sectors. This allows the disk cache to be ordered and faster traversal.
We seem to have a problem somewhere during reading. The stack gets
corrupted.
2023-06-19 10:31:47 +03:00
5e123031aa
Kernel: kmalloc has now somewhat dynamic storage
...
Allocations bigger than PAGE_SIZE and those not forced to be identity
mapped are now done on a GeneralAllocator. This allows us to use kmalloc
for big allocations; bigger than the fixed 1 MiB storage.
This is still a hack and the whole kmalloc will have to be rewritten at
some point, but for now this does the job :D
2023-06-18 23:27:00 +03:00
388f530edd
Kernel: Add GeneralAllocator::paddr_of
...
Yoy can now query physical address of a virtual address for general
allocator allocation
2023-06-18 23:25:51 +03:00
714305ef56
Kernel: General allocator takes first valid vaddr as parameter
2023-06-17 22:23:34 +03:00
32e1473c94
Kernel: Make disk IO blocking thread safe
...
This was causing a lot of deadlocks on vms without kvm accel
2023-06-12 18:57:47 +03:00
bf617036c7
Kernel: Rework syscall calling
...
I removed the intermediate function when calling syscalls. Now syscall
handler calls the current process automatically. Only exception is
sys_fork, since it needs a assembly trampoline for the new thread.
2023-06-12 14:16:48 +03:00
ce55422a24
Kernel: Remove Shell from kernel
...
This is now obsolete since we have a userspace Shell.
2023-06-12 02:04:52 +03:00
0f63cfa43f
Kernel/LibC: add SYS_{SET,GET}_PWD and chdir, getpwd
2023-06-12 02:02:52 +03:00
b254ade69b
Kernel: Add SYS_GET_{,E}{UID,GID}
2023-06-11 22:37:00 +03:00
ef4ebaa969
Kernel: Add syscalls for set{,e,re}{uid,gid}
2023-06-11 22:37:00 +03:00
c62e820bcf
Kernel: Add basic Credentials for the system
...
Now filesystem access/open, etc confirm that you have access for rwxs
2023-06-11 20:06:06 +03:00
5aed186827
Kernel: Add SYS_OPENAT
2023-06-11 03:29:22 +03:00
e209ca7c82
Kernel: Rewrite directory listing so it can be integrated to libc
2023-06-11 00:17:18 +03:00
db49cbd6e2
Kernel: We now store the processes exit code
2023-06-10 17:31:56 +03:00
27cef23823
Kernel: Scheduler now has reschedule()
...
This can be called from anywhere and just causes the scheduler to
schedule the next thread. This is more efficient and verbose version
of Scheduler::set_current_thread_sleeping(0), since we don't have
to wake other threads or do other verifications.
2023-06-09 00:47:17 +03:00
b7fc2dc3d0
Kenrel: Rename Scheduler::reschedule -> Scheduler::timer_reschedule
2023-06-09 00:41:43 +03:00
8af390e0f6
Kernel: Big commit. Rewrite ELF loading code
...
We now load ELF files to VirtualRanges instead of using kmalloc.
We have only a fixed 1 MiB kmalloc for big allocations and this
allows loading files even when they don't fit in there.
This caused me to rewrite the whole ELF loading process since the
loaded ELF is not in memory mapped by every process.
Virtual ranges allow you to zero out the memory and to copy into
them from arbitary byte buffers.
2023-06-09 00:37:43 +03:00
96d6453ea8
Kernel: PageTableScope locks the PageTable before disabling interrupts
...
This allows replacing some PageTableScopes with PageTable::lock()
2023-06-09 00:34:41 +03:00
86f58f60cb
LibC: implement setenv, unsetenv, putenv
2023-06-05 22:51:02 +03:00
064ce568c2
Kernel: add basic support for environment variables
...
exec functions will search files from PATH
2023-06-05 22:51:02 +03:00
0b1b4d8f7e
Kernel: exec now has better posix errors
2023-06-05 21:12:08 +03:00
b0e9ab0519
Kernel/LibC: pass environ pointer to process
2023-06-05 21:12:08 +03:00
5425394880
Kernel: TTY now supports CSI s and u
...
These are commonly supported values to save and load cursor
position
2023-06-05 18:19:13 +03:00
9d64dbd5c2
Kernel/LibC: add SYS_STAT and stat(), lstat()
2023-06-05 14:37:14 +03:00
b68d5a5833
Kernel: Add SYS_WAIT
...
This syscall waits for a given pid.
2023-06-04 18:00:52 +03:00
924fc2118c
Kernel: Allocators are now stored in UniqPtr
...
This allows proper memory management, we had some memory leak
2023-06-04 01:25:57 +03:00
51f4c0c750
Kernel: make load_elf() its own function
2023-06-04 01:24:11 +03:00
37b93da650
Kernel: PhysicalRange maps its nodes to kernel vaddr space
...
This keeps the lower half of address space cleaner
2023-06-04 01:20:47 +03:00
8352392b38
Kernel: You can specify first vaddr for getting free pages
2023-06-04 01:15:48 +03:00
dc1aff58ed
Kernel: PAGE_FLAG_MASK is now only 0xF
...
We don't care currenly about anything but the last few bits
2023-06-03 20:08:13 +03:00
9f75d9cfe5
Kernel: PageTable now has debug_dump
...
This dumps all the mapped pages and their flags
2023-06-03 20:08:13 +03:00
a4cb5d8360
Kernel: Inode/Device detection is done with overridden bool functions
2023-06-03 13:28:15 +03:00
59b807189f
Kernel: add basic disk cache
...
ATADevices now add disk cache to themselves
2023-06-03 02:23:14 +03:00
fb1c7015b1
Kernel: Shell 'memory' now prints heap memory usage
2023-06-03 02:22:18 +03:00
4d4d0e26a9
Kernel: Symlinks are now working
...
We still have to implement loop or depth detection
2023-06-02 11:43:46 +03:00
232fdcb82c
Kernel: add basic support for symlinks
2023-06-01 00:24:45 +03:00
4da1d6fd27
Kernel: Implement Process::exec()
2023-05-31 20:56:29 +03:00
909e847369
Kernel: Move userspace entry functions to Process instead of Thread
2023-05-31 19:31:10 +03:00
ed0dcacab3
Kernel: Move V2P and P2V to Memory/Types.h
2023-05-30 23:57:03 +03:00
57f7da6ce1
Kernel: Booting with higher half kernel gets to Heap initialization
2023-05-30 22:21:12 +03:00
e640344d7a
Kernel: Rename MMU to PageTable
...
This is more descriptive name for what it actually represents
2023-05-29 21:06:09 +03:00
7151bb86a8
Kernel/LibC: opening standard files is done in libc
2023-05-29 20:21:19 +03:00