File tree Expand file tree Collapse file tree 1 file changed +23
-1
lines changed Expand file tree Collapse file tree 1 file changed +23
-1
lines changed Original file line number Diff line number Diff line change 38
38
#include <linux/slab.h>
39
39
#include <linux/kthread.h>
40
40
#include <linux/namei.h>
41
+ #include <linux/moduleparam.h>
41
42
42
43
#include <linux/sunrpc/addr.h>
43
44
#include <linux/nfs_ssc.h>
52
53
#include "pnfs.h"
53
54
#include "trace.h"
54
55
56
+ static int param_set_inter_copy_offload (const char * val ,
57
+ const struct kernel_param * kp )
58
+ {
59
+ bool enable ;
60
+ int ret ;
61
+
62
+ ret = kstrtobool (val , & enable );
63
+ if (ret )
64
+ return ret ;
65
+
66
+ if (enable )
67
+ mark_tech_preview ("Inter server-to-server copy offload" , NULL );
68
+
69
+ return param_set_bool (val , kp );
70
+ }
71
+
72
+ static const struct kernel_param_ops param_ops_inter_copy_offload = {
73
+ .set = param_set_inter_copy_offload ,
74
+ .get = param_get_bool ,
75
+ };
76
+ #define param_check_inter_copy_offload (name , p ) __param_check(name, p, bool)
55
77
static bool inter_copy_offload_enable ;
56
- module_param (inter_copy_offload_enable , bool , 0644 );
78
+ module_param (inter_copy_offload_enable , inter_copy_offload , 0644 );
57
79
MODULE_PARM_DESC (inter_copy_offload_enable ,
58
80
"Enable inter server to server copy offload. Default: false" );
59
81
You can’t perform that action at this time.
0 commit comments