From 0939a0576bb88829f1534fc41b7e3a642ac2ecf3 Mon Sep 17 00:00:00 2001 From: Johann Lombardi Date: Fri, 28 Sep 2012 22:46:12 +0200 Subject: [PATCH] LU-2047 obdfilter: init glimpse desc to NULL for ext lock There is no glimpse descriptor when glimpsing extent locks, we should thus set ldlm_glimpse_work::gl_desc to NULL to allocate glimpse request with the correct format. Signed-off-by: Johann Lombardi Change-Id: I5cdedfb79631328114ef7b0bc8e035dde985b4fa Reviewed-on: http://review.whamcloud.com/4127 Tested-by: Hudson Reviewed-by: Fan Yong Reviewed-by: Niu Yawei Tested-by: Maloo Reviewed-by: Oleg Drokin --- lustre/obdfilter/filter.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lustre/obdfilter/filter.c b/lustre/obdfilter/filter.c index 82ba461..e213d3e 100644 --- a/lustre/obdfilter/filter.c +++ b/lustre/obdfilter/filter.c @@ -1829,6 +1829,9 @@ static int filter_intent_policy(struct ldlm_namespace *ns, /* The glimpse callback is sent to one single extent lock. As a result, * the gl_work list is just composed of one element */ cfs_list_add_tail(&gl_work.gl_list, &gl_list); + /* There is actually no need for a glimpse descriptor when glimpsing + * extent locks */ + gl_work.gl_desc = NULL; /* the ldlm_glimpse_work structure is allocated on the stack */ gl_work.gl_flags = LDLM_GL_WORK_NOFREE; -- 1.8.3.1