Sure. I will look at your CRC patchset and see what changes are needed
Meantime, you can answer my dilemma with the change in fs_quota_stat
(see patch 4).
As per your suggestion, I changed the data structure, to include pads at
relevant places in the data structure, which also means that the new
modified structure is not compatible with older user space code.
So, I created a copy of the older structure (fs_quota_stat_v1) and used
that if the user space request has older structure. So, now the new
kernel code is backward compatible with the old (already running) user
space code. All is well till now....
Now, I make the changes to the user space code so as to use the new
fs_quota_stat. Since the data structure has changed, the new user space
code will not work with the old kernel code.
This is where I have the dilemma.
1. Leave the user space code to work only with the newer version,
breaking the compatibility with the older kernel (with an error
2. Read the superblock, and if pquotino is _not_ present conclude older
version of fs_quota_stat would suffice for getting quota information
from kernel (note that this will work properly with newer kernel code
too), and use the older version of fs_quota_stat_v1 for quotactl.
3. Any other clever way ? :)
On Fri, 2013-03-22 at 13:02 +1100, Dave Chinner wrote:
> On Thu, Mar 21, 2013 at 04:52:49PM -0500, Chandra Seetharaman wrote:
> > Hello All,
> > This is the version 7 of the changes to allow pquota and gquota to be used
> > together.
> > Patchset applies cleanly on top of 56cea2d088811b8cf7d2893e29bcf369a912de69
> > in xfs git tree.
> > Ran latest xfstests against it.
> As an information point - I've got a separate pquota inode in the
> version 5 superblock format used in the CRC patchset. Given that
> this functionailty requires mkfs/db/repair support, woul dit be
> better to wait until the CRC code goes in and we can then add this
> feature without having to rework the superblock CRC patches around
> i.e. it will always be available on v5 superblocks, or v4
> superblocks when the feature bit is set to indicate the pquota inode
> part of the superblock is valid?