Subject: Re: [PATCH] net: dsa: better error reporting

From: Florian Fainelli <[email-masked]>
Date: Sat, 3 Oct 2015 13:16:11 -0700

Le 03/10/2015 10:09, Russell King a écrit :
> Add additional error reporting to the generic DSA code, so it's easier
> to debug when things go wrong.  This was useful when initially bringing
> up 88e6176 on a new board.
> 
> Signed-off-by: Russell King <[email-masked]>
> ---

[snip]

>  	} else {
>  		netdev_info(slave_dev, "attached PHY at address %d [%s]\n",
>  			    p->phy->addr, p->phy->drv->name);
> @@ -1195,6 +1202,7 @@ int dsa_slave_create(struct dsa_switch *ds, struct device *parent,
>  
>  	ret = dsa_slave_phy_setup(p, slave_dev);
>  	if (ret) {
> +		netdev_err(master, "error %d setting up slave phy\n", ret);
>  		free_netdev(slave_dev);
>  		return ret;

All of these debug messages are going to happen prior to the slave
network device being registered, so you would get these error messages
to be printed with an extraneous " (unregistered)" which is fine, just a
tad annoying sometimes.

Acked-by: Florian Fainelli <[email-masked]>
-- 
Florian