Whamcloud - gitweb
LU-1604 osd: don't call md_ucred() for OFD
authorJohann Lombardi <johann@whamcloud.com>
Thu, 5 Jul 2012 20:34:23 +0000 (22:34 +0200)
committerOleg Drokin <green@whamcloud.com>
Fri, 13 Jul 2012 07:38:15 +0000 (03:38 -0400)
commitc69f7adac0f87a4c31706b62bd72c780d2563586
treeb4f381281ffe3205a11936c2789507ff684acc40
parent08cdb5e2bb122f87e6c248394f1ba9407c4e62c4
LU-1604 osd: don't call md_ucred() for OFD

There are several places where md_ucred() is called in osd-ldiskfs.
However, this function is specific to the metadata stack (it ends
up calling a callback in mdd layer) and should not be called with OFD.

osd_{push,pop}_ctxt() have thus been modified to be no-op when the
parent is of DT type. __osd_oi_insert() has also been changed to call
md_ucred() only when dealing with a MDT device.

This hack is required to keep compatibility with current MDT stack,
but should be removed as soon as the LOD/OSP is landed.

Signed-off-by: Johann Lombardi <johann@whamcloud.com>
Change-Id: I931f0376a78cb2aff8b00a99b1c20618d4093e7d
Reviewed-on: http://review.whamcloud.com/3286
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Reviewed-by: Li Wei <liwei@whamcloud.com>
Reviewed-by: Mike Pershin <tappro@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/osd-ldiskfs/osd_handler.c
lustre/osd-ldiskfs/osd_internal.h