From patchwork Fri Aug 30 22:59:54 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoffer Dall X-Patchwork-Id: 2852248 Return-Path: X-Original-To: patchwork-linux-arm@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 0BD29C0AB5 for ; Fri, 30 Aug 2013 23:01:11 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 33FBD20364 for ; Fri, 30 Aug 2013 23:01:10 +0000 (UTC) Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 369062031C for ; Fri, 30 Aug 2013 23:01:09 +0000 (UTC) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1VFXgV-0007pX-KQ; Fri, 30 Aug 2013 23:00:55 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1VFXgN-00050R-Bn; Fri, 30 Aug 2013 23:00:47 +0000 Received: from mail-pd0-f173.google.com ([209.85.192.173]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1VFXg5-0004x1-Hm for linux-arm-kernel@lists.infradead.org; Fri, 30 Aug 2013 23:00:30 +0000 Received: by mail-pd0-f173.google.com with SMTP id p10so2416451pdj.18 for ; Fri, 30 Aug 2013 16:00:07 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=qSb5DAyu7ISmamqGqm4/iF/pOJZLJoPlQ/JjlA/Bpac=; b=XBnc8cyd9ckcezmCQx3xEJeIKRNVQBmhJ2We3+9oTUEG1bFRX6pR8JXPNUQwEZ9wCT /SmtF84i0bfRsrCY2U3UXPke3rjiGYXYNlK5dB/QP4/c2lfHp/9heyBDGCUucSR3uE2J B8BIUznj3nk+2Z3Jik5PUcK0X41dK0gNPg6i0D96LS9C+0hZVINSkJa5GTTlyxJHnumX FxXQAbtcm1EEtEaxDyEbtqPR1nG02GidGkYMEmwhCX0UI9eiwC73ptfSK5MxKX3VMcdh mI2U7Qp5/jXBG/ymc7pEaAubl7ouhPZBvOC04lPr2oID7BdJzvVuxNzHESkrOAl/BX29 O6kQ== X-Gm-Message-State: ALoCoQlviDxCH9JURhm8Nv1nDcLMmnInyqmeCjZAp1LJnzdWdjmKEcQNf4Ibubwwz6XiyH+WBE5p X-Received: by 10.66.159.132 with SMTP id xc4mr13517918pab.27.1377903607479; Fri, 30 Aug 2013 16:00:07 -0700 (PDT) Received: from localhost.localdomain (c-67-169-183-77.hsd1.ca.comcast.net. [67.169.183.77]) by mx.google.com with ESMTPSA id om2sm241835pbc.30.1969.12.31.16.00.00 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 30 Aug 2013 16:00:06 -0700 (PDT) From: Christoffer Dall To: Gleb Natapov , Paolo Bonzini Subject: [PATCH 1/4] ARM: KVM: Fix kvm_set_pte assignment Date: Fri, 30 Aug 2013 15:59:54 -0700 Message-Id: <1377903597-18704-2-git-send-email-christoffer.dall@linaro.org> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1377903597-18704-1-git-send-email-christoffer.dall@linaro.org> References: <1377903597-18704-1-git-send-email-christoffer.dall@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130830_190029_697727_BF182EE6 X-CRM114-Status: GOOD ( 11.17 ) X-Spam-Score: -1.9 (-) Cc: linaro-kernel@lists.linaro.org, kvm@vger.kernel.org, patches@linaro.org, Christoffer Dall , kvmarm@lists.cs.columbia.edu, linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-6.3 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable 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 THe kvm_set_pte function was actually assigning the entire struct to the structure member, which should work because the structure only has that one member, but it is still not very nice. Acked-by: Marc Zyngier Signed-off-by: Christoffer Dall --- arch/arm/include/asm/kvm_mmu.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/include/asm/kvm_mmu.h b/arch/arm/include/asm/kvm_mmu.h index 472ac70..9b28c41 100644 --- a/arch/arm/include/asm/kvm_mmu.h +++ b/arch/arm/include/asm/kvm_mmu.h @@ -64,7 +64,7 @@ void kvm_clear_hyp_idmap(void); static inline void kvm_set_pte(pte_t *pte, pte_t new_pte) { - pte_val(*pte) = new_pte; + *pte = new_pte; /* * flush_pmd_entry just takes a void pointer and cleans the necessary * cache entries, so we can reuse the function for ptes.