On Thu, Aug 8, 2013 at 3:55 AM, Greg Freemyer <greg.freemyer@xxxxxxxxx> wrote: > On Wed, Aug 7, 2013 at 6:07 PM, Greg Freemyer <greg.freemyer@xxxxxxxxx> wrote: >> On Tue, Aug 6, 2013 at 11:06 AM, Sankar P <sankar.curiosity@xxxxxxxxx> wrote: >>>> One recommendation: add support for page-cache. Start with read-cache >>>> only, and then mmap support, you need that to allow binary execution. >>>> >>> >>> oh okay. You suggest that I should do this before I start implementing >>> the support for extents ? >>> >>> Sankar >> >> Sankar, >> >> Do a strace on just about any program and you will see mmap is used >> heavily. Extents is an internal nicety, but mmap is core >> functionality that you would need even on a simpleFS for an embedded >> system. > > I just read your todo's. > > Multi-block files should come before extents and/or mmap support. I > guess you realize that ext2 and ext3 are NOT extent based filesystems. > ext4 is the first extent based one. > > So its: > ext2 - block based filesystem > ext3 - block based with a journal > ext4 - extent based with a journal > > In reality the current ext4 driver has a matrix of supported features. > There are flag bits which tell you which features a specific > filesystem instance supports. You may want to atleast look at those > feature flags to get an idea of the kinds of features ext4 supports. > > If you don't have lseek() support for read, you need to get it added. > lseek() is pretty trivial for reads so there is not much reason not to > have it as the very next step. > > For write, it means you have to implement a read/modify/write cycle in > your filesystem. I gather you don't have that. > > With just those todo's I go in this order: > > - lseek() support with read (trivial) > - partial block write support (requires read/modify/write logic, so not trivial) > - lseek() support for write (trivial now you have partial block write support) > - multi-block support, requires a major refactor most likely. > Thank you so much for the detailed response. I will go in this order as this seem to be logically progressive nicely iiuc. When do you think I should bring in support for mmap and page-caching that Rajat in the above plan ? Thanks. -- Sankar P http://psankar.blogspot.com _______________________________________________ Kernelnewbies mailing list Kernelnewbies@xxxxxxxxxxxxxxxxx http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies