Skip to content

Commit adbed05

Browse files
vshankaridryomov
authored andcommitted
ceph: mount syntax module parameter
Add read-only module parameters for supported mount syntaxes. Primary user is the user-space mount helper for catching v2 syntax bugs during testing by cross verifying if the kernel supports v2 syntax on mount failure. Signed-off-by: Venky Shankar <[email protected]> Reviewed-by: Jeff Layton <[email protected]> Signed-off-by: Ilya Dryomov <[email protected]>
1 parent e1b9eb5 commit adbed05

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

fs/ceph/super.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1461,6 +1461,14 @@ bool disable_send_metrics = false;
14611461
module_param_cb(disable_send_metrics, &param_ops_metrics, &disable_send_metrics, 0644);
14621462
MODULE_PARM_DESC(disable_send_metrics, "Enable sending perf metrics to ceph cluster (default: on)");
14631463

1464+
/* for both v1 and v2 syntax */
1465+
static bool mount_support = true;
1466+
static const struct kernel_param_ops param_ops_mount_syntax = {
1467+
.get = param_get_bool,
1468+
};
1469+
module_param_cb(mount_syntax_v1, &param_ops_mount_syntax, &mount_support, 0444);
1470+
module_param_cb(mount_syntax_v2, &param_ops_mount_syntax, &mount_support, 0444);
1471+
14641472
module_init(init_ceph);
14651473
module_exit(exit_ceph);
14661474

0 commit comments

Comments
 (0)