From patchwork Thu Mar 5 12:12:33 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joerg Roedel X-Patchwork-Id: 10024 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n25CDCqE021677 for ; Thu, 5 Mar 2009 12:13:12 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754550AbZCEMNK (ORCPT ); Thu, 5 Mar 2009 07:13:10 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1754418AbZCEMNH (ORCPT ); Thu, 5 Mar 2009 07:13:07 -0500 Received: from tx2ehsobe003.messaging.microsoft.com ([65.55.88.13]:45553 "EHLO TX2EHSOBE006.bigfish.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753304AbZCEMM4 (ORCPT ); Thu, 5 Mar 2009 07:12:56 -0500 Received: from mail177-tx2-R.bigfish.com (10.9.14.240) by TX2EHSOBE006.bigfish.com (10.9.40.26) with Microsoft SMTP Server id 8.1.340.0; Thu, 5 Mar 2009 12:12:53 +0000 Received: from mail177-tx2 (localhost.localdomain [127.0.0.1]) by mail177-tx2-R.bigfish.com (Postfix) with ESMTP id 9690BBF810A; Thu, 5 Mar 2009 12:12:53 +0000 (UTC) X-BigFish: VPS11(z1857rzzzzzz32i62h) X-Spam-TCS-SCL: 1:0 Received: by mail177-tx2 (MessageSwitch) id 1236255172336610_11744; Thu, 5 Mar 2009 12:12:52 +0000 (UCT) Received: from ausb3extmailp01.amd.com (unknown [163.181.251.8]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail177-tx2.bigfish.com (Postfix) with ESMTP id 1DB2BCF0053; Thu, 5 Mar 2009 12:12:52 +0000 (UTC) Received: from ausb3twp02.amd.com ([163.181.250.38]) by ausb3extmailp01.amd.com (Switch-3.2.7/Switch-3.2.7) with ESMTP id n25CCkuw006458; Thu, 5 Mar 2009 06:12:49 -0600 X-WSS-ID: 0KG18L5-02-DEG-01 Received: from sausexbh1.amd.com (sausexbh1.amd.com [163.181.22.101]) by ausb3twp02.amd.com (Tumbleweed MailGate 3.5.1) with ESMTP id 2763B16A03C5; Thu, 5 Mar 2009 06:12:40 -0600 (CST) Received: from sausexmb1.amd.com ([163.181.3.156]) by sausexbh1.amd.com with Microsoft SMTPSVC(6.0.3790.3959); Thu, 5 Mar 2009 06:12:45 -0600 Received: from SDRSEXMB1.amd.com ([172.20.3.116]) by sausexmb1.amd.com with Microsoft SMTPSVC(6.0.3790.3959); Thu, 5 Mar 2009 06:12:45 -0600 Received: from seurexmb1.amd.com ([165.204.82.130]) by SDRSEXMB1.amd.com with Microsoft SMTPSVC(6.0.3790.3959); Thu, 5 Mar 2009 13:12:35 +0100 Received: from lemmy.amd.com ([165.204.85.93]) by seurexmb1.amd.com with Microsoft SMTPSVC(6.0.3790.3959); Thu, 5 Mar 2009 13:12:33 +0100 Received: by lemmy.amd.com (Postfix, from userid 41430) id C4F1B53935; Thu, 5 Mar 2009 13:12:33 +0100 (CET) From: Joerg Roedel To: Avi Kivity , Marcelo Tosatti CC: kvm@vger.kernel.org, linux-kernel@vger.kernel.org, Joerg Roedel Subject: [PATCH 6/6] kvm/x86/mmu: include PT_PAGE_SIZE_MASK in PT64_PERM_MASK Date: Thu, 5 Mar 2009 13:12:33 +0100 Message-ID: <1236255153-4432-7-git-send-email-joerg.roedel@amd.com> X-Mailer: git-send-email 1.5.6.4 In-Reply-To: <1236255153-4432-1-git-send-email-joerg.roedel@amd.com> References: <1236255153-4432-1-git-send-email-joerg.roedel@amd.com> X-OriginalArrivalTime: 05 Mar 2009 12:12:33.0858 (UTC) FILETIME=[AA37FA20:01C99D8B] MIME-Version: 1.0 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org We also need to do a remote tlb flush if the PSE bit changes. The pte_pfn should also change if this bit changes but we can't rely on that. So check this bit too to be on the save side. Signed-off-by: Joerg Roedel --- arch/x86/kvm/mmu.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c index 2a36f7f..055b181 100644 --- a/arch/x86/kvm/mmu.c +++ b/arch/x86/kvm/mmu.c @@ -121,7 +121,7 @@ module_param(oos_shadow, bool, 0644); (PAGE_MASK & ~((1ULL << (PAGE_SHIFT + PT32_LEVEL_BITS)) - 1)) #define PT64_PERM_MASK (PT_PRESENT_MASK | PT_WRITABLE_MASK | PT_USER_MASK \ - | PT64_NX_MASK) + | PT64_NX_MASK | PT_PAGE_SIZE_MASK) #define PFERR_PRESENT_MASK (1U << 0) #define PFERR_WRITE_MASK (1U << 1)