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: <20190424072610.GF4038@hirez.programming.kicks-ass.net>
Date:   Wed, 24 Apr 2019 09:26:10 +0200
From:   Peter Zijlstra <peterz@...radead.org>
To:     Jiri Kosina <jikos@...nel.org>
Cc:     Dave Hansen <dave.hansen@...ux.intel.com>,
        Andy Lutomirski <luto@...nel.org>,
        Thomas Gleixner <tglx@...utronix.de>,
        Ingo Molnar <mingo@...hat.com>, Borislav Petkov <bp@...en8.de>,
        "H. Peter Anvin" <hpa@...or.com>, Joerg Roedel <jroedel@...e.de>,
        Frederic Weisbecker <fweisbec@...il.com>,
        Nicolai Stange <nstange@...e.de>, x86@...nel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] x86/mm: Remove in_nmi() warning from 64bit
 implementation of vmalloc_fault()

On Wed, Apr 24, 2019 at 09:04:57AM +0200, Jiri Kosina wrote:
> From: Jiri Kosina <jkosina@...e.cz>
> 
> In-NMI warnings have been added to vmalloc_fault() via ebc8827f75 ("x86: 
> Barf when vmalloc and kmemcheck faults happen in NMI") back in the time 
> when our NMI entry code could not cope with nested NMIs.
> 
> These days, it's perfectly fine to take a fault in NMI context and we 
> don't have to care about the fact that IRET from the fault handler might 
> cause NMI nesting.
> 
> This warning has already been removed from 32bit implementation of 
> vmalloc_fault() in 6863ea0cda8 ("x86/mm: Remove in_nmi() warning from 
> vmalloc_fault()"), but 64bit version was omitted.
> 
> Remove the bogus warning also from 64bit implementation of vmalloc_fault().

Cute; did you actually trigger this?

> Fixes: 6863ea0cda8 ("x86/mm: Remove in_nmi() warning from vmalloc_fault()")
> Reported-by: Nicolai Stange <nstange@...e.de>
> Signed-off-by: Jiri Kosina <jkosina@...e.cz>

Acked-by: Peter Zijlstra (Intel) <peterz@...radead.org>

> ---
>  arch/x86/mm/fault.c | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/arch/x86/mm/fault.c b/arch/x86/mm/fault.c
> index 667f1da36208..5eaf67e8314f 100644
> --- a/arch/x86/mm/fault.c
> +++ b/arch/x86/mm/fault.c
> @@ -359,8 +359,6 @@ static noinline int vmalloc_fault(unsigned long address)
>  	if (!(address >= VMALLOC_START && address < VMALLOC_END))
>  		return -1;
>  
> -	WARN_ON_ONCE(in_nmi());
> -
>  	/*
>  	 * Copy kernel mappings over when needed. This can also
>  	 * happen within a race in page table update. In the later
> 
> -- 
> Jiri Kosina
> SUSE Labs
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ