Whamcloud - gitweb
LU-17337 osd: ask for more revoke credits
authorAlex Zhuravlev <bzzz@whamcloud.com>
Tue, 5 Dec 2023 05:20:58 +0000 (08:20 +0300)
committerAndreas Dilger <adilger@whamcloud.com>
Thu, 7 Dec 2023 11:10:43 +0000 (11:10 +0000)
commit4eb7b73945f77b41eef5649d485deecd5a1baa43
tree2d09e52278c3d42cc5a946c495b5faed7b7a8647
parent9355d26a7f637859d21f3d0fc4cd2338bdef6892
LU-17337 osd: ask for more revoke credits

starting from 4.* kernels JBD2 tracks number of potential
revoked blocks separately from regular journal blocks and
checks a transaction doesn't exceed the declared number.
before extent merging patch a regular block allocation could
free only very limited number of blocks. now with extent
merging when an extent tree is really big and few extents
are inserted in a single transaction, then such an allocation
can exceed default revoke credits (8).
the patch uses number of extent in the transaction to calculate
potential number of revoke records (max tree depth * default).

Fixes: 0f7e6c02a9 ("LU-16843 ldiskfs: merge extent blocks")
Signed-off-by: Alex Zhuravlev <bzzz@whamcloud.com>
Change-Id: I4967deb56e5aba82b68ffdc91de589fffae6a64a
Reviewed-on: https://review.whamcloud.com/c/ex/lustre-release/+/53325
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Li Dongyang <dongyangli@ddn.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
lustre/osd-ldiskfs/osd_handler.c
lustre/osd-ldiskfs/osd_internal.h