Whamcloud - gitweb
LU-6458 mdd: try linkEA first in mdd_parent_fid 44/14444/2
authorwang di <di.wang@intel.com>
Mon, 13 Apr 2015 05:30:10 +0000 (22:30 -0700)
committerOleg Drokin <oleg.drokin@intel.com>
Fri, 5 Jun 2015 01:53:39 +0000 (01:53 +0000)
commit993858982eda2c7a7179b6c67c2d425df8e692f8
tree7cc8af83424b87b483e84bc2af14429641b580a2
parent0932c4e400be315bf608a553d3ad2463e7923d4a
LU-6458 mdd: try linkEA first in mdd_parent_fid

It should try to get parent FID from linkEA first, if that
fails, then do lookup dotdot. Two benefits

1. read EA is likely cheaper than lookup.

2. for striped directory, lookup might cause load sub stripes,
which is only necessary for certain operation (like unlink),
and for other cases, we should avoid it, because it will pin
the sub_stripe object with the master objet in the memory, i.e.
sub stripe object will only be freed when the master object
is freed, see lod_object_free()->lod_object_free_striping().

Signed-off-by: wang di <di.wang@intel.com>
Change-Id: Ia54a2d36b6ab640c533c0fb864431db062646299
Reviewed-on: http://review.whamcloud.com/14444
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/mdd/mdd_dir.c