Whamcloud - gitweb
LU-2047 obdfilter: init glimpse desc to NULL for ext lock
authorJohann Lombardi <johann.lombardi@intel.com>
Fri, 28 Sep 2012 20:46:12 +0000 (22:46 +0200)
committerOleg Drokin <green@whamcloud.com>
Sat, 29 Sep 2012 16:09:18 +0000 (12:09 -0400)
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 <johann@whamcloud.com>
Change-Id: I5cdedfb79631328114ef7b0bc8e035dde985b4fa
Reviewed-on: http://review.whamcloud.com/4127
Tested-by: Hudson
Reviewed-by: Fan Yong <yong.fan@whamcloud.com>
Reviewed-by: Niu Yawei <niu@whamcloud.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>

index 82ba461..e213d3e 100644 (file)
@@ -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;