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:	Thu, 12 Feb 2009 21:40:03 +1100
From:	Nick Piggin <nickpiggin@...oo.com.au>
To:	miaox@...fujitsu.com
Cc:	Paul Menage <menage@...gle.com>, Paul Jackson <pj@....net>,
	Andrew Morton <akpm@...ux-foundation.org>, mingo@...e.hu,
	linux-kernel@...r.kernel.org, cl@...ux-foundation.org,
	Derek Fults <dfults@....com>
Subject: Re: [PATCH] cpuset: fix allocating page cache/slab object on the unallowed node when memory spread is set

On Thursday 12 February 2009 19:27:16 Miao Xie wrote:
> on 2009-2-12 9:55 Nick Piggin wrote:
> > On Thursday 12 February 2009 12:19:11 Paul Menage wrote:
> >> On Wed, Feb 11, 2009 at 4:54 PM, Nick Piggin <nickpiggin@...oo.com.au>
> >
> > wrote:
> >>> It would be possible, depending on timing, for the allocating thread to
> >>> see either pre or post mems_allowed even if access was fully locked.
> >>
> >> Right - seeing either the pre set or the post set is fine.
> >>
> >>> The only difference is that a partially changed mems_allowed could be
> >>> seen. But what does this really mean? Some combination of the new and
> >>> the old nodes. I don't think this is too much of a problem.
> >>
> >> But if the old and new nodes are disjoint, that could lead to seeing no
> >> nodes.
> >
> > Well we could structure updates as setting all new allowed nodes,
> > then clearing newly disallowed ones.
>
> But it still has the other problem. such as:
> Task1							Task2
> get_page_from_freelist()				while(1) {
> {
> 	for_each_zone_zonelist_nodemask() {
> 								change Task1's mems_allowed
> 		if (!cpuset_zone_allowed_softwall())
> 			goto try_next_zone;
> try_next_zone:
> 		...
> 	}
> }							}
>
> In the extreme case, Task1 will be completely unable to allocate memory
> at worst. At least, it will lead to the delay of allocate pages. Though
> the probability of this case is very low, we have to take into account.

Hmm, but a task with that permission could kill task1 in a number
of ways. Is it really worth worrying about?

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