Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1501526 > unrolled thread

Re: fs/xfs/xfs_ondisk.h:96:2: error: call to '__compiletime_assert_96' declared with attribute error: XFS: sizeof(xfs_dir2_sf_entry_t) is wrong, expected 3

Started byChristoph Hellwig <hch@infradead.org>
First post2016-10-16 18:50 +0200
Last post2016-10-17 16:40 +0200
Articles 2 — 2 participants

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: fs/xfs/xfs_ondisk.h:96:2: error: call to  '__compiletime_assert_96' declared with attribute error: XFS:  sizeof(xfs_dir2_sf_entry_t) is wrong, expected 3 Christoph Hellwig <hch@infradead.org> - 2016-10-16 18:50 +0200
    Re: [kbuild-all] fs/xfs/xfs_ondisk.h:96:2: error: call to  '__compiletime_assert_96' declared with attribute error: XFS:  sizeof(xfs_dir2_sf_entry_t) is wrong, expected 3 Fengguang Wu <fengguang.wu@intel.com> - 2016-10-17 16:40 +0200

#1501526 — Re: fs/xfs/xfs_ondisk.h:96:2: error: call to '__compiletime_assert_96' declared with attribute error: XFS: sizeof(xfs_dir2_sf_entry_t) is wrong, expected 3

FromChristoph Hellwig <hch@infradead.org>
Date2016-10-16 18:50 +0200
SubjectRe: fs/xfs/xfs_ondisk.h:96:2: error: call to '__compiletime_assert_96' declared with attribute error: XFS: sizeof(xfs_dir2_sf_entry_t) is wrong, expected 3
Message-ID<ssWNj-8ii-3@gated-at.bofh.it>

> head:   1001354ca34179f3db924eb66672442a173147dc

That's Linux 4.9-rc1

> 30cbc591 Darrick J. Wong 2016-03-09 @86  	XFS_CHECK_STRUCT_SIZE(xfs_dir2_data_unused_t,		6);

But that's not how xfs_ondisk.h in 4.9-rc1 looks like

> 30cbc591 Darrick J. Wong 2016-03-09 @96  	XFS_CHECK_STRUCT_SIZE(xfs_dir2_sf_entry_t,		3);

And that's line 119.

Something is odd about this report. 

But both xfs_dir2_data_unused_t and xfs_dir2_sf_entry_t have one thing in
common: they are strutures that aren't padded to a natural alignment at
the end.  It seems like the openrisc gcc does implicit padding for them,
which sounds like a nightmware waiting to happen for any sort of disk
or network structure, so I'm really not sure if we should work around
it in xfs.

[toc] | [next] | [standalone]


#1502046 — Re: [kbuild-all] fs/xfs/xfs_ondisk.h:96:2: error: call to '__compiletime_assert_96' declared with attribute error: XFS: sizeof(xfs_dir2_sf_entry_t) is wrong, expected 3

FromFengguang Wu <fengguang.wu@intel.com>
Date2016-10-17 16:40 +0200
SubjectRe: [kbuild-all] fs/xfs/xfs_ondisk.h:96:2: error: call to '__compiletime_assert_96' declared with attribute error: XFS: sizeof(xfs_dir2_sf_entry_t) is wrong, expected 3
Message-ID<sthf4-4Gc-25@gated-at.bofh.it>
In reply to#1501526
Hi Christoph,

On Sun, Oct 16, 2016 at 09:45:56AM -0700, Christoph Hellwig wrote:
>
>
>> head:   1001354ca34179f3db924eb66672442a173147dc
>
>That's Linux 4.9-rc1
>
>> 30cbc591 Darrick J. Wong 2016-03-09 @86  	XFS_CHECK_STRUCT_SIZE(xfs_dir2_data_unused_t,		6);
>
>But that's not how xfs_ondisk.h in 4.9-rc1 looks like

Yeah it's a bit confusing for old errors -- the git blame is on the
old first bad commit, which is

ab9d1e4f7b0217948a3b35a64178602ab30ff45d Merge branch 'xfs-misc-fixes-4.6-3' into for-next

>> 30cbc591 Darrick J. Wong 2016-03-09 @96  	XFS_CHECK_STRUCT_SIZE(xfs_dir2_sf_entry_t,		3);
>
>And that's line 119.
>
>Something is odd about this report.
>
>But both xfs_dir2_data_unused_t and xfs_dir2_sf_entry_t have one thing in
>common: they are strutures that aren't padded to a natural alignment at
>the end.  It seems like the openrisc gcc does implicit padding for them,
>which sounds like a nightmware waiting to happen for any sort of disk
>or network structure, so I'm really not sure if we should work around
>it in xfs.

FYI the error for 'xfs_dir2_sf_entry_t' only shows up in openrisc;
and the 'xfs_attr_shortform_t' error only shows up in cris builds.

There is no errors for 'xfs_dir2_data_unused_t' in recent kernels.

Thanks,
Fengguang

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web