Re: How to write a file system?

Ingo Molnar (mingo@pc7537.hil.siemens.at)
Thu, 18 Sep 1997 16:00:21 +0200 (MET DST)


On Thu, 18 Sep 1997, Frans Orsel wrote:

> Does anyone have in-depth information on how to write a file system driver?
> I've read the part about file systems in the Kernel Hackers Guide, but it's not
> very detailed.

this isnt very detailed information, but anyway: look at patches which add
a new filesystem. Eg fs/romfs around 2.1.20, or autofs. Cut out the diffs
that add the new filesystem, and change all occurences to your 'newfs'
string. That should give you a good skeleton to start. Try to implement a
filesystem first that has a single inode, and sprintf() some 'Hello World'
string if someone wants to know the content of the inode :)

then add physical layout, more inodes, directories, etc. It's easy ;)

-- mingo