Simple framework for developing filesystems in userspace

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
tretornesp
Posts: 18
Joined: Mon Aug 15, 2022 12:30 pm

Simple framework for developing filesystems in userspace

Post by tretornesp »

Hello there.

As I found a lot of trouble porting FatFS to my kernel I decided to create my
own implementation of the filesystems (Fat32 and Ext2) that I plan to support.

For that task, I decided to invest a few days in developing a framework to test
the FS in userspace before running them on the kernel (for sake of my own sanity)

As a way to contribute a bit to this awesome community, I'm posting the code:

https://github.com/TretornESP/FUSED

The aim is to emulate a FatFS-enabled disk driver but supported by a raw file. The development roadmap is:

- Basic primitives (Read, Write, Startup, Status and IOCTL)
- Lazy mode loading for the files (currently it just mmaps it, which is a bad idea for big files)
- Buffer cache emulation (probably just introducing preconfigured delays on a miss, open to ideas)
- SSD Wear emulation (gathering stats)

In case you decide to give it a try, please don't doubt in asking any questions, I will gladly assist you!

Thank you all!
Post Reply