On Mon, May 28, 2001 at 06:41:42AM +0400, Vladimir V. Saveliev wrote:
> > * there is no easy way to tell if a particular stat-data is in v1 or v2
> >   format in link.
> 
> Yes, there is. They have different length.

But this information is not easily available where it's actually used,
in mkdir and link. (you're talking about on-disk structure length,
right?)


> > * save stat-data version number in reiserfs-specific part of the inode.
> >   (e.g. in i_version - we discussed this once before, but for some
> >   reason it was not changed)

Looking at it again, I see that i_version _is_ set, only it's always set
to 1 for directories.

> > Maybe instead of i_version the inode should have a pointer to a
> > version-dependent struct, that can include e.g. MAX_LINKS and others? I
> > suppose if other stat-data versions are invented later on, there will be
> > many things that differ (e.g. a stat-data version without timestamps may
> > make sense?)
> 
> filesystem specific union of struct inode is still almost not used by reiserfs, so,
> we can store there a lot of things like real number of links, etc

real number of links should be stored in the generic part of the inode,
so stat and friends will find it.

But what I suggested was a datastructure that didn't only depend on
filesystem, but on inode items version for this particular inode - it
can hold constants and potentially pointers to functions that differ
from item-version to item-version.


-- 
Ragnar Kjørstad
Big Storage

Reply via email to