const struct dt_device *dev,
struct dt_device_param *param)
{
+ struct osd_device *osd = osd_dt_dev(dev);
+
/*
* XXX should be taken from not-yet-existing fs abstraction layer.
*/
- param->ddp_max_name_len = MAXNAMELEN;
- param->ddp_max_nlink = 1 << 31; /* it's 8byte on a disk */
- param->ddp_block_shift = 12; /* XXX */
- param->ddp_mount_type = LDD_MT_ZFS;
+ param->ddp_max_name_len = MAXNAMELEN;
+ param->ddp_max_nlink = 1 << 31; /* it's 8byte on a disk */
+ param->ddp_block_shift = 12; /* XXX */
+ param->ddp_mount_type = LDD_MT_ZFS;
- param->ddp_mntopts = MNTOPT_USERXATTR | MNTOPT_ACL;
- param->ddp_max_ea_size = DXATTR_MAX_ENTRY_SIZE;
+ param->ddp_mntopts = MNTOPT_USERXATTR;
+ if (osd->od_posix_acl)
+ param->ddp_mntopts |= MNTOPT_ACL;
+ param->ddp_max_ea_size = DXATTR_MAX_ENTRY_SIZE;
/* for maxbytes, report same value as ZPL */
- param->ddp_maxbytes = MAX_LFS_FILESIZE;
+ param->ddp_maxbytes = MAX_LFS_FILESIZE;
/* Default reserved fraction of the available space that should be kept
* for error margin. Unfortunately, there are many factors that can
char *svname = lustre_cfg_string(cfg, 4);
dmu_buf_t *rootdb;
dsl_pool_t *dp;
+ const char *opts;
int rc;
ENTRY;
o->od_quota_slave = NULL;
GOTO(err, rc);
}
+
+ /* parse mount option "noacl", and enable ACL by default */
+ opts = lustre_cfg_string(cfg, 3);
+ if (opts == NULL || strstr(opts, "noacl") == NULL)
+ o->od_posix_acl = 1;
+
err:
RETURN(rc);
}
break;
case LCFG_PARAM: {
LASSERT(&o->od_dt_dev);
- rc = class_process_proc_seq_param(PARAM_OSD,
- lprocfs_osd_obd_vars, cfg,
- &o->od_dt_dev);
+ rc = class_process_proc_param(PARAM_OSD, lprocfs_osd_obd_vars,
+ cfg, &o->od_dt_dev);
if (rc > 0 || rc == -ENOSYS)
- rc = class_process_proc_seq_param(PARAM_OST,
- lprocfs_osd_obd_vars,
- cfg, &o->od_dt_dev);
+ rc = class_process_proc_param(PARAM_OST,
+ lprocfs_osd_obd_vars,
+ cfg, &o->od_dt_dev);
break;
}
default:
return rc;
rc = class_register_type(&osd_obd_device_ops, NULL, true, NULL,
-#ifndef HAVE_ONLY_PROCFS_SEQ
- NULL,
-#endif
LUSTRE_OSD_ZFS_NAME, &osd_device_type);
if (rc)
lu_kmem_fini(osd_caches);