From ba60084a3959a01a13d35a915f6565f9c8c7b4bc Mon Sep 17 00:00:00 2001 From: "Alexander.Zarochentsev" Date: Tue, 15 Jun 2010 23:00:15 +0400 Subject: [PATCH] b=22755 check for OBD_CONNECT_GRANT_SHRINK in osc_should_shrink_grant a=johann i=oleg.drokin i=di.wang --- lustre/osc/osc_request.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lustre/osc/osc_request.c b/lustre/osc/osc_request.c index 157031b..b81d8d3 100644 --- a/lustre/osc/osc_request.c +++ b/lustre/osc/osc_request.c @@ -1020,6 +1020,11 @@ static int osc_should_shrink_grant(struct client_obd *client) { cfs_time_t time = cfs_time_current(); cfs_time_t next_shrink = client->cl_next_shrink_grant; + + if ((client->cl_import->imp_connect_data.ocd_connect_flags & + OBD_CONNECT_GRANT_SHRINK) == 0) + return 0; + if (cfs_time_aftereq(time, next_shrink - 5 * CFS_TICK)) { if (client->cl_import->imp_state == LUSTRE_IMP_FULL && client->cl_avail_grant > GRANT_SHRINK_LIMIT) -- 1.8.3.1