diff options
author | Arnaud Pouliquen <arnaud.pouliquen@foss.st.com> | 2021-11-08 14:59:45 +0100 |
---|---|---|
committer | Mathieu Poirier <mathieu.poirier@linaro.org> | 2021-11-18 10:27:15 -0700 |
commit | c572724406e3926502eccc930447f0affb604503 (patch) | |
tree | 07153ba4d8b6d9957fba6806d96242d831752534 /drivers/rpmsg | |
parent | fa55b7dcdc43c1aa1ba12bca9d2dd4318c2a0dbf (diff) | |
download | linux-c572724406e3926502eccc930447f0affb604503.tar.bz2 |
rpmsg: char: Add pr_fmt() to prefix messages
Make all messages to be prefixed in a unified way.
Add pr_fmt() to achieve this.
Signed-off-by: Arnaud Pouliquen <arnaud.pouliquen@foss.st.com>
Link: https://lore.kernel.org/r/20211108135945.3364-1-arnaud.pouliquen@foss.st.com
Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
Diffstat (limited to 'drivers/rpmsg')
-rw-r--r-- | drivers/rpmsg/rpmsg_char.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/rpmsg/rpmsg_char.c b/drivers/rpmsg/rpmsg_char.c index b5907b80727c..d6214cb66026 100644 --- a/drivers/rpmsg/rpmsg_char.c +++ b/drivers/rpmsg/rpmsg_char.c @@ -9,6 +9,9 @@ * Based on rpmsg performance statistics driver by Michal Simek, which in turn * was based on TI & Google OMX rpmsg driver. */ + +#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt + #include <linux/cdev.h> #include <linux/device.h> #include <linux/fs.h> @@ -550,7 +553,7 @@ static int rpmsg_chrdev_init(void) ret = alloc_chrdev_region(&rpmsg_major, 0, RPMSG_DEV_MAX, "rpmsg"); if (ret < 0) { - pr_err("rpmsg: failed to allocate char dev region\n"); + pr_err("failed to allocate char dev region\n"); return ret; } @@ -563,7 +566,7 @@ static int rpmsg_chrdev_init(void) ret = register_rpmsg_driver(&rpmsg_chrdev_driver); if (ret < 0) { - pr_err("rpmsgchr: failed to register rpmsg driver\n"); + pr_err("failed to register rpmsg driver\n"); class_destroy(rpmsg_class); unregister_chrdev_region(rpmsg_major, RPMSG_DEV_MAX); } |