From 1f7c8234c7a68c2ccc2a33f3b7d48057980e7c35 Mon Sep 17 00:00:00 2001 From: Emil Medve Date: Tue, 16 Oct 2007 23:29:48 -0700 Subject: Make the pr_*() family of macros in kernel.h complete Other/Some pr_*() macros are already defined in kernel.h, but pr_err() was defined multiple times in several other places Signed-off-by: Emil Medve Cc: Jean Delvare Cc: Jeff Garzik Cc: "Antonino A. Daplas" Cc: Tony Lindgren Reviewed-by: Satyam Sharma Acked-by: Randy Dunlap Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/i2c/chips/menelaus.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'drivers/i2c') diff --git a/drivers/i2c/chips/menelaus.c b/drivers/i2c/chips/menelaus.c index d9c92c5e007..66436bae11a 100644 --- a/drivers/i2c/chips/menelaus.c +++ b/drivers/i2c/chips/menelaus.c @@ -49,8 +49,6 @@ #define DRIVER_NAME "menelaus" -#define pr_err(fmt, arg...) printk(KERN_ERR DRIVER_NAME ": ", ## arg); - #define MENELAUS_I2C_ADDRESS 0x72 #define MENELAUS_REV 0x01 @@ -155,7 +153,7 @@ static int menelaus_write_reg(int reg, u8 value) int val = i2c_smbus_write_byte_data(the_menelaus->client, reg, value); if (val < 0) { - pr_err("write error"); + pr_err(DRIVER_NAME ": write error"); return val; } @@ -167,7 +165,7 @@ static int menelaus_read_reg(int reg) int val = i2c_smbus_read_byte_data(the_menelaus->client, reg); if (val < 0) - pr_err("read error"); + pr_err(DRIVER_NAME ": read error"); return val; } @@ -1177,7 +1175,7 @@ static int menelaus_probe(struct i2c_client *client) /* If a true probe check the device */ rev = menelaus_read_reg(MENELAUS_REV); if (rev < 0) { - pr_err("device not found"); + pr_err(DRIVER_NAME ": device not found"); err = -ENODEV; goto fail1; } @@ -1258,7 +1256,7 @@ static int __init menelaus_init(void) res = i2c_add_driver(&menelaus_i2c_driver); if (res < 0) { - pr_err("driver registration failed\n"); + pr_err(DRIVER_NAME ": driver registration failed\n"); return res; } -- cgit v1.2.3