Commit d3d96820 authored by Mauro Carvalho Chehab's avatar Mauro Carvalho Chehab

[media] rc-main: use pr_foo() macros

Instead of calling printk() directly, use pr_foo() macro.

That should make the rc_core messages be formatted with the
right prefix.
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@s-opensource.com>
parent e5134114
...@@ -12,6 +12,8 @@ ...@@ -12,6 +12,8 @@
* GNU General Public License for more details. * GNU General Public License for more details.
*/ */
#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
#include <media/rc-core.h> #include <media/rc-core.h>
#include <linux/atomic.h> #include <linux/atomic.h>
#include <linux/spinlock.h> #include <linux/spinlock.h>
...@@ -66,7 +68,7 @@ struct rc_map *rc_map_get(const char *name) ...@@ -66,7 +68,7 @@ struct rc_map *rc_map_get(const char *name)
if (!map) { if (!map) {
int rc = request_module("%s", name); int rc = request_module("%s", name);
if (rc < 0) { if (rc < 0) {
printk(KERN_ERR "Couldn't load IR keymap %s\n", name); pr_err("Couldn't load IR keymap %s\n", name);
return NULL; return NULL;
} }
msleep(20); /* Give some time for IR to register */ msleep(20); /* Give some time for IR to register */
...@@ -75,7 +77,7 @@ struct rc_map *rc_map_get(const char *name) ...@@ -75,7 +77,7 @@ struct rc_map *rc_map_get(const char *name)
} }
#endif #endif
if (!map) { if (!map) {
printk(KERN_ERR "IR keymap %s not found\n", name); pr_err("IR keymap %s not found\n", name);
return NULL; return NULL;
} }
...@@ -1620,7 +1622,7 @@ static int __init rc_core_init(void) ...@@ -1620,7 +1622,7 @@ static int __init rc_core_init(void)
{ {
int rc = class_register(&rc_class); int rc = class_register(&rc_class);
if (rc) { if (rc) {
printk(KERN_ERR "rc_core: unable to register rc class\n"); pr_err("rc_core: unable to register rc class\n");
return rc; return rc;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment