Whamcloud - gitweb
LU-170 oscc_grow_count will never grow
authorLiang Zhen <liang@whamcloud.com>
Mon, 28 Mar 2011 16:05:16 +0000 (00:05 +0800)
committerOleg Drokin <green@whamcloud.com>
Wed, 6 Apr 2011 18:19:46 +0000 (11:19 -0700)
commitb9ab6348153fd8d236871f75e5bd3793a49c9a45
tree3a0f7a88913581409e18ac5f26795ce295b1c969
parent723b0fa656d41d29e0cdf45d8bd212d6f1d0e575
LU-170 oscc_grow_count will never grow

We are using req::rq_async_args.space[0] to store original value of
oscc_grow_count, and using req::rq_async_args.pointer_arg[0] to store
oscc, however, ptlrpc_async_args is a union, which means
req::rq_async_args.space[0] will always be overwritten by a ossc (pointer),
and osc_interpret_create will always get true on this condition
"if (diff < (int) req->rq_async_args.space[0])" and reset
oscc_grow_count to OST_MIN_PRECREATE and set OSCC_FLAG_LOW.

Because it's very unsafe to use raw scratchpad directly, I also cleaned
up all using of raw scratchpad in this patch.

Change-Id: I56348c2ebaf27acb493185db73f3992a17610d98
Signed-off-by: Liang Zhen <liang@whamcloud.com>
Reviewed-on: http://review.whamcloud.com/371
Tested-by: Hudson
Reviewed-by: Oleg Drokin <green@whamcloud.com>
Reviewed-by: Johann Lombardi <johann@whamcloud.com>
Reviewed-by: Fan Yong <yong.fan@whamcloud.com>
lustre/include/lustre_net.h
lustre/ldlm/ldlm_lockd.c
lustre/mdc/mdc_locks.c
lustre/mdc/mdc_request.c
lustre/osc/osc_create.c
lustre/ptlrpc/recov_thread.c