lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20090217093805.GB31323@wotan.suse.de>
Date:	Tue, 17 Feb 2009 10:38:05 +0100
From:	Nick Piggin <npiggin@...e.de>
To:	Peter Zijlstra <peterz@...radead.org>
Cc:	Edward Shishkin <edward.shishkin@...il.com>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Ryan Hope <rmh3093@...il.com>,
	Randy Dunlap <randy.dunlap@...cle.com>,
	linux-kernel@...r.kernel.org,
	ReiserFS Mailing List <reiserfs-devel@...r.kernel.org>
Subject: Re: [patch 2/4] vfs: add set_page_dirty_notag

On Tue, Feb 17, 2009 at 10:09:41AM +0100, Peter Zijlstra wrote:
> On Tue, 2009-02-17 at 01:43 +0300, Edward Shishkin wrote:
> 
> >  > How much performance gain do you see by avoiding that radix tree op? 
> >  > 
> > 
> > Nop. We want to use it with extended semantics.
> > All dirty pages are divided into 2 categories:
> > 
> > A) tagged in the radix tree (with PAGECACHE_TAG_DIRTY).
> > B) captured by atoms (usual linked lists).
> > 
> > reiser4_writepages() looks for pages of "A" in the radix tree
> > and moves them to "B". set_page_dirty_notag(), introduced by
> > my patch, is needed for pages of "B".
> > 
> > If "B" is empty, then we get the traditional semantics with
> > regular ->writepages().
> > 
> > That's all!
> 
> Ah, indeed. I had not considered such a scheme.

It is a great shame that filesystems are not properly notified
that a page may become dirty before the actual set_page_dirty
event (which is not allowed to fail and is called after the
page is already dirty).

This is a big problem I have with fsblock simply in trying to
make the memory allocation robust. page_mkwrite unfortunately
is racy and I've fixed problems there... the big problem though
is get_user_pages. Fixing that properly seems to require fixing
callers so it is not really realistic in the short term.

As such...
 
> > Add set_page_dirty_notag() to the core library to enable
> > extended functionality of radix tree attached to inode->i_mapping.
> > 
> > Signed-off-by: Edward Shishkin<edward.shishkin@...il.com>
> 
> Looks good to me
> 
> Acked-by: Peter Zijlstra <a.p.zijlstra@...llo.nl>

I'm fine with it too.

Acked-by: Nick Piggin <npiggin@...e.de>

You know... it wouldn't be terribly painful to introduce a new
pagecache radix tree tag for filesystem private use (doesn't bloat
the radix tree node size) if there is a strong need for it. But if
you have this workaround then I think it is also reasonable.

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ