From b5d21704361eefe337a36ebbb57a1d9927132511 Mon Sep 17 00:00:00 2001 From: Dmitry Torokhov Date: Mon, 10 Oct 2011 18:27:03 -0700 Subject: Input: psmouse - switch to using dev_*() for messages This will ensure our reporting is consistent with the rest of the system and we do not refer to obsolete source file names. Reviewed-by: Wanlong Gao Reviewed-by: JJ Ding Reviewed-by: Daniel Kurtz Signed-off-by: Dmitry Torokhov --- drivers/input/mouse/psmouse.h | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) (limited to 'drivers/input/mouse/psmouse.h') diff --git a/drivers/input/mouse/psmouse.h b/drivers/input/mouse/psmouse.h index 593e910bfc7..9b84b0c4e37 100644 --- a/drivers/input/mouse/psmouse.h +++ b/drivers/input/mouse/psmouse.h @@ -150,4 +150,29 @@ static struct psmouse_attribute psmouse_attr_##_name = { \ static ssize_t _set(struct psmouse *, void *, const char *, size_t); \ __PSMOUSE_DEFINE_ATTR_VAR(_name, _mode, _data, NULL, _set, true) +#ifndef psmouse_fmt +#define psmouse_fmt(fmt) KBUILD_BASENAME ": " fmt +#endif + +#define psmouse_dbg(psmouse, format, ...) \ + dev_dbg(&(psmouse)->ps2dev.serio->dev, \ + psmouse_fmt(format), ##__VA_ARGS__) +#define psmouse_info(psmouse, format, ...) \ + dev_info(&(psmouse)->ps2dev.serio->dev, \ + psmouse_fmt(format), ##__VA_ARGS__) +#define psmouse_warn(psmouse, format, ...) \ + dev_warn(&(psmouse)->ps2dev.serio->dev, \ + psmouse_fmt(format), ##__VA_ARGS__) +#define psmouse_err(psmouse, format, ...) \ + dev_err(&(psmouse)->ps2dev.serio->dev, \ + psmouse_fmt(format), ##__VA_ARGS__) +#define psmouse_notice(psmouse, format, ...) \ + dev_notice(&(psmouse)->ps2dev.serio->dev, \ + psmouse_fmt(format), ##__VA_ARGS__) +#define psmouse_printk(level, psmouse, format, ...) \ + dev_printk(level, \ + &(psmouse)->ps2dev.serio->dev, \ + psmouse_fmt(format), ##__VA_ARGS__) + + #endif /* _PSMOUSE_H */ -- cgit v1.2.3-70-g09d2