Re: [PATCH 1/3] eeprom: at25: check return value of devfs_create

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, May 30, 2016 at 11:39:51AM +0200, Uwe Kleine-König wrote:
> Also only emit the message that the device was probed when it
> actually was.
> 
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx>
> ---

Applied, thanks

Sascha

>  drivers/eeprom/at25.c | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/eeprom/at25.c b/drivers/eeprom/at25.c
> index 9f054d00b459..f7f8368c4b45 100644
> --- a/drivers/eeprom/at25.c
> +++ b/drivers/eeprom/at25.c
> @@ -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;
>  
> -- 
> 2.8.1
> 
> 
> _______________________________________________
> barebox mailing list
> barebox@xxxxxxxxxxxxxxxxxxx
> http://lists.infradead.org/mailman/listinfo/barebox

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox




[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux