eeprom: at25: check return value of devfs_create
Also only emit the message that the device was probed when it actually was. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This commit is contained in:
parent
24fcf5fcee
commit
a20a3cb4cd
|
@ -354,8 +354,11 @@ static int at25_probe(struct device_d *dev)
|
|||
goto fail;
|
||||
}
|
||||
|
||||
err = devfs_create(&at25->cdev);
|
||||
if (err)
|
||||
goto fail;
|
||||
|
||||
dev_dbg(dev, "%s probed\n", at25->cdev.name);
|
||||
devfs_create(&at25->cdev);
|
||||
of_parse_partitions(&at25->cdev, dev->device_node);
|
||||
return 0;
|
||||
|
||||
|
|
Loading…
Reference in New Issue