From: "Marcus Hüwe" <suse-tux@gmx.de>
To: "Darrick J. Wong" <darrick.wong@oracle.com>
Cc: linux-ext4@vger.kernel.org
Subject: Re: [PATCH] e2undo: fix endian issues
Date: Fri, 17 Jun 2016 09:24:56 +0200 [thread overview]
Message-ID: <20160617072456.m3t2xopwomzcfcgm@linux> (raw)
In-Reply-To: <20160616230510.GC5724@birch.djwong.org>
On 2016-06-16 16:05:10 -0700, Darrick J. Wong wrote:
> On Thu, Jun 16, 2016 at 05:51:04PM -0500, Eric Sandeen wrote:
> > Two new e2undo issues exist in the latest release on big endian
> > machines.
> >
> > From sparse check:
> >
> > undo_io.c:157:26: warning: invalid assignment: |=
> > undo_io.c:157:26: left side has type restricted __le32
> > undo_io.c:157:26: right side has type int
> > undo_io.c:161:26: warning: invalid assignment: &=
> > undo_io.c:161:26: left side has type restricted __le32
> > undo_io.c:161:26: right side has type int
> >
> > e2undo.c:211:16: warning: cast to restricted __le64
> > e2undo.c:211:16: warning: cast from restricted blk64_t
> > e2undo.c:212:16: warning: cast to restricted __le64
> > e2undo.c:212:16: warning: cast from restricted blk64_t
> >
> > Addresses-RedHat-Bugzilla: 1344636
> > Signed-off-by: Eric Sandeen <sandeen@redhat.com>
> > ---
> >
> > diff --git a/lib/ext2fs/undo_io.c b/lib/ext2fs/undo_io.c
> > index f921218..776d5b8 100644
> > --- a/lib/ext2fs/undo_io.c
> > +++ b/lib/ext2fs/undo_io.c
> > @@ -154,11 +154,11 @@ struct undo_private_data {
> > #define E2UNDO_FEATURE_COMPAT_FS_OFFSET 0x1 /* the filesystem offset */
> >
> > static inline void e2undo_set_feature_fs_offset(struct undo_header *header) {
> > - header->f_compat |= E2UNDO_FEATURE_COMPAT_FS_OFFSET;
> > + header->f_compat |= ext2fs_le32_to_cpu(E2UNDO_FEATURE_COMPAT_FS_OFFSET);
> > }
> >
> > static inline void e2undo_clear_feature_fs_offset(struct undo_header *header) {
> > - header->f_compat &= ~E2UNDO_FEATURE_COMPAT_FS_OFFSET;
> > + header->f_compat &= ~ext2fs_le32_to_cpu(E2UNDO_FEATURE_COMPAT_FS_OFFSET);
> > }
>
> (I don't remember the fs_offset patch going to the list?)
>
No, I sent it directly to Ted - but I was told to CC the list in the
future. Sorry for that...
Marcus
next prev parent reply other threads:[~2016-06-17 7:25 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-16 22:51 [PATCH] e2undo: fix endian issues Eric Sandeen
2016-06-16 23:05 ` Darrick J. Wong
2016-06-17 7:24 ` Marcus Hüwe [this message]
2016-06-22 3:11 ` Theodore Ts'o
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160617072456.m3t2xopwomzcfcgm@linux \
--to=suse-tux@gmx.de \
--cc=darrick.wong@oracle.com \
--cc=linux-ext4@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).