]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commit
xfs: use and update the finobt on inode allocation
authorBrian Foster <bfoster@redhat.com>
Tue, 20 May 2014 21:54:04 +0000 (07:54 +1000)
committerDave Chinner <david@fromorbit.com>
Tue, 20 May 2014 21:54:04 +0000 (07:54 +1000)
commit88fc73063c110659063d4998a028072c90dd4087
treea5371d1ad454cb836c7475293be2fa7379162dc3
parent3c699279577193dcbbe123b45db08dacd717853f
xfs: use and update the finobt on inode allocation

Replace xfs_dialloc_ag() with an implementation that looks for a
record in the finobt. The finobt only tracks records with at least
one free inode. This eliminates the need for the intra-ag scan in
the original algorithm. Once the inode is allocated, update the
finobt appropriately (possibly removing the record) as well as the
inobt.

Move the original xfs_dialloc_ag() algorithm to
xfs_dialloc_ag_slow() and fall back as such if finobt support is
not enabled.

Signed-off-by: Brian Foster <bfoster@redhat.com>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
libxfs/xfs_ialloc.c