e9b7cf332d
Kernel: Implement directory creation for RamFS
2023-10-25 19:41:34 +03:00
4ee2f0f789
Kernel: Implement Ext2 directory creation
2023-10-25 19:37:04 +03:00
18e90d305d
Kernel: Add Inode API for creating directories
2023-10-25 19:36:04 +03:00
fd1b331b86
Kernel: Ext2FS now uses Ext2Inodes as cached values
2023-10-25 19:34:00 +03:00
627b8cc140
Kernel/LibC: implement chmod syscall + libc wrapper
2023-10-25 02:35:37 +03:00
f3d9da9549
Kernel: Rewrite all read/write functions to use BAN::ByteSpan
...
This allows us to not work with raw pointers and use sized containers
for reading and writing.
2023-10-24 11:56:00 +03:00
f21d4e794c
Kernel: Rework whole ATA driver structure
...
Make ATA driver more compatible when we are adding SATA support
2023-10-08 02:50:23 +03:00
39bc6c43dc
Kernel: Expose command line and environment to /proc
2023-09-30 23:01:33 +03:00
785de5f9b9
Kernel: /proc/{pid}/meminfo now reports per process memory usage
2023-09-30 21:20:18 +03:00
8f630a97df
Kernel: Add procfs that contains only pids
2023-09-30 21:19:36 +03:00
9f0797047f
Kernel/LibC: dirent now contains file type
2023-09-30 20:46:57 +03:00
e8a0eeb0b4
Kernel: RamInode verifies that you have not specified mode type
...
This is kinda weird behaviour, but it ensures the user cannot
create e.g. CharacterDevice with mode having IFLNK.
The Inode overrider is the only one setting the mode.
2023-09-30 20:46:57 +03:00
3e5645d453
Kernel: Add API for RamDirectoryInodes to delete containing inodes
2023-09-30 19:22:30 +03:00
2301654c4e
Kernel: Rework RamInode API
...
RamInode is now a general RamInode with no data. RamFileInode is now
a inode for regular files. This is much cleaner and more intuitive
since there is no reason for most non-regular inodes to hold data
Vector.
2023-09-30 19:22:30 +03:00
43c23db4a6
Kernel: Implement MAP_SHARED for regular files
...
Every inode holds a weak pointer to shared file data. This contains
physical addresses of pages for inode file data. Physical addresses
are allocated and read on demand.
When last shared mapping is unmapped. The inodes shared data is freed
and written to the inode.
2023-09-29 18:59:20 +03:00
1e6930a3bc
Kernel: SYS_SYNC now schedules sync to happen soon
...
You can pass non-zero argument to the syscall to block until the
sync has finished.
2023-09-27 00:34:00 +03:00
9d55cf1d80
Kernel: Ext2 inodes are now stored in cache
...
This allows faster inode access and ensures working inodes when
opened in multiple places.
2023-09-25 20:31:40 +03:00
669b2ace4e
Kernel: Ext2 filesystem now holds 10 preallocated block buffers
...
Inodes can query blocks from this buffer. This allows allocation of
blocks to not fail during normal operations. Also less stress on
kmalloc.
2023-09-25 14:32:25 +03:00
0e67c6318b
Kernel: Fix ext2 block allocation
...
Redo ext2 block allocation. This is now much "cleaner" although
I'm not too fond of the macros.
2023-09-25 13:17:44 +03:00
63dc2b6aa6
Kernel: Implement SYS_SYNC and add sync executable to userspace
...
You can (and have to) manually sync disk after writes to it.
2023-09-11 01:26:27 +03:00
921d95d18f
All: Clear lines with only whitspace in them
2023-09-10 00:31:42 +03:00
dd9af56e21
Kernel: Start work on making inodes more thread safe
...
All inode operations are now locked and thread blocked
2023-09-10 00:31:42 +03:00
ba7e1b9ca5
Kernel: Add /dev/tty symlink that targets the current tty
2023-09-05 01:07:52 +03:00
f0772e385c
Kernel: Implement basic RamSymlinkInode
2023-09-05 01:07:52 +03:00
323de3c866
Kernel: Rework whole Terminal structure
...
Serial monitors can now be used as a output. This requires editing
init code for the stdio opening. Serial input is not supported, so qemu
still needs graphical window for ps/2 keyboard.
2023-09-04 19:34:18 +03:00
b2139c0b1e
Kernel: Add basic support for O_NONBLOCK (only for tty)
2023-09-04 12:57:52 +03:00
a711462ef4
Kernel: Split ext2 implementation to multiple files
2023-09-01 15:10:23 +03:00
f31c6b847f
Kernel: Start work on writable ext2 filesystem
2023-08-31 23:40:31 +03:00
195ccf4f53
Kernel: Add missing ififo() to Inode::Mode
2023-08-31 21:38:31 +03:00
cd64c1cfec
Kernel: add is_tty() to inode
2023-07-24 22:19:59 +03:00
08cd285ca6
Kernel: move Device.h to its own directory
2023-07-19 23:55:38 +03:00
9bcfb34524
Kernel: Rewrite whole device structure
...
We now have DevFileSystem which is derived from RamFileSystem. All
devices are RamInodes. We don't have separate DeviceManager anymore.
To iterate over devices, you can loop througn every inode in devfs.
2023-07-10 23:17:14 +03:00
ee4ef6638c
Kenrel: RamInode now implements truncate()
2023-07-10 16:07:09 +03:00
d6408bcf17
Kernel: add O_TRUNC
...
this is not supported by anything yet
2023-07-10 15:48:18 +03:00
89d4fa4d9b
Kernel: Ext2 fill now return ENOTSUP on write
...
We used to crash the kernel
2023-07-10 15:34:25 +03:00
a0ecbed726
Kernel: You can now read/write to RamInodes
...
RamFS should be stored on physical pages and not in kmalloc, but
that will be implemented later :)
2023-07-10 14:09:35 +03:00
74fc0aa308
Kernel: Inode::create_file() now takes uid and gid as parameters
2023-07-10 13:32:10 +03:00
d5f0448e48
Kernel: start work on ram file system
2023-07-10 13:26:14 +03:00
d713f252aa
Kenrel: Fix inode comparison
...
We should not compare rdevs
2023-07-10 11:48:11 +03:00
5ec2d85081
Kernel: Inode rename directory functions
2023-07-10 11:48:11 +03:00
0d132ee518
Kernel: Mark Ext2 classes final
2023-07-10 11:48:11 +03:00
4cd72992c8
Kernel/LibC: Add basic pipe() syscall and command
...
You can now create pipes :)
2023-07-06 22:16:26 +03:00
c7ec19c25c
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
01311b470f
Kernel: Rewrite directory listing so it can be integrated to libc
2023-06-11 00:17:18 +03:00
9228df0f23
Kernel: Inode/Device detection is done with overridden bool functions
2023-06-03 13:28:15 +03:00
7bbdee6cc4
Kernel: Symlinks are now working
...
We still have to implement loop or depth detection
2023-06-02 11:43:46 +03:00
835d32814d
Kernel: add basic support for symlinks
2023-06-01 00:24:45 +03:00
cfa025acae
BAN: Move RefPtr to its own file and create New.h
...
New.h contains definitions for placement new operators and
BAN::allocator and BAN::dealloctor
2023-04-10 21:07:25 +03:00
7f95444bb5
Kernel: Start work on making tty a file
...
TTY is now a file that you can read from/write to. I still have
to port shell to use this new interface
2023-04-05 00:56:09 +03:00
783842bac2
Kernel: add virtual write function to inode
2023-04-03 20:29:07 +03:00