From patchwork Fri Aug 9 03:41:58 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoffer Dall X-Patchwork-Id: 2841653 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 AECD6BF546 for ; Fri, 9 Aug 2013 03:42:38 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id D883120498 for ; Fri, 9 Aug 2013 03:42:37 +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 E8DDE20490 for ; Fri, 9 Aug 2013 03:42:36 +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 1V7day-0003jB-Nz; Fri, 09 Aug 2013 03:42:33 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1V7dau-0001Sj-UU; Fri, 09 Aug 2013 03:42:28 +0000 Received: from mail-pd0-f169.google.com ([209.85.192.169]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1V7das-0001RZ-Is for linux-arm-kernel@lists.infradead.org; Fri, 09 Aug 2013 03:42:26 +0000 Received: by mail-pd0-f169.google.com with SMTP id r10so62142pdi.28 for ; Thu, 08 Aug 2013 20:42:05 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=uye8Sy1dpdupwfGL3lNwSTuB90L+x6nVeLC7tkKX7Rk=; b=Ypi6E6Kp8XDvtDbxYVqSxxicl4Zw0Aj+tY5VMLJb7OCDDPr+iV45LSfnXK979v1QOt 5bAQYrxcmNzQrqJR7MO67mxHs0wR0Mt+hzTVXpNTFRbhPUC7fdUB0GUlg8XY7hC1U0SC E4i06sdUGb97FNHUlZyOkrVUlnp6bnf4Ww6TY2esR3WpoSFy/U9JKg4tByeQBd8rCbTm iFMNQtnkLfxcqdeLbBkvsAfRF0FpuJOmevEkj7YSO4nCXbfwPM9q4e34WvAkH/2pY41I u7wwA5vmS0Df6FF2JPBj3oRJL3nAkKq0PKw306VWe4UpP72NNhZdmnJk2K5Z9s9fH9SG mPxA== X-Gm-Message-State: ALoCoQn5CGFcUiSft9oGuNGWyFwGd+lPG+hDeiTQ727MhkeSx1kQWhQK0pOYIYuzwF/LEDMFL2aK X-Received: by 10.66.254.41 with SMTP id af9mr9050881pad.174.1376019725753; Thu, 08 Aug 2013 20:42:05 -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 nv6sm17449679pbc.6.2013.08.08.20.42.03 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 08 Aug 2013 20:42:04 -0700 (PDT) From: Christoffer Dall To: kvmarm@lists.cs.columbia.edu Subject: [PATCH] ARM: KVM: Fix kvm_set_pte assignment Date: Thu, 8 Aug 2013 20:41:58 -0700 Message-Id: <1376019718-19378-1-git-send-email-christoffer.dall@linaro.org> X-Mailer: git-send-email 1.7.10.4 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130808_234226_768207_ED80F225 X-CRM114-Status: GOOD ( 11.16 ) X-Spam-Score: 0.6 (/) Cc: Christoffer Dall , linaro-kernel@lists.linaro.org, linux-arm-kernel@lists.infradead.org, kvm@vger.kernel.org, patches@linaro.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=-1.7 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, SUSPICIOUS_RECIPS, UNPARSEABLE_RELAY autolearn=no 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. 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.