Skip to content

Commit

Permalink
module: Add NOARG flag for ops with param_set_bool_enable_only() set …
Browse files Browse the repository at this point in the history
…function

The ops that uses param_set_bool_enable_only() as its set function can
easily handle being used without an argument. There's no reason to
fail the loading of the module if it does not have one.

Signed-off-by: Steven Rostedt <[email protected]>
Signed-off-by: Rusty Russell <[email protected]>
  • Loading branch information
rostedt authored and rustyrussell committed Aug 20, 2013
1 parent ab013c5 commit 0ce8140
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions kernel/module.c
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@ static int param_set_bool_enable_only(const char *val,
}

static const struct kernel_param_ops param_ops_bool_enable_only = {
.flags = KERNEL_PARAM_FL_NOARG,
.set = param_set_bool_enable_only,
.get = param_get_bool,
};
Expand Down

0 comments on commit 0ce8140

Please sign in to comment.