lkml.org 
[lkml]   [2008]   [Jan]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] x86: Add a list for custom page fault handlers.
From
Date

On Sun, 2008-01-27 at 18:52 +0200, Pekka Paalanen wrote:

> +void unregister_page_fault_handler(struct pf_handler *old_pfh)
> +{
> + might_sleep();
> + spin_lock(&pf_handlers_writer);
> + hlist_del_rcu(&old_pfh->hlist);
> + spin_unlock(&pf_handlers_writer);
> + synchronize_rcu();
> +}
> +EXPORT_SYMBOL_GPL(unregister_page_fault_handler);

Could you remove that sync_rcu() call and put in the comments that the
calling function is to take care of proper freeing.

sync_rcu() is a _very_ expensive call, and oft time it is not needed in
favour of call_rcu().




\
 
 \ /
  Last update: 2008-01-27 22:07    [W:0.097 / U:0.088 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site