mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-06 19:08:57 +09:00
UPSTREAM: 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>
Bug: 228237154
(cherry picked from commit c572724406)
Change-Id: I3bf8414a74aaeba9ae08bb3954f975c872894cd3
Signed-off-by: Jindong Yue <jindong.yue@nxp.com>
This commit is contained in:
committed by
Jindong Yue
parent
374fbf2939
commit
5ce1bc8a73
@@ -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>
|
||||
@@ -536,7 +539,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;
|
||||
}
|
||||
|
||||
@@ -549,7 +552,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);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user