diff options
author | Bobi Jam <bobijam.xu@intel.com> | 2016-09-18 16:38:44 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-09-19 10:03:41 +0200 |
commit | 7ebb0ef382814c6c23188d7cf13951357fa75302 (patch) | |
tree | f7a5514be5aa672d7079c4076514ed7e8af630da /drivers/staging/lustre/lustre/osc/osc_io.c | |
parent | 96234ec51269417ec5c43bf13daede17cf4078ba (diff) |
staging: lustre: clio: pass fid for OST setattr
Store inode's fid in cl_setattr_ost() and OSC packs this info on the
wire (via lustre_set_wire_obdo) so that OST can use.
NOTE: currently lu_fid::f_ver and obdo::o_parent_ver are not used on
OFD device, and we use obdo::o_stripe_idx as
filter_fid::ff_parent::f_ver and save it to the device.
Signed-off-by: Bobi Jam <bobijam.xu@intel.com>
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-1154
Reviewed-on: http://review.whamcloud.com/12902
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Signed-off-by: James Simmons <jsimmons@infradead.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/lustre/lustre/osc/osc_io.c')
-rw-r--r-- | drivers/staging/lustre/lustre/osc/osc_io.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/staging/lustre/lustre/osc/osc_io.c b/drivers/staging/lustre/lustre/osc/osc_io.c index 42e9761aa368..8a559cbcdd0c 100644 --- a/drivers/staging/lustre/lustre/osc/osc_io.c +++ b/drivers/staging/lustre/lustre/osc/osc_io.c @@ -484,11 +484,13 @@ static int osc_io_setattr_start(const struct lu_env *env, memset(oa, 0, sizeof(*oa)); if (result == 0) { oa->o_oi = loi->loi_oi; + obdo_set_parent_fid(oa, io->u.ci_setattr.sa_parent_fid); + oa->o_stripe_idx = io->u.ci_setattr.sa_stripe_index; oa->o_mtime = attr->cat_mtime; oa->o_atime = attr->cat_atime; oa->o_ctime = attr->cat_ctime; - oa->o_valid = OBD_MD_FLID | OBD_MD_FLGROUP | OBD_MD_FLATIME | - OBD_MD_FLCTIME | OBD_MD_FLMTIME; + oa->o_valid |= OBD_MD_FLID | OBD_MD_FLGROUP | OBD_MD_FLATIME | + OBD_MD_FLCTIME | OBD_MD_FLMTIME; if (ia_valid & ATTR_SIZE) { oa->o_size = size; oa->o_blocks = OBD_OBJECT_EOF; |