lkml.org 
[lkml]   [2006]   [Jun]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch 0/5] [PATCH,RFC] vfs: per-superblock unused dentries list (2nd version)
On Mon, 19 Jun 2006 11:21:04 +1000
Neil Brown <neilb@suse.de> wrote:

> static void prune_dcache(int count, struct super_block *sb)
> +static void prune_dcache(int count, struct list_head *list)
> {
> + int have_list = list != NULL;
> + struct list_head alt_head;
> spin_lock(&dcache_lock);
> + if (list == NULL) {
> + /* use the dentry_unused list */
> + list_add(&alt_head, &dentry_unused);
> + list_del_init(&dentry_unused);
> + list = &alt_head;
> + }

This will make dentry_unused appear to be empty.

> for (; count ; count--) {
> struct dentry *dentry;
> struct list_head *tmp;
> @@ -405,23 +417,11 @@ static void prune_dcache(int count, stru
>
> cond_resched_lock(&dcache_lock);

And then it makes that apparent-emptiness globally visible.

Won't this cause concurrent unmounting or memory shrinking to malfunction?
-
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/

\
 
 \ /
  Last update: 2006-06-19 04:06    [W:0.130 / U:0.676 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site