From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=217.140.110.172 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796149191; b=n8pAjtlyI6h/2pzNh5R2jhyMI0GYZM0QRg4djPrHwGeffhrBqjL9a9biM9A0PhGZeUso BLUNjV4SUH0zT7/5IeWPiyhjDhsqmLUZlYXrxW67dvhNxzySZhQEYyzzUla1dQ3ysTwwT J7ZSB+zxMvHUQHLHvAr2Ixj2+PscURKUgs/d32HZk01A542ec29a5vPjQA7IfwgamMUwo tD0W3oxefdQ6/C1NTzFQwWfHNfq1Afg4m1D1Ko5IE6NtOgYFiXRmejobOBICvWHMoqfLF zsoOG2hEhW9s3mr+ZhmQaF+gOq4sX0EPk1U+UagEVjcBqHNTtwSf5IWg35F30c1lRRw== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796149191; h=DMARC-Filter:Received:Received:DKIM-Signature:From:To:Cc:Subject: Date:Message-ID:X-Mailer:In-Reply-To:References:MIME-Version: Content-Type:Content-Disposition:Content-Transfer-Encoding; bh=0jjNBLdFlYYs3wlt5ahg0c4VxMefT5Wljyw4qA+sPjI=; b=nMf+LFVj5gR6+eEptTzPK2i4xSvJZVOQQUM0YA3jL8Y6zpDkCf4XBKCtlKoDeAUzDaU8 9/vf72qYaBDLPhSK0utUuutnuZNAw88EXm7aMLLAvejbgYTHGLPTmXgjFwFCNMKG68vd9 e5vyGuQfFzonD2riTzf+9UJBDO63+6e9xx93DfUIqI4Y6gskttnw4eyOw6IcRZwlJWfzd EwLYZ4ozx/RFpG7oSFg0aHXbfHY/7C54wwlUkJfXJmoQYwql1xK44nKXpvqtHQxvaSW04 9bk7o+THCFES93Y6Gn/SQTugXo9Dp2G+sLiHjKgBLi2jhDvze1zHXOtjuWd76eo/cuw== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=arm.com; spf=pass smtp.mailfrom=arm.com; dkim=pass header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=foss header.b=gAJG6ikB; arc=none smtp.remote-ip=217.140.110.172 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id AF8C1606A31A for ; Tue, 1 Dec 2026 18:19:50 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org AF8C1606A31A Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key, unprotected) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=foss header.b=gAJG6ikB Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id EC6361516; Tue, 1 Dec 2026 10:19:46 -0800 (PST) Received: from LeoBrasDK.cambridge.arm.com (LeoBrasDK.cambridge.arm.com [10.2.212.21]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 04E1F3F86F; Tue, 1 Dec 2026 10:19:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=arm.com; s=foss; t=1796149189; bh=K1t2QR4crzM/njMEMmc7fR/9+XuXencrJ9HGqRnGgW0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=gAJG6ikBWwWxrxlPkldlI8pjricCiCBirzNEuAsjWNV0zaFvL0FUXmsKxk4/3MgIw uF60w6ZABBPDAE/0R4Cu1cvvFXX7PoA1O4NsHstGgmzg+vjyvXwFZtRObeDXH6WGSV X1n7woJSwPczmeA/jX/juMlSlchLzd9PMnLaZWbQ= From: Leonardo Bras To: Usama Arif Cc: Leonardo Bras , ljs@kernel.org, maz@kernel.org, oupton@kernel.org, fuad.tabba@linux.dev, joey.gouly@arm.com, seiden@linux.ibm.com, suzuki.poulose@arm.com, yuzenghui@huawei.com, catalin.marinas@arm.com, will@kernel.org, mark.rutland@arm.com, kvmarm@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, riel@surriel.com, shakeel.butt@linux.dev, kernel-team@meta.com, rkeilty@meta.com, atish.patra@linux.dev, dgreid@meta.com Subject: Re: [PATCH v2] KVM: arm64: Size the stage-2 memcache from kvm_mmu_cache_min_pages() Date: Tue, 1 Dec 2026 18:19:42 +0000 Message-ID: X-Mailer: git-send-email 2.56.1 In-Reply-To: References: <20261130143039.867874-1-usama.arif@linux.dev> <73b7f0a4-9cee-4fad-ae61-667dafd035f9@linux.dev> <25bc8bdf-53b4-40ad-ad56-db71aedd0d23@linux.dev> X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: 8bit On Tue, Dec 01, 2026 at 12:46:22PM +0000, Leonardo Bras wrote: > On Mon, Nov 30, 2026 at 08:05:32PM +0000, Usama Arif wrote: [...] > > >> I tried your MULTIPLIER * min_pages version under QEMU with > > >> kvm-arm.mode=nested: 4K pages, an IPA limit of 52 bits, and a 40-bit > > >> IPA VM whose L1 runs an L2. In all six runs, across two tests, L2's > > >> first fault that needs a refill hits that WARN_ON_ONCE() and KVM_RUN > > >> fails with EIO. > > > > > > Out of curiosity, is it fully KVM, or are you using QEMU to emulate a > > > 4k-pagesize host? > > > > > > QEMU emulates the host. I don't have hardware with FEAT_NV2, so L0 is a > > 4K kernel booted with kvm-arm.mode=nested in qemu-system-aarch64 with > > TCG (-cpu max, virtualization=on). Only the NV tests ran that way, > > the numbers above are from the Grace host. > > > > Ah, I see your point. > The issue is that QEMU TCG is not really great for gathering performance > numbers :( > > I can try running the tests for you in a NV2-enabled machine, if that's ok > :) > Humm, but again, why do you need NV2? That path is tested on both user_mem_abort and gmem_abort, it could easily be tested by replacing the host kernel. Do you have any limitation replacing the host kernel? Thanks! Leo