Subject: Re: [PATCH] atmel: unregister_netdev() on error

From: Dan Carpenter <[email-masked]>
Date: Sat, 10 Jul 2010 16:12:04 +0200

On Sat, Jul 10, 2010 at 05:11:47PM +0400, Kulikov Vasiliy wrote:
> We must unregister registered device if probe_atmel_card() fails.

I think you hit send accidentally on this one?

>  	if (!probe_atmel_card(dev)) {
>  		unregister_netdev(dev);
		^^^^^^^^^^^^^^^^^^^^^^^

> -		goto err_out_res;
> +		goto err_out_unreg;
>  	}
>  
>  	netif_carrier_off(dev);
> @@ -1640,6 +1640,9 @@ struct net_device *init_atmel_card(unsigned short irq, unsigned long port,
>  
>  	return dev;
>  
> +err_out_unreg:
> +	unregister_netdev(dev);
	^^^^^^^^^^^^^^^^^^^^^^
> +

What the pants?  :P

regards,
dan carpenter

--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to [email-masked]
More majordomo info at  http://vger.kernel.org/majordomo-info.html