Skip to content

Commit c572724

Browse files
arnopomathieupoirier
authored andcommitted
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 <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mathieu Poirier <[email protected]>
1 parent fa55b7d commit c572724

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

drivers/rpmsg/rpmsg_char.c

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@
99
* Based on rpmsg performance statistics driver by Michal Simek, which in turn
1010
* was based on TI & Google OMX rpmsg driver.
1111
*/
12+
13+
#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
14+
1215
#include <linux/cdev.h>
1316
#include <linux/device.h>
1417
#include <linux/fs.h>
@@ -550,7 +553,7 @@ static int rpmsg_chrdev_init(void)
550553

551554
ret = alloc_chrdev_region(&rpmsg_major, 0, RPMSG_DEV_MAX, "rpmsg");
552555
if (ret < 0) {
553-
pr_err("rpmsg: failed to allocate char dev region\n");
556+
pr_err("failed to allocate char dev region\n");
554557
return ret;
555558
}
556559

@@ -563,7 +566,7 @@ static int rpmsg_chrdev_init(void)
563566

564567
ret = register_rpmsg_driver(&rpmsg_chrdev_driver);
565568
if (ret < 0) {
566-
pr_err("rpmsgchr: failed to register rpmsg driver\n");
569+
pr_err("failed to register rpmsg driver\n");
567570
class_destroy(rpmsg_class);
568571
unregister_chrdev_region(rpmsg_major, RPMSG_DEV_MAX);
569572
}

0 commit comments

Comments
 (0)