diff options
author | Joe Perches <joe@perches.com> | 2014-04-09 03:04:14 +0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-04-09 03:48:52 +0400 |
commit | b41f8b84d01d32ea618dbbe5679bd07ce3444b88 (patch) | |
tree | cbede13191e15a0554b8d12ae6ef098a8ce4048b /fs/ncpfs/getopt.c | |
parent | d0057ca4c1fe73c05a9e077cc7691217370b3283 (diff) | |
download | linux-b41f8b84d01d32ea618dbbe5679bd07ce3444b88.tar.xz |
ncpfs: Add pr_fmt and convert printks to pr_<level>
Convert to a more current logging style.
Add pr_fmt to prefix with "ncpfs: ".
Remove the embedded function names and use "%s: ", __func__
Some previously unprefixed messages now have "ncpfs: "
Signed-off-by: Joe Perches <joe@perches.com>
Cc: Petr Vandrovec <petr@vandrovec.name>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/ncpfs/getopt.c')
-rw-r--r-- | fs/ncpfs/getopt.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/fs/ncpfs/getopt.c b/fs/ncpfs/getopt.c index 0af3349de851..03ffde1f44d6 100644 --- a/fs/ncpfs/getopt.c +++ b/fs/ncpfs/getopt.c @@ -2,6 +2,8 @@ * getopt.c */ +#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt + #include <linux/kernel.h> #include <linux/string.h> @@ -46,8 +48,8 @@ int ncp_getopt(const char *caller, char **options, const struct ncp_option *opts if (opts->has_arg & OPT_NOPARAM) { return opts->val; } - printk(KERN_INFO "%s: the %s option requires an argument\n", - caller, token); + pr_info("%s: the %s option requires an argument\n", + caller, token); return -EINVAL; } if (opts->has_arg & OPT_INT) { @@ -57,18 +59,18 @@ int ncp_getopt(const char *caller, char **options, const struct ncp_option *opts if (!*v) { return opts->val; } - printk(KERN_INFO "%s: invalid numeric value in %s=%s\n", + pr_info("%s: invalid numeric value in %s=%s\n", caller, token, val); return -EDOM; } if (opts->has_arg & OPT_STRING) { return opts->val; } - printk(KERN_INFO "%s: unexpected argument %s to the %s option\n", + pr_info("%s: unexpected argument %s to the %s option\n", caller, val, token); return -EINVAL; } } - printk(KERN_INFO "%s: Unrecognized mount option %s\n", caller, token); + pr_info("%s: Unrecognized mount option %s\n", caller, token); return -EOPNOTSUPP; } |