Subject: Re: [PATCH] skfddi - convert to new pci model.

From: Alexander Viro <[email-masked]>
Date: Thu, 4 Dec 2003 19:59:16 -0500

On Thu, Dec 04, 2003 at 04:39:28PM -0800, Stephen Hemminger wrote:
> +	dev->irq = pdev->irq;
>  	dev->get_stats = &skfp_ctl_get_stats;
>  	dev->open = &skfp_open;
>  	dev->stop = &skfp_close;
> +	dev->init = &skfp_driver_init;

Ehh...  Don't do that, please.  net_device ->init() means trouble,
since getting failure from register_netdev() gives you no clue
whether it had failed before, during or after ->init().  Makes
for an interesting cleanup...

You can do that if required cleanup can be deduced from the state
of *dev after register_netdev() failure (e.g. if no cleanup is
ever needed), but generally it's less PITA to just call the
damn function directly before register_netdev() and leave ->init NULL.