On Fri, Apr 08, 2005 at 01:16:53AM +0200, Francois Romieu wrote:
> Paul E. McKenney <[EMAIL PROTECTED]> :
> > This patch changes calls to synchronize_kernel(), deprecated in the
> > earlier "Deprecate synchronize_kernel, GPL replacement" patch to
> > instead call the new synchronize_rcu() and synchronize_sched() APIs.
> [...]
> > diff -urpN -X dontdiff linux-2.6.12-rc1/drivers/net/r8169.c 
> > linux-2.6.12-rc1-bettersk/drivers/net/r8169.c
> > --- linux-2.6.12-rc1/drivers/net/r8169.c    Thu Mar 31 09:53:08 2005
> > +++ linux-2.6.12-rc1-bettersk/drivers/net/r8169.c   Fri Apr  1 21:41:38 2005
> > @@ -2385,7 +2385,7 @@ core_down:
> >     }
> >  
> >     /* Give a racing hard_start_xmit a few cycles to complete. */
> > -   synchronize_kernel();
> > +   synchronize_sched();  /* FIXME: should this be synchronize_irq()? */
> >  
> >     /*
> >      * And now for the 50k$ question: are IRQ disabled or not ?
> 
> (answering the FIXME)
> 
> The race with the irq is handled somewhere else. As the comment suggests,
> this part is racing with the hard_start_xmit() handler. If I read correctly
> net/core/dev.c::dev_queue_xmit, the code above simply needs the new
> synchronize_rcu().

That would be good!  In your reading of the code, did you verify that
all instances of calls to hard_start_xmit() are in fact under either
rcu_read_lock() or rcu_read_lock_bh()?

                                                        Thanx, Paul
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to