Re: NMI handling rework for x86

From: Dipankar Sarma (dipankar@in.ibm.com)
Date: Fri Nov 15 2002 - 01:10:12 EST


On Thu, Nov 14, 2002 at 11:40:04PM -0500, Zwane Mwaikambo wrote:
> What interrupt rate have you tested this at? SMP? Adding handlers at
> runtime? I'm still skeptical on how RCU protects you, but i'm RCU clueless...

The RCU part is fairly simple - you want to avoid having to acquire
a lock for every NMI event to walk the handler so you do it
lockfree. If a process running in a different CPU tries to
free an nmi handler, it removes it from the list, issues an
rcu callback (to be invoked after all CPUs have gone through
a context switch or executed user-level code ensuring that the
deleted nmi handler can't be running) and waits for completion of
the callback. The rcu callback handler wakes it up.
It is all hidden under list_add_rcu()/list_del_rcu() and __list_for_each_rcu().

Thanks

-- 
Dipankar Sarma  <dipankar@in.ibm.com> http://lse.sourceforge.net
Linux Technology Center, IBM Software Lab, Bangalore, India.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Fri Nov 15 2002 - 22:00:36 EST