* Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved.
* Use is subject to license terms.
*
- * Copyright (c) 2012, 2016, Intel Corporation.
+ * Copyright (c) 2012, 2017, Intel Corporation.
*/
/*
* This file is part of Lustre, http://www.lustre.org/
#define DEBUG_SUBSYSTEM S_FILTER
-#include <lustre/lustre_idl.h>
#include "ofd_internal.h"
#include <obd_cksum.h>
-#include <uapi/linux/lustre_ioctl.h>
+#include <uapi/linux/lustre/lustre_ioctl.h>
#include <lustre_quota.h>
#include <lustre_lfsck.h>
#include <lustre_nodemap.h>
* \retval negative value on error
*/
int ofd_statfs(const struct lu_env *env, struct obd_export *exp,
- struct obd_statfs *osfs, __u64 max_age, __u32 flags)
+ struct obd_statfs *osfs, time64_t max_age, __u32 flags)
{
struct obd_device *obd = class_exp2obd(exp);
struct ofd_device *ofd = ofd_exp(exp);
struct ldlm_resource *res;
struct ofd_object *fo;
struct lu_fid *fid = &oa->o_oi.oi_fid;
- struct filter_fid *ff = NULL;
int rc = 0;
ENTRY;
la_from_obdo(&info->fti_attr, oa, oa->o_valid);
info->fti_attr.la_valid &= ~LA_TYPE;
- if (oa->o_valid & OBD_MD_FLFID) {
- ff = &info->fti_mds_fid;
- ofd_prepare_fidea(ff, oa);
- }
-
/* setting objects attributes (including owner/group) */
- rc = ofd_attr_set(env, fo, &info->fti_attr, ff);
+ rc = ofd_attr_set(env, fo, &info->fti_attr, oa);
if (rc)
GOTO(out_unlock, rc);
struct ofd_device *ofd = ofd_exp(exp);
u64 seq = ostid_seq(&oa->o_oi);
struct ofd_seq *oseq;
- int rc = 0, diff = 1;
long granted;
u64 next_id;
+ s64 diff = 1;
+ int rc = 0;
int count;
ENTRY;
rc = granted;
granted = 0;
CDEBUG(D_HA, "%s: failed to acquire grant space for "
- "precreate (%d): rc = %d\n", ofd_name(ofd), diff, rc);
+ "precreate (%lld): rc = %d\n", ofd_name(ofd), diff, rc);
diff = 0;
GOTO(out, rc);
}
next_id = ofd_seq_last_oid(oseq) + 1;
- count = ofd_precreate_batch(ofd, diff);
+ count = ofd_precreate_batch(ofd, (int)diff);
rc = ofd_precreate_objects(env, ofd, next_id, oseq, count, 0);
if (rc < 0) {
data->ioc_inllen3 == sizeof(__u64) &&
data->ioc_inlbuf4 != NULL &&
data->ioc_inllen4 == sizeof(__u64)) {
- struct ost_id ostid;
+ struct ost_id ostid = { };
ostid_set_seq(&ostid, *(__u64 *)data->ioc_inlbuf4);
rc = ostid_set_id(&ostid, *(__u64 *)data->ioc_inlbuf3);