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: <20170426151451.GS3956@linux.vnet.ibm.com>
Date:   Wed, 26 Apr 2017 08:14:51 -0700
From:   "Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>
To:     Paolo Bonzini <pbonzini@...hat.com>
Cc:     linux-kernel@...r.kernel.org, kvm@...r.kernel.org,
        rkrcmar@...hat.com, ross.zwisler@...ux.intel.com, jack@...e.cz,
        linux-ext4@...r.kernel.org, tytso@....edu, josh@...htriplett.org,
        stable@...r.kernel.org
Subject: Re: [PATCH] kvm: async_pf: fix rcu_irq_enter() with irqs enabled

On Wed, Apr 26, 2017 at 04:56:26PM +0200, Paolo Bonzini wrote:
> native_safe_halt enables interrupts, and you just shouldn't
> call rcu_irq_enter() with interrupts enabled.  Reorder the
> call with the following local_irq_disable() to respect the
> invariant.
> 
> Reported-by: Ross Zwisler <ross.zwisler@...ux.intel.com>
> Cc: stable@...r.kernel.org
> Signed-off-by: Paolo Bonzini <pbonzini@...hat.com>

Acked-by: Paul E. McKenney <paulmck@...ux.vnet.ibm.com>

> ---
>  arch/x86/kernel/kvm.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/x86/kernel/kvm.c b/arch/x86/kernel/kvm.c
> index 14f65a5f938e..2a7835932b71 100644
> --- a/arch/x86/kernel/kvm.c
> +++ b/arch/x86/kernel/kvm.c
> @@ -161,8 +161,8 @@ void kvm_async_pf_task_wait(u32 token)
>  			 */
>  			rcu_irq_exit();
>  			native_safe_halt();
> -			rcu_irq_enter();
>  			local_irq_disable();
> +			rcu_irq_enter();
>  		}
>  	}
>  	if (!n.halted)
> -- 
> 2.9.3
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ