From patchwork Mon Aug 4 07:52:40 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bharat Bhushan X-Patchwork-Id: 4667271 Return-Path: X-Original-To: patchwork-kvm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 513FFC0338 for ; Mon, 4 Aug 2014 07:55:34 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 55D24201E4 for ; Mon, 4 Aug 2014 07:55:33 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 42EA420108 for ; Mon, 4 Aug 2014 07:55:32 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751407AbaHDHz2 (ORCPT ); Mon, 4 Aug 2014 03:55:28 -0400 Received: from mail-by2lp0244.outbound.protection.outlook.com ([207.46.163.244]:29268 "EHLO na01-by2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1750941AbaHDHz1 (ORCPT ); Mon, 4 Aug 2014 03:55:27 -0400 Received: from BN3PR0301CA0004.namprd03.prod.outlook.com (25.160.180.142) by DM2PR0301MB0752.namprd03.prod.outlook.com (25.160.97.148) with Microsoft SMTP Server (TLS) id 15.0.995.14; Mon, 4 Aug 2014 07:55:23 +0000 Received: from BN1AFFO11FD045.protection.gbl (2a01:111:f400:7c10::152) by BN3PR0301CA0004.outlook.office365.com (2a01:111:e400:4000::14) with Microsoft SMTP Server (TLS) id 15.0.995.14 via Frontend Transport; Mon, 4 Aug 2014 07:55:23 +0000 Received: from az84smr01.freescale.net (192.88.158.2) by BN1AFFO11FD045.mail.protection.outlook.com (10.58.53.60) with Microsoft SMTP Server (TLS) id 15.0.990.10 via Frontend Transport; Mon, 4 Aug 2014 07:55:22 +0000 Received: from kvm.ap.freescale.net (kvm.ap.freescale.net [10.232.14.24]) by az84smr01.freescale.net (8.14.3/8.14.0) with ESMTP id s747tB8m028677; Mon, 4 Aug 2014 00:55:20 -0700 From: Bharat Bhushan To: , CC: , , , Bharat Bhushan Subject: [PATCH 3/5] KVM: PPC: BOOKE: Allow guest to change MSR_DE Date: Mon, 4 Aug 2014 13:22:40 +0530 Message-ID: <1407138762-25531-3-git-send-email-Bharat.Bhushan@freescale.com> X-Mailer: git-send-email 1.9.3 In-Reply-To: <1407138762-25531-1-git-send-email-Bharat.Bhushan@freescale.com> References: <1407138762-25531-1-git-send-email-Bharat.Bhushan@freescale.com> X-EOPAttributedMessage: 0 X-Forefront-Antispam-Report: CIP:192.88.158.2; CTRY:US; IPV:CAL; IPV:NLI; EFV:NLI; SFV:NSPM; SFS:(6009001)(189002)(199002)(50466002)(102836001)(36756003)(50986999)(19580405001)(31966008)(74502001)(106466001)(6806004)(77982001)(4396001)(44976005)(105606002)(46102001)(92726001)(95666004)(83322001)(50226001)(85306004)(74662001)(19580395003)(81156004)(68736004)(81342001)(104166001)(99396002)(69596002)(76482001)(87286001)(47776003)(81542001)(48376002)(26826002)(76176999)(107046002)(21056001)(229853001)(97736001)(62966002)(85852003)(79102001)(104016003)(64706001)(77156001)(83072002)(80022001)(89996001)(20776003)(88136002)(93916002)(86362001)(84676001)(92566001)(87936001); DIR:OUT; SFP:; SCL:1; SRVR:DM2PR0301MB0752; H:az84smr01.freescale.net; FPR:; MLV:ovrnspm; PTR:InfoDomainNonexistent; MX:1; LANG:en; MIME-Version: 1.0 X-Microsoft-Antispam: BCL:0;PCL:0;RULEID: X-Forefront-PRVS: 0293D40691 Received-SPF: Fail (protection.outlook.com: domain of freescale.com does not designate 192.88.158.2 as permitted sender) receiver=protection.outlook.com; client-ip=192.88.158.2; helo=az84smr01.freescale.net; Authentication-Results: spf=fail (sender IP is 192.88.158.2) smtp.mailfrom=Bharat.Bhushan@freescale.com; X-OriginatorOrg: freescale.com Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Spam-Status: No, score=-7.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This patch changes the default behavior of MSRP_DEP, that is guest is not allowed to change the MSR_DE, to guest can change MSR_DE. When userspace is debugging guest then it override the default behavior and set MSRP_DEP. This stops guest to change MSR_DE when userspace is debugging guest. Signed-off-by: Bharat Bhushan --- arch/powerpc/kvm/e500mc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/kvm/e500mc.c b/arch/powerpc/kvm/e500mc.c index 164bad2..000cf82 100644 --- a/arch/powerpc/kvm/e500mc.c +++ b/arch/powerpc/kvm/e500mc.c @@ -194,7 +194,7 @@ int kvmppc_core_vcpu_setup(struct kvm_vcpu *vcpu) #ifdef CONFIG_64BIT vcpu->arch.shadow_epcr |= SPRN_EPCR_ICM; #endif - vcpu->arch.shadow_msrp = MSRP_UCLEP | MSRP_DEP | MSRP_PMMP; + vcpu->arch.shadow_msrp = MSRP_UCLEP | MSRP_PMMP; vcpu->arch.eplc = EPC_EGS | (vcpu->kvm->arch.lpid << EPC_ELPID_SHIFT); vcpu->arch.epsc = vcpu->arch.eplc;