Subject: Re: [PATCH] atm: clip causes unregister hang

From: Stephen Hemminger <[email-masked]>
Date: Wed, 12 Apr 2006 13:15:27 -0700

On Thu, 13 Apr 2006 06:00:15 +1000
Herbert Xu <[email-masked]> wrote:

> Hi Stephen:
> 
> On Wed, Apr 12, 2006 at 12:45:33PM -0700, Stephen Hemminger wrote:
> >
> >  	/* ignore non-CLIP devices */
> > -	if (((struct net_device *) dev)->type != ARPHRD_ATM ||
> > -	    ((struct net_device *) dev)->hard_start_xmit != clip_start_xmit)
> > +	if (dev->type != ARPHRD_ATM || dev->hard_start_xmit != clip_start_xmit)
> >  		return NOTIFY_DONE;
> 
> I think we need to check whether atm_init_atmarp has been done before
> passing this point.  We also need to make sure that it doesn't get pulled
> out from under us while we're doing this.
> 
> Cheers,

If atm_init_atmarp has not been done, then to_atamarpd is a nop because
atmarpd == NULL.