lkml.org 
[lkml]   [2011]   [Oct]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH staging 3/6] et131x: fix error paths in et131x_pci_setup.
On Sun, Oct 23, 2011 at 07:11:35PM +0200, Francois Romieu wrote:
> Wrong status code and unbalanced phy_connect.
>
> Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
> ---
[...]
> @@ -5448,9 +5424,11 @@ static int __devinit et131x_pci_setup(struct pci_dev *pdev,
> */
> pci_set_drvdata(pdev, netdev);
> pci_save_state(adapter->pdev);
> +out:
> + return rc;
>
> - return result;
> -
> +err_phy_disconnect:
> + phy_disconnect(adapter->phydev);
> err_mdio_unregister:
> mdiobus_unregister(adapter->mii_bus);
> err_mdio_free_irq:
> @@ -5468,8 +5446,7 @@ err_release_res:
> pci_release_regions(pdev);
> err_disable:
> pci_disable_device(pdev);
> -err_out:
> - return result;
> + goto out;
> }
>
> static SIMPLE_DEV_PM_OPS(et131x_pm_ops, et131x_suspend, et131x_resume);

Patch looks good, but again, could you remove the backwards jumping goto.


\
 
 \ /
  Last update: 2011-10-24 22:25    [W:0.062 / U:10.088 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site