]> www.infradead.org Git - users/jedix/linux-maple.git/commit
xfs: disallow rw remount on fs with unknown ro-compat features
authorEric Sandeen <sandeen@redhat.com>
Tue, 5 Apr 2016 21:05:41 +0000 (07:05 +1000)
committerDhaval Giani <dhaval.giani@oracle.com>
Fri, 20 Jan 2017 22:21:52 +0000 (17:21 -0500)
commita4e013b070da9c2d14a16c0ecbf519203dab4774
tree20f9034480f053eba445947f2d830dbca46f8ebb
parent794d839b5ef8a640617d468a51b78cd2b1f5cfbd
xfs: disallow rw remount on fs with unknown ro-compat features

Orabug: 25256914

[ Upstream commit d0a58e833931234c44e515b5b8bede32bd4e6eed ]

Today, a kernel which refuses to mount a filesystem read-write
due to unknown ro-compat features can still transition to read-write
via the remount path.  The old kernel is most likely none the wiser,
because it's unaware of the new feature, and isn't using it.  However,
writing to the filesystem may well corrupt metadata related to that
new feature, and moving to a newer kernel which understand the feature
will have problems.

Right now the only ro-compat feature we have is the free inode btree,
which showed up in v3.16.  It would be good to push this back to
all the active stable kernels, I think, so that if anyone is using
newer mkfs (which enables the finobt feature) with older kernel
releases, they'll be protected.

Cc: <stable@vger.kernel.org> # 3.10.x-
Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Reviewed-by: Bill O'Donnell <billodo@redhat.com>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
(cherry picked from commit 9c153a82fb6f9a177d0ec2034005b4245973a28f)
Signed-off-by: Dhaval Giani <dhaval.giani@oracle.com>
fs/xfs/xfs_super.c