From 35308b05d9a44b0f25534a7a9caf41c01af45ac2 Mon Sep 17 00:00:00 2001 From: wang di Date: Tue, 11 Aug 2015 04:19:43 -0700 Subject: [PATCH 1/1] LU-6977 lod: do_index_try should be called first In lod_striped_it_next do_index_try should be called first to initialize do_index_ops, then checking do_index_ops. Signed-off-by: wang di Change-Id: I477fb3c9ccd65c4e7721d78a3746f64acf8733ce Reviewed-on: http://review.whamcloud.com/15972 Tested-by: Jenkins Tested-by: Maloo Reviewed-by: Alex Zhuravlev Reviewed-by: James Simmons Reviewed-by: Oleg Drokin --- lustre/lod/lod_object.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lustre/lod/lod_object.c b/lustre/lod/lod_object.c index 255b8c8..ff13bda 100644 --- a/lustre/lod/lod_object.c +++ b/lustre/lod/lod_object.c @@ -571,12 +571,12 @@ again: next = lo->ldo_stripe[it->lit_stripe_index]; LASSERT(next != NULL); - LASSERT(next->do_index_ops != NULL); - rc = next->do_ops->do_index_try(env, next, &dt_directory_features); if (rc != 0) RETURN(rc); + LASSERT(next->do_index_ops != NULL); + it_next = next->do_index_ops->dio_it.init(env, next, it->lit_attr); if (!IS_ERR(it_next)) { it->lit_it = it_next; -- 1.8.3.1