tech-net archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: if_txtimer API to replace (*if_watchdog)()



> On Jan 23, 2020, at 8:10 AM, Andrew Doran <ad%netbsd.org@localhost> wrote:
> 
> How about permitting that but require that the lock is taken again before
> return back to if_txtimer_tick().  Would it be a big pessimisation?  If
> you're resetting the interface I guess not.

Well, it's not the only asymmetry... in the "timer expired" case, if_txtimer_tick() also does not reschedule the callout (it relies on the callback's error handler to decide if that's appropriate).  Basically, "timer expired" == "driver handles the situation".  It just seems weird and redundant to require the callback to reacquire the lock just to have if_txtimer_tick() do nothing with it other than release it.

-- thorpej



Home | Main Index | Thread Index | Old Index