[PATCH 05/10] AXFS: axfs_profiling.c
arnd at arndb.de
Thu Aug 21 11:50:44 EDT 2008
On Thursday 21 August 2008, Jared Hulbert wrote:
> So /sys/kernel/debug/axfs/volume0 would work?
> > 4) no profiling at all
> > The profiling code has certainly been useful to you during development,
> > and you should keep that code around for your own work on it,
> > but maybe you should not push that upstream, because regular users
> > are not going to need it.
> Nope. Profiling is absolutely fundamental to how AXFS works. Read
> the [PATCH 00/10] thread again.
Ok, understood it now. So it actually is a stable interface into
the file system, which means that debugfs might not be the best
I need to think about this some more. So far none of the options
are perfect. What I can think of so far includes:
1. An ioctl on the mount point of the fs
2. An ioctl that you need to call on each file
3. sysfs files is /sys/fs/axfs/
4. A new virtual file system to be mounted to /sys/fs/axfs/
5. A file below the device in sysfs, e.g. /sys/block/mtdblk0/axfs-profile
I've also taken a look at the format of the profiling data file.
I'm not sure that it is ideal if you want to be able to share
identical data blocks between files. Do you currently do that
in your mkfs? The fs format certainly allows it. I would expect
that if you checksum each page, you can find duplicates on a page
basis and save some space this way. However, it can make profiling
harder if you count based on blocks but report the data based on
the file name. Not sure what a better solution would look like.
More information about the linux-mtd