]> git.baikalelectronics.ru Git - kernel.git/commit
xfs: don't assume a left rmap when allocating a new rmap
authorDarrick J. Wong <darrick.wong@oracle.com>
Tue, 17 Jul 2018 21:24:11 +0000 (14:24 -0700)
committerDarrick J. Wong <darrick.wong@oracle.com>
Tue, 17 Jul 2018 21:25:57 +0000 (14:25 -0700)
commit6b1934e81551fa28c399913ca2bbea5f0c41f927
treea227802bfbef395c314472808c2f3f878daee9e0
parent6576702a17251611a4757fd06e6adb9fc15c016d
xfs: don't assume a left rmap when allocating a new rmap

The original rmap code assumed that there would always be at least one
rmap in the rmapbt (the AG sb/agf/agi) and so errored out if it didn't
find one.  This assumption isn't true for the rmapbt repair function
(and it won't be true for realtime rmap either), so remove the check and
just deal with the situation.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Allison Henderson <allison.henderson@oracle.com>
fs/xfs/libxfs/xfs_rmap.c