[Top] [All Lists]

Re: [PATCH] fix dir2 shortform structures on ARM old ABI

To: xfs@xxxxxxxxxxx
Subject: Re: [PATCH] fix dir2 shortform structures on ARM old ABI
From: "Andre Draszik" <xfs@xxxxxxxxxx>
Date: Tue, 18 Mar 2008 23:49:11 +0000
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:sender:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition:x-google-sender-auth; bh=z3zGfl7OGhdyWegRdslcBaUBogAC2LQHelNCVqO1Xeo=; b=PN4bJjMSZnA7F93e+jT80yuuBJInWmRcJ5fQrx1CfXSUS8ijO+pu6T4LEgu5tNbwmny/C2sw3XIBrjsogwmVwHQ6pKa0S5l5yPfStSS+3QEH6CaKOG09qlRgL8odpanp7ZbckKKd3lqIZW2zEgzySezXP4VkHX3jp2mzHwfudlE=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=message-id:date:from:sender:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition:x-google-sender-auth; b=tm5r1KPQDP8ikxZ/ydwW/9yTKDlX2f9qylIRZzJhyyK75AZzLzGXoffoKB/GuNWI4Xz9SluKRCDorLVeWI9IAC1UeSt6wdO8OWp/PmbSHF/zn57XiqAq97h3Hh1lWvC8mkutvQ9ZvBNe3W56wvV93Qf0FwW1rBJdzGv/GxZN6lc=
Sender: xfs-bounce@xxxxxxxxxxx

(I just subscribed, so I can't reply correctly :-(

In fact,, the last two evenings I spent making XFS work on arm eabi,
where things are much better than with the old API, but still XFS
won't work out of the box.

So, Eric, if you go for the #if defined(__arm__) &&
!defined(__ARM_EABI__) approach, arm eabi will still be broken.

EABI basically behaves like other 'normal' arches/abis, but sometimes
structures get padded to have a size of a multiple of 8, i.e. padding
is added at the end of the struct, which as far as I can see for now
affects 5 structs: xfs_dir2_data_entry_t, xfs_dinode_t, xfs_sb_t,
xfs_dsb_t, and xlog_rec_header_t

I must say, I like Jeff's approach of explicitly telling gcc about
alignment much better :-) It makes it a) much easier to find structs
that are in fact representations of on-disk data and thus might need
tweaking, and b) as somebody already said you fix such problems once
and forever.
E.g. for me as an absolute outsider, it was quite time consuming
finding out which structs are actually on-disk.

That said, Jeff, you mentioned that your changes don't work yet
completely - could this be because (at least from the comments) struct
xfs_sb needs to match struct xfs_dsb and you only change xfs_dsb?


<Prev in Thread] Current Thread [Next in Thread>