-
-static struct lprocfs_vars lprocfs_mdt_obd_vars[] = {
- { "uuid", lprocfs_rd_uuid, NULL,
- NULL, NULL, 0 },
- { "recovery_status", lprocfs_obd_rd_recovery_status, NULL,
- NULL, NULL, 0 },
- { "num_exports", lprocfs_rd_num_exports, NULL,
- NULL, NULL, 0 },
- { "identity_expire", lprocfs_rd_identity_expire,
- lprocfs_wr_identity_expire,
- NULL, NULL, 0 },
- { "identity_acquire_expire", lprocfs_rd_identity_acquire_expire,
- lprocfs_wr_identity_acquire_expire,
- NULL, NULL, 0 },
- { "identity_upcall", lprocfs_rd_identity_upcall,
- lprocfs_wr_identity_upcall,
- NULL, NULL, 0 },
- { "identity_flush", NULL, lprocfs_wr_identity_flush,
- NULL, NULL, 0 },
- { "identity_info", NULL, lprocfs_wr_identity_info,
- NULL, NULL, 0 },
- { "capa", lprocfs_rd_capa,
- lprocfs_wr_capa,
- NULL, NULL, 0 },
- { "capa_timeout", lprocfs_rd_capa_timeout,
- lprocfs_wr_capa_timeout,
- NULL, NULL, 0 },
- { "capa_key_timeout", lprocfs_rd_ck_timeout,
- lprocfs_wr_ck_timeout,
- NULL, NULL, 0 },
- { "capa_count", lprocfs_rd_capa_count, NULL,
- NULL, NULL, 0 },
- { "site_stats", lprocfs_rd_site_stats, NULL,
- NULL, NULL, 0 },
- { "evict_client", NULL, lprocfs_mdt_wr_evict_client,
- NULL, NULL, 0 },
- { "hash_stats", lprocfs_obd_rd_hash, NULL,
- NULL, NULL, 0 },
- { "sec_level", lprocfs_rd_sec_level,
- lprocfs_wr_sec_level,
- NULL, NULL, 0 },
- { "commit_on_sharing", lprocfs_rd_cos, lprocfs_wr_cos,
- NULL, NULL, 0 },
- { "root_squash", lprocfs_rd_mdt_root_squash,
- lprocfs_wr_mdt_root_squash,
- NULL, NULL, 0 },
- { "nosquash_nids", lprocfs_rd_mdt_nosquash_nids,
- lprocfs_wr_mdt_nosquash_nids,
- NULL, NULL, 0 },
- { "som", lprocfs_rd_mdt_som,
- lprocfs_wr_mdt_som,
- NULL, NULL, 0 },
- { "instance", lprocfs_target_rd_instance, NULL,
- NULL, NULL, 0},
- { "ir_factor", lprocfs_obd_rd_ir_factor,
- lprocfs_obd_wr_ir_factor,
- NULL, NULL, 0 },
- { "job_cleanup_interval", lprocfs_rd_job_interval,
- lprocfs_wr_job_interval,
- NULL, NULL, 0 },
- { "enable_remote_dir", lprocfs_rd_enable_remote_dir,
- lprocfs_wr_enable_remote_dir,
- NULL, NULL, 0},
- { "enable_remote_dir_gid", lprocfs_rd_enable_remote_dir_gid,
- lprocfs_wr_enable_remote_dir_gid,
- NULL, NULL, 0},
- { "hsm_control", lprocfs_rd_hsm_cdt_control,
- lprocfs_wr_hsm_cdt_control,
- NULL, NULL, 0 },
- { 0 }
-};
-
-static struct lprocfs_vars lprocfs_mdt_module_vars[] = {
- { "num_refs", lprocfs_rd_numrefs, NULL,
- NULL, NULL, 0 },
- { 0 }
-};
-
-void lprocfs_mdt_init_vars(struct lprocfs_static_vars *lvars)
-{
- lvars->module_vars = lprocfs_mdt_module_vars;
- lvars->obd_vars = lprocfs_mdt_obd_vars;
-}
-
-struct lprocfs_vars lprocfs_mds_obd_vars[] = {
- { "uuid", lprocfs_rd_uuid, NULL, NULL, NULL, 0 },
- { 0 }
-};
-
-struct lprocfs_vars lprocfs_mds_module_vars[] = {
- { "num_refs", lprocfs_rd_numrefs, NULL, NULL, NULL, 0 },
+LPROC_SEQ_FOPS(mdt_enable_remote_dir_gid);
+
+LPROC_SEQ_FOPS_RO_TYPE(mdt, uuid);
+LPROC_SEQ_FOPS_RO_TYPE(mdt, recovery_status);
+LPROC_SEQ_FOPS_RO_TYPE(mdt, num_exports);
+LPROC_SEQ_FOPS_RO_TYPE(mdt, target_instance);
+LPROC_SEQ_FOPS_RO_TYPE(mdt, hash);
+LPROC_SEQ_FOPS_WO_TYPE(mdt, mds_evict_client);
+LPROC_SEQ_FOPS_RW_TYPE(mdt, job_interval);
+LPROC_SEQ_FOPS_RW_TYPE(mdt, ir_factor);
+LPROC_SEQ_FOPS_RW_TYPE(mdt, nid_stats_clear);
+LPROC_SEQ_FOPS(mdt_hsm_cdt_control);
+
+static struct lprocfs_seq_vars lprocfs_mdt_obd_vars[] = {
+ { .name = "uuid",
+ .fops = &mdt_uuid_fops },
+ { .name = "recovery_status",
+ .fops = &mdt_recovery_status_fops },
+ { .name = "num_exports",
+ .fops = &mdt_num_exports_fops },
+ { .name = "identity_expire",
+ .fops = &mdt_identity_expire_fops },
+ { .name = "identity_acquire_expire",
+ .fops = &mdt_identity_acquire_expire_fops },
+ { .name = "identity_upcall",
+ .fops = &mdt_identity_upcall_fops },
+ { .name = "identity_flush",
+ .fops = &mdt_identity_flush_fops },
+ { .name = "identity_info",
+ .fops = &mdt_identity_info_fops },
+ { .name = "capa",
+ .fops = &mdt_capa_fops },
+ { .name = "capa_timeout",
+ .fops = &mdt_capa_timeout_fops },
+ { .name = "capa_key_timeout",
+ .fops = &mdt_ck_timeout_fops },
+ { .name = "capa_count",
+ .fops = &mdt_capa_count_fops },
+ { .name = "site_stats",
+ .fops = &mdt_site_stats_fops },
+ { .name = "evict_client",
+ .fops = &mdt_mds_evict_client_fops },
+ { .name = "hash_stats",
+ .fops = &mdt_hash_fops },
+ { .name = "sec_level",
+ .fops = &mdt_sec_level_fops },
+ { .name = "commit_on_sharing",
+ .fops = &mdt_cos_fops },
+ { .name = "root_squash",
+ .fops = &mdt_root_squash_fops },
+ { .name = "nosquash_nids",
+ .fops = &mdt_nosquash_nids_fops },
+ { .name = "som",
+ .fops = &mdt_som_fops },
+ { .name = "instance",
+ .fops = &mdt_target_instance_fops },
+ { .name = "ir_factor",
+ .fops = &mdt_ir_factor_fops },
+ { .name = "job_cleanup_interval",
+ .fops = &mdt_job_interval_fops },
+ { .name = "enable_remote_dir",
+ .fops = &mdt_enable_remote_dir_fops },
+ { .name = "enable_remote_dir_gid",
+ .fops = &mdt_enable_remote_dir_gid_fops },
+ { .name = "hsm_control",
+ .fops = &mdt_hsm_cdt_control_fops },