Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp3811105imm; Mon, 17 Sep 2018 03:42:55 -0700 (PDT) X-Google-Smtp-Source: ANB0VdYNgrwT2c2lULKQs99s7OPeZEF0+bs0sVrXj9QQMLFYO9Djeo+Bdb2SlDwq3dRuV6kptqxc X-Received: by 2002:a62:2b50:: with SMTP id r77-v6mr25127468pfr.51.1537180975388; Mon, 17 Sep 2018 03:42:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537180975; cv=none; d=google.com; s=arc-20160816; b=OYJMIVQ3HFlSRtAk8GzgRafuES8behAGV7WnwXNVV1aokGTvpchjn1Nl50bOOBb7eg UFx6kR/J3XZdXod6m1+dptKcLYzmQ9GYCD66pF9+2VvDj93eJDdR4yhWTfLZdxXGKAfU cR+Meydkko5kTEAC9Dki1kLo2VhDX2KOVym1go7sANj1cuGCpjCdLdaRGV6hjTKvavSO CFWxzvIfNjiu6oAWGTvW3RlIitMgsMe9q/jbvd8HsQf1rfTZ7TCrRqHgP3Usw5JH3JD1 cSox2ZoLrtyf8+PtB0jtLXDUy6VVrL0TvN7nwQzcgvbhsBg3ZPwAU9y13zFYgof8/f5i mNTA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=oCnyqRaxP/CMatkwOtLd+qTIA5bWe03uCvXIbGWYMAQ=; b=cv0KlXbR9woMRKfr1KsdTGFUHCY0SreONJuxFkFE+sKlLvoBTZBdpDkJ7Mf5C0+QQ0 sNjsfTIJPhseaWXvr7ARoozpd3aOuvNPOlHIR2PDGneYTH64JIxby9gYvqu/nukddFCH IurTF+GA99yb/u3T4uYMBwQXrPhMlCT30n11T1IeGxkIsbBYnI0/f/kytujbNMU9R5Ac ki2BMPdI08/rPT65aLlZVAviR7xIU1Q9s8VEwNFqAhn+7tHBJ7K8HNPYK89TmZmhmpOX BXeTmMFnRm8jO0njaaTTXBb96Jr2wYDNB0k8iRS6LIPuWwXPS7BGY9JLMDpq56XAVxy8 2MJg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h69-v6si15342829pfc.121.2018.09.17.03.42.40; Mon, 17 Sep 2018 03:42:55 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728080AbeIQQJQ (ORCPT + 99 others); Mon, 17 Sep 2018 12:09:16 -0400 Received: from usa-sjc-mx-foss1.foss.arm.com ([217.140.101.70]:56434 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726894AbeIQQJP (ORCPT ); Mon, 17 Sep 2018 12:09:15 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 4CE3B15B2; Mon, 17 Sep 2018 03:42:28 -0700 (PDT) Received: from en101.Emea.Arm.com (en101.emea.arm.com [10.4.13.23]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id BCCB33F5BD; Mon, 17 Sep 2018 03:42:25 -0700 (PDT) From: Suzuki K Poulose To: linux-arm-kernel@lists.infradead.org Cc: kvmarm@lists.cs.columbia.edu, kvm@vger.kernel.org, marc.zyngier@arm.com, cdall@kernel.org, eric.auger@redhat.com, pbonzini@redhat.com, rkrcmar@redhat.com, will.deacon@arm.com, catalin.marinas@arm.com, james.morse@arm.com, dave.martin@arm.com, julien.grall@arm.com, linux-kernel@vger.kernel.org, suzuki.poulose@arm.com Subject: [PATCH v5 02/18] kvm: arm/arm64: Remove spurious WARN_ON Date: Mon, 17 Sep 2018 11:41:24 +0100 Message-Id: <20180917104144.19188-3-suzuki.poulose@arm.com> X-Mailer: git-send-email 2.19.0 In-Reply-To: <20180917104144.19188-1-suzuki.poulose@arm.com> References: <20180917104144.19188-1-suzuki.poulose@arm.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On a 4-level page table pgd entry can be empty, unlike a 3-level page table. Remove the spurious WARN_ON() in stage_get_pud(). Acked-by: Christoffer Dall Acked-by: Marc Zyngier Reviewed-by: Eric Auger Signed-off-by: Suzuki K Poulose --- virt/kvm/arm/mmu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/virt/kvm/arm/mmu.c b/virt/kvm/arm/mmu.c index ee7ce8fa4a12..4a285d760ce0 100644 --- a/virt/kvm/arm/mmu.c +++ b/virt/kvm/arm/mmu.c @@ -1005,7 +1005,7 @@ static pud_t *stage2_get_pud(struct kvm *kvm, struct kvm_mmu_memory_cache *cache pud_t *pud; pgd = kvm->arch.pgd + stage2_pgd_index(addr); - if (WARN_ON(stage2_pgd_none(*pgd))) { + if (stage2_pgd_none(*pgd)) { if (!cache) return NULL; pud = mmu_memory_cache_alloc(cache); -- 2.19.0