From patchwork Fri Sep 26 13:16:37 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoffer Dall X-Patchwork-Id: 37970 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wi0-f197.google.com (mail-wi0-f197.google.com [209.85.212.197]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id B7E61202DB for ; Fri, 26 Sep 2014 13:20:17 +0000 (UTC) Received: by mail-wi0-f197.google.com with SMTP id ho1sf5676946wib.8 for ; Fri, 26 Sep 2014 06:20:16 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:subject:date:message-id :in-reply-to:references:cc:precedence:list-id:list-unsubscribe :list-archive:list-post:list-help:list-subscribe:mime-version:sender :errors-to:x-original-sender:x-original-authentication-results :mailing-list:content-type:content-transfer-encoding; bh=HvGN/kp+5QZLZBBl66Bl+Tmm1XxgxGhZLuApifPauqI=; b=goz+yBKoB8XNoH4DEGpdBlvJ+o84yGb8+qpnd6mhHguYR7gv60j9Zc3XhzowfOVkhO fyG7EdQAySIbkJT0lV2ljxW4w4qAwhaSLunKpRZBWvcNlsuB2jdCHy/vwIjuTamblriE HtabTqKK3zsWhbGzbFjFcOdzUEKOAZUwe+xthezqL0RricRdW+Im2nLUinXYZdeef3rD p0/njA6AvVqc5vtPBdYxZG/f8GclScxHU+8yWm3o3kMJvpKpYy7s3cAphNpP3GWLyYZO bOYw7INXTY9vq/O/Z0szWVbPUFluqqM0sQ+8AtlfHcuZvpZnleVdOjJdm8uBKoE7GmJf XiHQ== X-Gm-Message-State: ALoCoQmDGFgCpFpWq6PLlJSPqyORjyWMelIlHODZSGcPiBrEBY/OQBDqjRD5ks43NUO6QHfVvEye X-Received: by 10.112.182.8 with SMTP id ea8mr508353lbc.11.1411737616922; Fri, 26 Sep 2014 06:20:16 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.197.68 with SMTP id is4ls72593lac.6.gmail; Fri, 26 Sep 2014 06:20:16 -0700 (PDT) X-Received: by 10.152.4.194 with SMTP id m2mr20532555lam.63.1411737616766; Fri, 26 Sep 2014 06:20:16 -0700 (PDT) Received: from mail-lb0-f175.google.com (mail-lb0-f175.google.com [209.85.217.175]) by mx.google.com with ESMTPS id ba3si7134293lbc.92.2014.09.26.06.20.16 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 26 Sep 2014 06:20:16 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.175 as permitted sender) client-ip=209.85.217.175; Received: by mail-lb0-f175.google.com with SMTP id w7so8671053lbi.6 for ; Fri, 26 Sep 2014 06:20:16 -0700 (PDT) X-Received: by 10.112.62.200 with SMTP id a8mr19155883lbs.34.1411737616678; Fri, 26 Sep 2014 06:20:16 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.130.169 with SMTP id of9csp59319lbb; Fri, 26 Sep 2014 06:20:15 -0700 (PDT) X-Received: by 10.70.87.134 with SMTP id ay6mr40560242pdb.68.1411737615214; Fri, 26 Sep 2014 06:20:15 -0700 (PDT) Received: from bombadil.infradead.org (bombadil.infradead.org. [2001:1868:205::9]) by mx.google.com with ESMTPS id kf2si9144003pad.211.2014.09.26.06.20.14 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 26 Sep 2014 06:20:15 -0700 (PDT) Received-SPF: none (google.com: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org does not designate permitted sender hosts) client-ip=2001:1868:205::9; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1XXVQB-0003UP-W8; Fri, 26 Sep 2014 13:18:52 +0000 Received: from mail-la0-f43.google.com ([209.85.215.43]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1XXVPP-0002aN-Pr for linux-arm-kernel@lists.infradead.org; Fri, 26 Sep 2014 13:18:04 +0000 Received: by mail-la0-f43.google.com with SMTP id gb8so4888358lab.2 for ; Fri, 26 Sep 2014 06:17:42 -0700 (PDT) X-Received: by 10.112.14.199 with SMTP id r7mr19525605lbc.58.1411737462067; Fri, 26 Sep 2014 06:17:42 -0700 (PDT) Received: from localhost.localdomain (188-178-240-98-static.dk.customer.tdc.net. [188.178.240.98]) by mx.google.com with ESMTPSA id z4sm1876657laz.39.2014.09.26.06.17.40 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 26 Sep 2014 06:17:41 -0700 (PDT) From: Christoffer Dall To: Paolo Bonzini , Gleb Natapov Subject: [PATCH 04/27] KVM: ARM/arm64: fix broken __percpu annotation Date: Fri, 26 Sep 2014 15:16:37 +0200 Message-Id: <1411737420-9063-5-git-send-email-christoffer.dall@linaro.org> X-Mailer: git-send-email 2.0.0 In-Reply-To: <1411737420-9063-1-git-send-email-christoffer.dall@linaro.org> References: <1411737420-9063-1-git-send-email-christoffer.dall@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20140926_061804_028744_1ECD9928 X-CRM114-Status: GOOD ( 13.25 ) X-Spam-Score: -0.7 (/) X-Spam-Report: SpamAssassin version 3.4.0 on bombadil.infradead.org summary: Content analysis details: (-0.7 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [209.85.215.43 listed in list.dnswl.org] -0.0 RCVD_IN_MSPIKE_H3 RBL: Good reputation (+3) [209.85.215.43 listed in wl.mailspike.net] -0.0 SPF_PASS SPF: sender matches SPF record -0.0 RCVD_IN_MSPIKE_WL Mailspike good senders Cc: kvm@vger.kernel.org, Marc Zyngier , Will Deacon , 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.18-1 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+patch=linaro.org@lists.infradead.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: christoffer.dall@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.175 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 From: Will Deacon Running sparse results in a bunch of noisy address space mismatches thanks to the broken __percpu annotation on kvm_get_running_vcpus. This function returns a pcpu pointer to a pointer, not a pointer to a pcpu pointer. This patch fixes the annotation, which kills the warnings from sparse. Cc: Christoffer Dall Cc: Marc Zyngier Signed-off-by: Will Deacon Signed-off-by: Christoffer Dall --- arch/arm/kvm/arm.c | 2 +- arch/arm64/include/asm/kvm_host.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/kvm/arm.c b/arch/arm/kvm/arm.c index ac306b4..53ee31b 100644 --- a/arch/arm/kvm/arm.c +++ b/arch/arm/kvm/arm.c @@ -82,7 +82,7 @@ struct kvm_vcpu *kvm_arm_get_running_vcpu(void) /** * kvm_arm_get_running_vcpus - get the per-CPU array of currently running vcpus. */ -struct kvm_vcpu __percpu **kvm_get_running_vcpus(void) +struct kvm_vcpu * __percpu *kvm_get_running_vcpus(void) { return &kvm_arm_running_vcpu; } diff --git a/arch/arm64/include/asm/kvm_host.h b/arch/arm64/include/asm/kvm_host.h index 44094e5..50431d3 100644 --- a/arch/arm64/include/asm/kvm_host.h +++ b/arch/arm64/include/asm/kvm_host.h @@ -193,7 +193,7 @@ static inline int kvm_test_age_hva(struct kvm *kvm, unsigned long hva) } struct kvm_vcpu *kvm_arm_get_running_vcpu(void); -struct kvm_vcpu __percpu **kvm_get_running_vcpus(void); +struct kvm_vcpu * __percpu *kvm_get_running_vcpus(void); u64 kvm_call_hyp(void *hypfn, ...);