Re: Enlarging w/ xfs_growfs: XFS_IOC_FSGROWFSDATA xfsctl failed: Inappropriate ioctl for device

Nick Bowler
2018-12-11T20:20:26Z

On 12/11/18, Nick Bowler <nbowler@draconx.ca> wrote:
> On 12/11/18, Brian Foster <bfoster@redhat.com> wrote:
>> Given that the structure size essentially changes the command value, I'm
>> kind of curious why we have this ifdeffery in the first place. That
>> aside, the patch seems reasonable to me at a glance (though some brief
>> comments around the ifdefs would be nice).
[...]
> Current code has the ifdeffery. Also since it's a syntax error to have
> multiple case labels with the same value it'd be essential to validate
> that all supported architectures architectures end up with different
> values for each XFS_IOC_xyz and the corresponding XFS_IOC_xyz_32.

Right after I write this, I realize that it's almost certainly
the case that architectures which _don't_ define BROKEN_X86_ALIGNMENT
will have matching ioctl numbers between e.g., XFS_IOC_ALLOCSP and
XFS_IOC_ALLOCSP_32. Thus the ifdeffery is essential for the above
syntactic reason.

Cheers,
Nick