Re: [PATCH] protect remove_proc_entry
- From: Steven Rostedt <rostedt@xxxxxxxxxxx>
- Date: Fri, 30 Dec 2005 17:11:40 -0500
On Fri, 2005-12-30 at 13:55 -0800, Mitchell Blank Jr wrote:
> Steven Rostedt wrote:
> > I've added a global remove_proc_lock to protect this section of code. I
> > was going to add a lock to proc_dir_entry so that the locking is only
> > cut down to the same parent, but since this function is called so
> > infrequently, why waste more memory then is needed. One global lock
> > should not cause too much of a headache here.
>
> Are you sure that it's the only place where we need guard ->subdir? It
> looks like proc_lookup() and proc_readdir() use the BLK when walking that
> list, so probably the best fix would be to use that lock everywhere else
> ->subdir is touched
Perhaps this is a good candidate to have the BKL removed from this
protection and replaced with a spin lock or something else. If I
remember, I'll look into that further.
-- Steve
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
- References:
- [Question] race condition with remove_proc_entry
- From: Steven Rostedt
- [PATCH] protect remove_proc_entry
- From: Steven Rostedt
- Re: [PATCH] protect remove_proc_entry
- From: Mitchell Blank Jr
- [Question] race condition with remove_proc_entry
- Prev by Date: Re: system keeps freezing once every 24 hours / random apps crashing
- Next by Date: Re: [patch 00/2] improve .text size on gcc 4.0 and newer compilers
- Previous by thread: Re: [PATCH] protect remove_proc_entry
- Next by thread: Re: [PATCH] protect remove_proc_entry
- Index(es):
Relevant Pages
|
|