[PATCH 6/6] xfs: pad xfs_attr_leaf_name_remote to avoid tripping on m68k
Christoph Hellwig
hch at infradead.org
Mon Mar 7 10:28:58 CST 2016
On Mon, Mar 07, 2016 at 08:49:50AM +1100, Dave Chinner wrote:
> From: "Darrick J. Wong" <darrick.wong at oracle.com>
>
> Pad the xfs_attr_leaf_name_remote so that we don't trip the structure
> size checker on m68k.
>
> [dchinner: add comment, XFS_ATTR_LEAF_NAME_BYTES constant and make sure
> xfs_attr_leaf_entsize_remote() does the right thing. ]
I think using a small fixed size array as a variable sized array
is not a good idea, especially with increasinly "smart" optimizing
compilers. I'd rather take this structure out the size checking,
and then move it to a C99 VLA instead of the size 1 hack in the long
run.
More information about the xfs
mailing list