Re: [PATCH] sr9800: Use common error handling code in sr9800_phy_powerup()

2017-10-30 Thread Geert Uytterhoeven
Hi Markus, On Sun, Oct 29, 2017 at 1:03 PM, SF Markus Elfring wrote: >>> @@ -700,10 +700,9 @@ static int sr9800_phy_powerup(struct usbnet *dev) >>> >>> /* set the embedded Ethernet PHY in power-up state */ >>> ret = sr_sw_reset(dev, SR_SWRESET_IPRL); >>> - if (ret < 0) { >>>

Re: [PATCH] sr9800: Use common error handling code in sr9800_phy_powerup()

2017-10-29 Thread SF Markus Elfring
>> @@ -700,10 +700,9 @@ static int sr9800_phy_powerup(struct usbnet *dev) >> >> /* set the embedded Ethernet PHY in power-up state */ >> ret = sr_sw_reset(dev, SR_SWRESET_IPRL); >> - if (ret < 0) { >> - netdev_err(dev->net, "Failed to reset PHY: %d\n", ret); >> -

Re: [PATCH] sr9800: Use common error handling code in sr9800_phy_powerup()

2017-10-29 Thread Geert Uytterhoeven
Hi Markus, On Sun, Oct 29, 2017 at 11:45 AM, SF Markus Elfring wrote: > From: Markus Elfring > Date: Sun, 29 Oct 2017 11:33:14 +0100 > > Add a jump target so that a specific error message is stored only once > at the end of this function implementation. > Replace two calls of the function "netde

[PATCH] sr9800: Use common error handling code in sr9800_phy_powerup()

2017-10-29 Thread SF Markus Elfring
From: Markus Elfring Date: Sun, 29 Oct 2017 11:33:14 +0100 Add a jump target so that a specific error message is stored only once at the end of this function implementation. Replace two calls of the function "netdev_err" by goto statements. This issue was detected by using the Coccinelle softwar