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: <9f77b568-d86c-47db-f7a3-ddb931f33af0@linux.intel.com>
Date:   Fri, 16 Feb 2018 12:00:38 -0800
From:   Dave Hansen <dave.hansen@...ux.intel.com>
To:     Nadav Amit <nadav.amit@...il.com>
Cc:     LKML <linux-kernel@...r.kernel.org>,
        "open list:MEMORY MANAGEMENT" <linux-mm@...ck.org>,
        Andy Lutomirski <luto@...nel.org>,
        Linus Torvalds <torvalds@...ux-foundation.org>,
        keescook@...gle.com, Hugh Dickins <hughd@...gle.com>,
        Juergen Gross <jgross@...e.com>, x86@...nel.org
Subject: Re: [PATCH 2/3] x86/mm: introduce __PAGE_KERNEL_GLOBAL

On 02/16/2018 11:54 AM, Nadav Amit wrote:
>> But I don't really want to hide that gunk in a macro like that.  It
>> might make more sense as a static inline.  I'll give that a shot and resent.
> Since determining whether PTI is on is done in several places in the kernel,
> maybe there should a single function to determine whether PTI is on,
> something like:
> 
> static inline bool is_pti_on(void)
> {
> 	return IS_ENABLED(CONFIG_PAGE_TABLE_ISOLATION) && 
> 		static_cpu_has(X86_FEATURE_PTI);
> }

We should be able to do it with disabled-features.h and the X86_FEATURE
bit.  I'll look into it.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ