Skip to content

Commit 65f5355

Browse files
petrpavlusamitolvanen
authored andcommitted
module: Clean up parse_args() arguments
* Use the preferred `unsigned int` over plain `unsigned` for the `num` parameter. * Synchronize the parameter names in moduleparam.h with the ones used by the implementation in params.c. Signed-off-by: Petr Pavlu <petr.pavlu@suse.com> Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
1 parent deffe1e commit 65f5355

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

include/linux/moduleparam.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -417,12 +417,12 @@ extern bool parameqn(const char *name1, const char *name2, size_t n);
417417
typedef int (*parse_unknown_fn)(char *param, char *val, const char *doing, void *arg);
418418

419419
/* Called on module insert or kernel boot */
420-
extern char *parse_args(const char *name,
420+
extern char *parse_args(const char *doing,
421421
char *args,
422422
const struct kernel_param *params,
423-
unsigned num,
424-
s16 level_min,
425-
s16 level_max,
423+
unsigned int num,
424+
s16 min_level,
425+
s16 max_level,
426426
void *arg, parse_unknown_fn unknown);
427427

428428
/* Called by module remove. */

kernel/params.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@ static int parse_one(char *param,
161161
char *parse_args(const char *doing,
162162
char *args,
163163
const struct kernel_param *params,
164-
unsigned num,
164+
unsigned int num,
165165
s16 min_level,
166166
s16 max_level,
167167
void *arg, parse_unknown_fn unknown)

0 commit comments

Comments
 (0)