From 5bfa3e3150a9de7c97aa6bcb5f9e2c00d1c0e030 Mon Sep 17 00:00:00 2001 From: Alex Zhuravlev Date: Thu, 3 Sep 2015 13:46:11 +0300 Subject: [PATCH] LU-7014 osd: add additional credits for generic IAM delete IAM is different from regular htree used by regular directories. it can recycle and shrink blocks which needs additional credits. Change-Id: I819d26206b158a0e8ef2a9110ba89fe34e5a1925 Signed-off-by: Alex Zhuravlev Reviewed-on: http://review.whamcloud.com/16213 Reviewed-by: Fan Yong Tested-by: Jenkins Tested-by: Maloo Reviewed-by: James Simmons Reviewed-by: Oleg Drokin --- lustre/osd-ldiskfs/osd_handler.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lustre/osd-ldiskfs/osd_handler.c b/lustre/osd-ldiskfs/osd_handler.c index ee45354..b99c079 100644 --- a/lustre/osd-ldiskfs/osd_handler.c +++ b/lustre/osd-ldiskfs/osd_handler.c @@ -3287,8 +3287,9 @@ static int osd_index_declare_iam_delete(const struct lu_env *env, oh = container_of0(handle, struct osd_thandle, ot_super); LASSERT(oh->ot_handle == NULL); + /* Recycle may cause additional three blocks to be changed. */ osd_trans_declare_op(env, oh, OSD_OT_DELETE, - osd_dto_credits_noquota[DTO_INDEX_DELETE]); + osd_dto_credits_noquota[DTO_INDEX_DELETE] + 3); return 0; } -- 1.8.3.1