From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754569AbbJ1FXI (ORCPT ); Wed, 28 Oct 2015 01:23:08 -0400 Received: from mail-ob0-f170.google.com ([209.85.214.170]:33464 "EHLO mail-ob0-f170.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751874AbbJ1FXF (ORCPT ); Wed, 28 Oct 2015 01:23:05 -0400 MIME-Version: 1.0 In-Reply-To: <1445996397-32703-4-git-send-email-pbonzini@redhat.com> References: <1445996397-32703-1-git-send-email-pbonzini@redhat.com> <1445996397-32703-4-git-send-email-pbonzini@redhat.com> From: Andy Lutomirski Date: Tue, 27 Oct 2015 22:22:44 -0700 Message-ID: Subject: Re: [PATCH 3/3] x86: context_tracking: avoid irq_save/irq_restore on kernel entry and exit To: Paolo Bonzini Cc: "linux-kernel@vger.kernel.org" , kvm list , Andy Lutomirski , Frederic Weisbecker , Rik van Riel , Paul McKenney Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Oct 27, 2015 at 6:39 PM, Paolo Bonzini wrote: > x86 always calls user_enter and user_exit with interrupt disabled. > Therefore, it is not necessary to check for exceptions, nor to > save/restore the IRQ state, when context tracking functions are > called by guest_enter and guest_exit. > > Use the previously introduced __context_tracking_entry and > __context_tracking_exit. x86 isn't ready for this yet. We could do a quick-and-dirty fix with explicit IRQs-on-and-off much protected by the static key, or we could just wait until I finish the syscall cleanup. I favor the latter, but you're all welcome to do the former and I'll review it. BTW, Frederic, I have a static key patch coming that I think you'll like. I'll send it tomorrow once I'm in front of a real computer. --Andy