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]
Date:	Mon, 7 Jul 2014 21:48:46 -0700
From:	Andrew Morton <akpm@...ux-foundation.org>
To:	Gioh Kim <gioh.kim@....com>
Cc:	Laura Abbott <lauraa@...eaurora.org>,
	Michal Nazarewicz <mina86@...a86.com>,
	Marek Szyprowski <m.szyprowski@...sung.com>,
	Joonsoo Kim <js1304@...il.com>,
	Alexander Viro <viro@...iv.linux.org.uk>,
	linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org,
	이건호 <gunho.lee@....com>,
	Gi-Oh Kim <gurugio@...il.com>
Subject: Re: [PATCH] [RFC] CMA: clear buffer-head lru before page migration

On Tue, 08 Jul 2014 13:44:04 +0900 Gioh Kim <gioh.kim@....com> wrote:

> 2014-07-08 ______ 7:52, Andrew Morton ___ ___:
> > On Fri, 04 Jul 2014 17:25:09 +0900 Gioh Kim <gioh.kim@....com> wrote:
> >
> >> From: Gioh Kim <gioh.kim@....com>
> >> Date: Fri, 4 Jul 2014 16:53:22 +0900
> >> Subject: [PATCH] [RFC] CMA: clear buffer-head lru before page migration
> >>
> >> When CMA try to migrate page, some buffer-heads can exist on lru.
> >> The bh on lru has non-zero count value so that it cannot be dropped
> >> even-if it is not used. We can drop only buffers related to the
> >> migrated page, but it can take long time more than dropping all
> >> because of searching list. There all buffers in lru are dropped.
> >>
> >> Signed-off-by: Laura Abbott <lauraa@...eaurora.org>
> >> Signed-off-by: Gioh Kim <gioh.kim@....com>
> >> ---
> >>   fs/buffer.c |   13 +++++++++++++
> >>   1 file changed, 13 insertions(+)
> >>
> >> diff --git a/fs/buffer.c b/fs/buffer.c
> >> index eba6e4f..4f11b7a 100644
> >> --- a/fs/buffer.c
> >> +++ b/fs/buffer.c
> >> @@ -3233,6 +3233,19 @@ int try_to_free_buffers(struct page *page)
> >>          if (PageWriteback(page))
> >>                  return 0;
> >>
> >> +#ifdef CONFIG_CMA
> >> +       /*
> >> +        * When CMA try to migrate page, some buffer-heads can exist on lru.
> >> +        * The bh on lru has non-zero count value so that it cannot
> >> +        * be dropped even-if it is not used.
> >> +        * We can drop only buffers related to the migrated page,
> >> +        * but it can take long time more than dropping all
> >> +        * because of searching list.
> >> +        * There all buffers in lru are dropped first.
> >> +        */
> >> +       invalidate_bh_lrus();
> >> +#endif
> >
> > No, this will be tremendously expensive.
> >
> > What I proposed is that CMA call invalidate_bh_lrus() right at the
> > outset.  Something along the lines of

Please do not top-post your email replies - it makes it very hard to
conduct a coherent discussion.

> It's my fault.
> I'm going to send another patch ASAP.

No, not "ASAP".  Such a patch will require careful testing on numerous
system configurations and workloads.  Take however much time it needs
to get it right.

--
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