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:	Wed, 3 Jun 2015 15:42:04 +0200
From:	Michal Hocko <mhocko@...e.cz>
To:	Tetsuo Handa <penguin-kernel@...ove.SAKURA.ne.jp>
Cc:	akpm@...ux-foundation.org, linux-mm@...ck.org, david@...morbit.com,
	neilb@...e.de, hannes@...xchg.org, viro@...iv.linux.org.uk,
	mgorman@...e.de, riel@...hat.com, linux-kernel@...r.kernel.org,
	linux-fsdevel@...r.kernel.org
Subject: Re: [RFC 0/2] mapping_gfp_mask from the page fault path

On Wed 03-06-15 22:04:22, Tetsuo Handa wrote:
[...]
> Michal Hocko wrote:
> > Initialize the default to (mapping_gfp_mask | GFP_IOFS) because this
> > should be safe from the page fault path normally. Why do we care
> > about mapping_gfp_mask at all then? Because this doesn't hold only
> > reclaim protection flags but it also might contain zone and movability
> > restrictions (GFP_DMA32, __GFP_MOVABLE and others) so we have to respect
> > those.
> 
> [2/2] says that mapping_gfp_mask(mapping) might contain bits which are not
> in !GFP_KERNEL. If we do
> 
>   GFP_KERNEL & mapping_gfp_mask(mapping)
> 
> we will drop such bits and will cause problems.

No we won't.

> Thus, "GFP_KERNEL"
> in patch [1/1] should be replaced with "mapping_gfp_mask(mapping)" than
> "GFP_KERNEL & mapping_gfp_mask(mapping)" ?

Those gfp_masks are for LRU handling and that is GFP_KERNEL by
default. We only need to drop those which are not compatible with
mapping_gfp_mask. We do not care about __GFP_MOVABLE, GFP_DMA32 etc...
-- 
Michal Hocko
SUSE Labs
--
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