Commit 76df2773 authored by Felipe Balbi's avatar Felipe Balbi Committed by Tony Lindgren

I2C: i2c subsystem should print error messages

We don't have to print any error message if i2c_add_driver
fails since i2c subsystem already does it.
Signed-off-by: default avatarFelipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
parent c7cf41bd
......@@ -1606,15 +1606,7 @@ static struct i2c_driver isp1301_driver = {
static int __init isp_init(void)
{
int status = -ENODEV;
printk(KERN_INFO "%s: version %s\n", DRIVER_NAME, DRIVER_VERSION);
status = i2c_add_driver(&isp1301_driver);
if (status)
printk(KERN_ERR "%s failed to probe\n", DRIVER_NAME);
return status;
return i2c_add_driver(&isp1301_driver);
}
module_init(isp_init);
......
......@@ -1281,15 +1281,7 @@ static struct i2c_driver menelaus_i2c_driver = {
static int __init menelaus_init(void)
{
int res;
res = i2c_add_driver(&menelaus_i2c_driver);
if (res < 0) {
dev_err(&the_menelaus->client->dev, "driver registration failed\n");
return res;
}
return 0;
return i2c_add_driver(&menelaus_i2c_driver);
}
static void __exit menelaus_exit(void)
......
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