From: Theodore Ts'o <tytso@mit.edu>
To: Jan Kara <jack@suse.cz>
Cc: linux-ext4@vger.kernel.org, Dave Chinner <david@fromorbit.com>,
stable@vger.kernel.org#4.4.x-
Subject: Re: [PATCH 01/11] ext4: Fix xattr shifting when expanding inodes
Date: Thu, 11 Aug 2016 13:32:19 -0400 [thread overview]
Message-ID: <20160811173219.GA10626@thunk.org> (raw)
In-Reply-To: <1470220795-17045-2-git-send-email-jack@suse.cz>
On Wed, Aug 03, 2016 at 12:39:45PM +0200, Jan Kara wrote:
> The code in ext4_expand_extra_isize_ea() treated new_extra_isize
> argument sometimes as the desired target i_extra_isize and sometimes as
> the amount by which we need to grow current i_extra_isize. These happen
> to coincide when i_extra_isize is 0 which used to be the common case and
> so nobody noticed this until recently when we added i_projid to the
> inode and so i_extra_isize now needs to grow from 28 to 32 bytes.
>
> The result of these bugs was that we sometimes unnecessarily decided to
> move xattrs out of inode even if there was enough space and we often
> ended up corrupting in-inode xattrs because arguments to
> ext4_xattr_shift_entries() were just wrong. This could demonstrate
> itself as BUG_ON in ext4_xattr_shift_entries() triggering.
>
> Fix the problem by introducing new isize_diff variable and use it where
> appropriate.
>
> CC: <stable@vger.kernel.org> # 4.4.x-
> Reported-by: Dave Chinner <david@fromorbit.com>
> Signed-off-by: Jan Kara <jack@suse.cz>
Thanks, applied.
- Ted
next prev parent reply other threads:[~2016-08-11 17:32 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-03 10:39 [PATCH 0/11] ext4: Fix inode expansion code Jan Kara
2016-08-03 10:39 ` [PATCH 01/11] ext4: Fix xattr shifting when expanding inodes Jan Kara
2016-08-03 23:25 ` Andreas Dilger
2016-08-04 8:43 ` Jan Kara
2016-08-11 17:32 ` Theodore Ts'o [this message]
2016-08-03 10:39 ` [PATCH 02/11] ext4: Fix xattr shifting when expanding inodes (2) Jan Kara
2016-08-11 17:32 ` Theodore Ts'o
2016-08-03 10:39 ` [PATCH 03/11] ext4: Properly align shifted xattrs when expanding inodes Jan Kara
2016-08-11 17:32 ` Theodore Ts'o
2016-08-03 10:39 ` [PATCH 04/11] ext4: Avoid deadlock when expanding inode size Jan Kara
2016-08-11 17:32 ` Theodore Ts'o
2016-08-03 10:39 ` [PATCH 05/11] ext4: Fixup free space calculations when expanding inodes Jan Kara
2016-08-11 17:33 ` Theodore Ts'o
2016-08-03 10:39 ` [PATCH 06/11] ext4: Check that external xattr value block is 0 Jan Kara
2016-08-11 17:33 ` Theodore Ts'o
2016-08-03 10:39 ` [PATCH 07/11] ext4: Remove checks for e_value_block Jan Kara
2016-08-11 17:33 ` Theodore Ts'o
2016-08-03 10:39 ` [PATCH 08/11] ext4: Replace bogus assertion in ext4_xattr_shift_entries() Jan Kara
2016-08-11 17:33 ` Theodore Ts'o
2016-08-03 10:39 ` [PATCH 09/11] ext4: Factor out xattr moving Jan Kara
2016-08-11 17:33 ` Theodore Ts'o
2016-08-03 10:39 ` [PATCH 10/11] ext4: Remove (almost) unused variables from ext4_expand_extra_isize_ea() Jan Kara
2016-08-11 17:34 ` Theodore Ts'o
2016-08-03 10:39 ` [PATCH 11/11] ext4: Factor out loop for freeing inode xattr space Jan Kara
2016-08-11 17:34 ` 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=20160811173219.GA10626@thunk.org \
--to=tytso@mit.edu \
--cc=david@fromorbit.com \
--cc=jack@suse.cz \
--cc=linux-ext4@vger.kernel.org \
--cc=stable@vger.kernel.org#4.4.x- \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.