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: <4922A93B.6060102@cn.fujitsu.com>
Date:	Tue, 18 Nov 2008 19:38:35 +0800
From:	Lai Jiangshan <laijs@...fujitsu.com>
To:	Nick Piggin <nickpiggin@...oo.com.au>
CC:	Andrew Morton <akpm@...ux-foundation.org>,
	Johannes Weiner <hannes@...xchg.org>,
	David Miller <davem@...emloft.net>,
	Dave Airlie <airlied@...il.com>,
	Paul Menage <menage@...gle.com>,
	kamezawa.hiroyu@...fujitsu.com,
	Balbir Singh <balbir@...ux.vnet.ibm.com>,
	Arjan van de Ven <arjan@...radead.org>,
	Jan Kara <jack@...e.cz>, Jes Sorensen <jes@....com>,
	KOSAKI Motohiro <kosaki.motohiro@...fujitsu.com>,
	dada1@...mosbay.com, Alexey Dobriyan <adobriyan@...il.com>,
	Jens Axboe <jens.axboe@...cle.com>,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>,
	Nick Piggin <npiggin@...e.de>,
	Al Viro <viro@...iv.linux.org.uk>,
	Rik van Riel <riel@...hat.com>,
	Pekka Enberg <penberg@...helsinki.fi>
Subject: Re: [PATCH V2 1/4] vmalloc: introduce vfree_atomic()

Nick Piggin wrote:
> On Tuesday 18 November 2008 19:51, Lai Jiangshan wrote:
>> fdtable and sysipc use vfree() in RCU callback. this patch
>> introduce vfree_atomic() for them.
> 
> AFAIKS, vfree is usable from atomic context? What am I missing?

Hi, Nick Piggin,

Sorry for misled you.

fdtable and sysipc use vfree() in RCU callback.(_but defer it by schedule_work()_)
current vfree() is not usable from atomic context, so this patches are worthy.

even if vfree() is usable from atomic context soon,
[PATCH 3/4] [PATCH 4/4] are still worthy now. Because these two patches are
independent from vfree().(just needs to be changed one or two lines
when vfree() is usable from atomic context)

I suggest we can use vfree_atomic() before vfree() is available
for atomic context. Because fdtable and sysipc need a grace way for
using RCU and vmalloc/vfree. (actually, fdtable and sysipc have implemented
they own "vfree_atomic()", but it's very ugly)

Thanx, Lai.

> Actually, one could argue that we don't want to perform such
> costly operations in the atomic context, however with lazy
> unmapping, vfree is very cheap now (amortized, at least).
>

I'm looking forward to vfree() is available for atomic context.

> But it should be much cheaper on average not to schedule this in
> another context.
> 
> If there was any concern about the TLB flush from atomic context,
> we should just defer the lazy flushing, rather than every single
> vunmap.
> 
> 
> 


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