From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from sinmsgout03.his.huawei.com (sinmsgout03.his.huawei.com [119.8.177.38]) (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 DA2A322D7B9 for ; Thu, 29 Jan 2026 12:25:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=119.8.177.38 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769689539; cv=none; b=oIuM15Oiwk+T+unMZj7hZYzPYtyjnzlnVeVQ4cq3h2RaUwOgPET8OyfH00npmorTjEfW0YQxljYgE6kRz14WC8Muo36HiRpP2DmqIfgfm/YYWP7LMeqlB9Ld8zaGSXvZgD4l9kl/O//PG8QpZmE9eQ7T5sk1LHqEtojY/pzg6zw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769689539; c=relaxed/simple; bh=m8ylvaq8h/DzsNq6ZhbNUFUDMUasrbfqOjyDlNFwl7I=; h=Date:From:To:CC:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=X27ZGuGcEXMIFxqmQ+RZA+w3n2ZXoLc2E2c+Si9T3JoMn4PqvdErsnvspyJsHjA65Y+vAOwDvB1UmFjVwHLWr6qmpaFTUMK9Mfu3/pamV10qGTyBCqWgW2B9mOduOc8BAjTK9tKHXi1dYji/YOzoL1Ry0+bRnXgZLeK/wHIcvM8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com; spf=pass smtp.mailfrom=huawei.com; dkim=pass (1024-bit key) header.d=huawei.com header.i=@huawei.com header.b=ViHzBtXw; arc=none smtp.client-ip=119.8.177.38 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=huawei.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=huawei.com header.i=@huawei.com header.b="ViHzBtXw" dkim-signature: v=1; a=rsa-sha256; d=huawei.com; s=dkim; c=relaxed/relaxed; q=dns/txt; h=From; bh=yO3/auPzmp7ReB1QnPMWLdhH/pZKTIU/CYkFbUdLmUE=; b=ViHzBtXwU5EOIYFIkOPA05+owiF//mmrmP1BYmKw0DM1FLVapAJxlTqV9B0DkdISfFagDj95F 7baaD+YkRydIaaRkvaXUImTJiABrjKe3zRC01Maqm2zoXeIip4yaSPVUwxcULRpLcWwmTU56Qs0 x1JPdN9kjUzu1P+wSCN32iA= Received: from frasgout.his.huawei.com (unknown [172.18.146.32]) by sinmsgout03.his.huawei.com (SkyGuard) with ESMTPS id 4f1yvw74DlzN0jj; Thu, 29 Jan 2026 20:22:52 +0800 (CST) Received: from mail.maildlp.com (unknown [172.18.224.83]) by frasgout.his.huawei.com (SkyGuard) with ESMTPS id 4f1yxw0zsDzHnGgq; Thu, 29 Jan 2026 20:24:36 +0800 (CST) Received: from dubpeml500005.china.huawei.com (unknown [7.214.145.207]) by mail.maildlp.com (Postfix) with ESMTPS id 974D140572; Thu, 29 Jan 2026 20:25:25 +0800 (CST) Received: from localhost (10.203.177.15) by dubpeml500005.china.huawei.com (7.214.145.207) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.11; Thu, 29 Jan 2026 12:25:24 +0000 Date: Thu, 29 Jan 2026 12:25:23 +0000 From: Jonathan Cameron To: Sascha Bischoff CC: "linux-arm-kernel@lists.infradead.org" , "kvmarm@lists.linux.dev" , "kvm@vger.kernel.org" , nd , "maz@kernel.org" , "oliver.upton@linux.dev" , Joey Gouly , Suzuki Poulose , "yuzenghui@huawei.com" , "peter.maydell@linaro.org" , "lpieralisi@kernel.org" , Timothy Hayes Subject: Re: [PATCH v4 36/36] KVM: arm64: gic-v5: Communicate userspace-driveable PPIs via a UAPI Message-ID: <20260129122523.00004bfd@huawei.com> In-Reply-To: <20260128175919.3828384-37-sascha.bischoff@arm.com> References: <20260128175919.3828384-1-sascha.bischoff@arm.com> <20260128175919.3828384-37-sascha.bischoff@arm.com> X-Mailer: Claws Mail 4.3.0 (GTK 3.24.42; x86_64-w64-mingw32) Precedence: bulk X-Mailing-List: kvm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-ClientProxiedBy: lhrpeml100012.china.huawei.com (7.191.174.184) To dubpeml500005.china.huawei.com (7.214.145.207) On Wed, 28 Jan 2026 18:08:35 +0000 Sascha Bischoff wrote: > GICv5 systems will likely not support the full set of PPIs. The > presence of any virtual PPI is tied to the presence of the physical > PPI. Therefore, the available PPIs will be limited by the physical > host. Userspace cannot drive any PPIs that are not implemented. > > Moreover, it is not desirable to expose all PPIs to the guest in the > first place, even if they are supported in hardware. Some devices, > such as the arch timer, are implemented in KVM, and hence those PPIs > shouldn't be driven by userspace, either. > > Provided a new UAPI: > KVM_DEV_ARM_VGIC_GRP_CTRL => KVM_DEV_ARM_VGIC_USERPSPACE_PPIs > > This allows userspace to query which PPIs it is able to drive via > KVM_IRQ_LINE. > > Additionally, introduce a check in kvm_vm_ioctl_irq_line() to reject > any PPIs not in the userspace mask. > > Signed-off-by: Sascha Bischoff Seems fine to me, but it's new ABI, so needs some careful review from others. Reviewed-by: Jonathan Cameron