Received: by 2002:a05:7208:9594:b0:7e:5202:c8b4 with SMTP id gs20csp1778029rbb; Tue, 27 Feb 2024 00:12:28 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCUdq4ljjIL+bOSF8U+EIO40VY+JBWWN2HGYLku15d5lDg2Er0+x/Q11bPlme4fK+RXgSJAAtE2ydh5NHzlyynbRxVtupF0UPvTOGesiaA== X-Google-Smtp-Source: AGHT+IHu/8mJSykhAL8JPETBpvyCCVzo3UyYQM3ICMpg2H3QiABbijG6heFpggwB3ydqAWm1RR59 X-Received: by 2002:a17:906:a2cf:b0:a43:48aa:a68b with SMTP id by15-20020a170906a2cf00b00a4348aaa68bmr3200913ejb.77.1709021548399; Tue, 27 Feb 2024 00:12:28 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709021548; cv=pass; d=google.com; s=arc-20160816; b=DFYsq+OiKVpMs+YRZsk/V16p3UbvyHAtQvtb1EwMhZsXVsxosno4QNuyfWQYa1xMyQ YIxGUqF4mNYl2nHTAg86ph0XFCSHXIXHS9iiA+wsF0ejleSKkVUKUVKXQrwwZ+P1cqqO x/TPzuU7U5c20HR+cH7yVOz5dyzD3oFOdUXotMXi8iIZJD/9oGnBGXtOqWC1ufFH2929 DP6V2C8GDVlqHPYvCaY2eHPpoZi+Hcoz+ELVj+1MDeHCdpHbVZPLnoABP2PeFrWSj1dT gafrI5+3sro8gJ86YEze4qJBkG/rqOtSBMKMpdG8eLExkOWzLALGNCciYuYTSs2wr+Zt fiHQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=mime-version:list-unsubscribe:list-subscribe:list-id:precedence :user-agent:references:in-reply-to:subject:cc:to:from:message-id :date:dkim-signature; bh=Gs6hpzyKBp5WpS1O9tmyVuXzcMoqMG0aJaM4de6vflY=; fh=1daZthg/6gvCnUynrFLevp9+g9F0tJ6tG/jgmoFlakw=; b=dEqhXc6UDQGQl1tICUaR2Id+GfU2TqHIjSr33TgGyPomrAiBxtEA7JpiUTkuZYch/m IFA+uxZJNb8vqWOKWJLC5d+Je45g6oOgv76lY7QIMBTUeT7Z7ovC/QbzOHSmtk+IFtZo h1TAYglK57cEPhof97Wc8tvsb8fSIDqmC5KkfHbfigd+SLypNa9Ts768DWGTwFdW9huE W0KordlWDXmTIVbbKyATN3LLL8az8MAmLjCT/xfdOCU8H2sXZR8E3rN04kyplhCHj+IQ SWtCw+hZl8SwvjKQ34UMAL3FkdBoETBUr83CE7YJW/jmfXIyPA53VSl5tD+Y58TajJxV J3Ng==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="Nm/bGc92"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-82851-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-82851-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id y22-20020a170906471600b00a3e553fe35fsi518832ejq.918.2024.02.27.00.12.28 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 27 Feb 2024 00:12:28 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-82851-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="Nm/bGc92"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-82851-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-82851-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 2D6BE1F24DBD for ; Tue, 27 Feb 2024 08:12:28 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1073D56465; Tue, 27 Feb 2024 08:12:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="Nm/bGc92" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 32EB856441; Tue, 27 Feb 2024 08:12:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709021542; cv=none; b=ADeiX/HjwT2RYoHUcpfKMUhZIft4Sn+NCvAtwgIde3hq1yV8/GOpiMCJ+pfsM4vE6/NI8SkRokcLlPFHT4G5l55kQGk+OKAZWDNUGnAVL+xB/bwpW/Rtu/jybYc7vdbs0T2b91MRZ5SxOUSaIqnqcBlCL66Y1wPKsIiVnR8wxF0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709021542; c=relaxed/simple; bh=RzvSoN1d+y+H0+TLwarmN0FFOj8Wb4VWXo/kszcd3Lo=; h=Date:Message-ID:From:To:Cc:Subject:In-Reply-To:References: MIME-Version:Content-Type; b=ERR0qE9X44GSwbrYl75IUJK3wlt7dGFcydPvrgSVTE1CJL104kROq+wG5AGhdpGJQ2SifVmmPrdEzpAno6L056wRhYV1CtQZncZas4iFYUqa+v4eRTurYlQlOd6MQMmIXCJH4nHrX3ltwn+pWXcxJYEmRheLM9z2LJ5OG+Pf9yM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=Nm/bGc92; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id A3456C433F1; Tue, 27 Feb 2024 08:12:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1709021541; bh=RzvSoN1d+y+H0+TLwarmN0FFOj8Wb4VWXo/kszcd3Lo=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=Nm/bGc927EhmL4UobMryUyxB1RwBxVWWUAw7mA/nmxCYTHcfg38j0bzvwh6eugkza 5g3LqJegrd2xgP1RmSoLz+3kwlPJxNYTii3G3VjMdz/4EdXr/Tjnw9hrwzKnKwVvBn GBIsWx+U5N4Bw48gD3uAvJ9oNLxp90NblAluTCMYnt7KSXZxsIHdhNtk4s25I7YXsh NomaEDKCD2Dx0qAObiol8gQ5e5QMOSkhirr7JfqBR7WOjVNA43bb1JCb7RIijomfYN 07Q9/QuPjFIZRvZaD9yEvyvtBpPRT6QbX+OQq0OTWswcq4k8099ICUnY/+FTxSoWo2 qTi6CsOUVNCBg== Received: from ip-185-104-136-29.ptr.icomera.net ([185.104.136.29] helo=wait-a-minute.misterjones.org) by disco-boy.misterjones.org with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.95) (envelope-from ) id 1resZW-007AGt-Jj; Tue, 27 Feb 2024 08:12:18 +0000 Date: Tue, 27 Feb 2024 08:10:48 +0000 Message-ID: <874jdu9vjr.wl-maz@kernel.org> From: Marc Zyngier To: Wei-Lin Chang Cc: oliver.upton@linux.dev, james.morse@arm.com, suzuki.poulose@arm.com, yuzenghui@huawei.com, catalin.marinas@arm.com, will@kernel.org, linux-arm-kernel@lists.infradead.org, kvmarm@lists.linux.dev, linux-kernel@vger.kernel.org, sauravsc@amazon.com, eric.auger@redhat.com Subject: Re: [PATCH 1/1] KVM: arm64: Affinity level 3 support In-Reply-To: <20240227022708.795214-1-r09922117@csie.ntu.edu.tw> References: <86frxg3i6u.wl-maz@kernel.org> <20240227022708.795214-1-r09922117@csie.ntu.edu.tw> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM-LB/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL-LB/10.8 EasyPG/1.0.0 Emacs/28.2 (x86_64-pc-linux-gnu) MULE/6.0 (HANACHIRUSATO) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII X-SA-Exim-Connect-IP: 185.104.136.29 X-SA-Exim-Rcpt-To: r09922117@csie.ntu.edu.tw, oliver.upton@linux.dev, james.morse@arm.com, suzuki.poulose@arm.com, yuzenghui@huawei.com, catalin.marinas@arm.com, will@kernel.org, linux-arm-kernel@lists.infradead.org, kvmarm@lists.linux.dev, linux-kernel@vger.kernel.org, sauravsc@amazon.com, eric.auger@redhat.com X-SA-Exim-Mail-From: maz@kernel.org X-SA-Exim-Scanned: No (on disco-boy.misterjones.org); SAEximRunCond expanded to false On Tue, 27 Feb 2024 02:27:08 +0000, Wei-Lin Chang wrote: > > On Sun, 25 Feb 2024 11:19:05 +0000, > Marc Zyngier wrote: [...] > > I can see multiple problems with this: > > > > - this is the host state, which shouldn't necessarily represent the > > guest state. It should be possible to restore a VM that have a > > different A3V value and still have the same guarantees. There is > > however a small nit around ICV_CTLR_EL1.A3V, which would require > > trapping to emulate the A3V bit. > > > > - this assumes GICv3, which is definitely not universal (we support > > GICv2, for which no such restriction actually exists). > > > > Finally, I don't see VM save/restore being addressed here, and I > > suspect it hasn't been looked at. > > > > Overall, this patch does too many things, and it should be split in > > discrete changes. I also want to see an actual justification for Aff3 > > support. And if we introduce it, it must be fully virtualised > > (independent of the A3V support on the host). > > Hi Marc, > > Really appreciate for the feedback. I think I understand most of your > comments and agree with them. It appears that I don't fully understand > the changes that I am doing with this. Thanks for explaining. I hope this doesn't deter you from working on this feature. I'll happily answer questions and discuss the above points. Thanks, M. -- Without deviation from the norm, progress is not possible.