]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commit
xfs: perag initialization should only touch m_ag_max_usable for AG 0
authorDarrick J. Wong <darrick.wong@oracle.com>
Mon, 18 Sep 2017 16:42:09 +0000 (09:42 -0700)
committerThadeu Lima de Souza Cascardo <cascardo@canonical.com>
Thu, 16 Nov 2017 13:23:21 +0000 (11:23 -0200)
commite2e1ea3ef51518da2f5f93b86d1864a1b25ee51e
tree4d13705256d97e4ce9fbab6be213c51a1d8b3748
parent15f30c7fd23080d719013741492aad6bc065b3cd
xfs: perag initialization should only touch m_ag_max_usable for AG 0

BugLink: http://bugs.launchpad.net/bugs/1731951
commit 9789dd9e1d939232e8ff4c50ef8e75aa6781b3fb upstream.

We call __xfs_ag_resv_init to make a per-AG reservation for each AG.
This makes the reservation per-AG, not per-filesystem.  Therefore, it
is incorrect to adjust m_ag_max_usable for each AG.  Adjust it only
when we're reserving AG 0's blocks so that we only do it once per fs.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Brian Foster <bfoster@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@canonical.com>
fs/xfs/libxfs/xfs_ag_resv.c