[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] xen/arm: gic-v3: Preserve ARE_NS when disabling the distributor


  • To: Mykola Kvach <xakep.amatop@xxxxxxxxx>
  • From: Luca Fancellu <Luca.Fancellu@xxxxxxx>
  • Date: Tue, 19 May 2026 20:31:08 +0000
  • Accept-language: en-GB, en-US
  • Arc-authentication-results: i=2; mx.microsoft.com 1; spf=pass (sender ip is 4.158.2.129) smtp.rcpttodomain=gmail.com smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=pass (signature was verified) header.d=arm.com; arc=pass (0 oda=1 ltdi=1 spf=[1,1,smtp.mailfrom=arm.com] dkim=[1,1,header.d=arm.com] dmarc=[1,1,header.from=arm.com])
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=arm.com; dmarc=pass action=none header.from=arm.com; dkim=pass header.d=arm.com; arc=none
  • Arc-message-signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=ggP6mE4pgsMMj14IvM+asEVHGETF/xyPvBsMDIMk9ks=; b=rHzE2up+jPPt5sws7m9PPXt8aCCmEuA+bSAUemTAF11q/eFWe2lCtyPbtrtES1icUQDuoqEfqBDx8ptEk3Yu9V0sqh1JOz0Ap551/T4SFLcAz0wyoAdunKoaLbAjyvgWcv9u5p4Iq+zFEcv863nHHRogZl5BMiFmlGAqiWhJJDZdVo8viiihudYooAuhOGFW4YPWudZVxH+pHl/6Dml9PoAjKh1f9BLxof/idUKuecT0TTvFAfeG1pe3s+85habjt65YJHI7yLpCTGbZa0lM77Y1RCLtsptYzZmneJp7b9CinFrQxiPghxz7d2FB5MjXIFhVFWpdcWH7P++rbmM2DQ==
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=ggP6mE4pgsMMj14IvM+asEVHGETF/xyPvBsMDIMk9ks=; b=rPT8I7nrAU5TgQQxeDAcQv3KBWSFZAR7mfN8fLVATQPbMZi6KVSX1rMV7QCk8jFN++PXdYwKI6bhMf5MHwu9+nD4Ug0M+Yw+HypazYbhGe6Lrjsd0lL7c8EftYcsBx/f849seevSC3HX0c1zrj8V2JoRCrV8xAirWOVquvOBdsSxgvJWfPvlP4svYRUb0EfIqgn5S9hYBhqXV5OdDnPn883E5MRF3EXS2Z2G6cKNGHNuY5HKj6/92t6i8DFqxd1Gm2YLIdlxyBiEazsU01SuOmYekXGE4DFGYhK0Q7D4RMHAyHGPhnaRxopu8C5v3nkQmaXY4mEVS+ltPnVFfiUsvA==
  • Arc-seal: i=2; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=pass; b=DxUuthYMAAuzAeWISwNH0Sz1d/4qy37lE7sc5SHsslNpOJtEiDfkq6py0MEli0wfoR/bS7ILRvGnmx/MA8cgBJXWW3d1XijcfEiAnUhKqFw+Cu4H0wwVsawSJ0ma63OLhgaBeX2tvHGtpWVFBS8Dgc+RU3QlcIFi+vRrfAdbSp76i0WIa6nY1J8KCbW0cXTBXvmfoq+XLfKaX+d3X7Sp4RhqQ/LPfttCBzxqVxw7LCU5OE9ec7AazfWOJ9zw19cJYXpqMtNH7EkJYwaPhglLL9g9ecdJmsjn6Ld3s51FRz91WN4gOKuY0+SwMaRUGbg4EM+65fy+mjxRH2hA6vkutg==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=Bbgm3pV9iFjKNhkGRrEdme2IGo1jSORLfNbwdJrIFj1vz5gAGXgrtw4U9oKgFqacKWuerZMUlaRVGVuHiV5jcsI2IUtismOhLm6/63aTcFKLablbfKcBU4JgJwsgfy9axyp/UZKbywnoPA/hs3AkQVTz7GzE0D28Wzqe5Zs4xbscBltUnvnIvE7DyBIasO3DL782uE/UEuBcwXn8ej0qg+GqPo9KggTsplCwwUmzg0NKNiKYc9O3cNF92j3pSLpOepAvo5/xrnOVkgiJNSccfYxGlOfc9R4IF+mdBf5BGR541lJjcegnJskldPHWOJRYU7etwb0wcieSgATGMx8PTg==
  • Authentication-results: eu.smtp.expurgate.cloud; dkim=pass header.s=selector1 header.d=arm.com header.i="@arm.com" header.h="From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck"; dkim=pass header.s=selector1 header.d=arm.com header.i="@arm.com" header.h="From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck"
  • Authentication-results-original: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
  • Cc: "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Mykola Kvach <mykola_kvach@xxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Bertrand Marquis <Bertrand.Marquis@xxxxxxx>, Michal Orzel <michal.orzel@xxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>, Oleksii Kurochko <oleksii.kurochko@xxxxxxxxx>
  • Delivery-date: Tue, 19 May 2026 20:32:40 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Nodisclaimer: true
  • Thread-index: AQHc55ylTZMtKVDVD0+QjroHtjvpLLYVzXqA
  • Thread-topic: [PATCH] xen/arm: gic-v3: Preserve ARE_NS when disabling the distributor

Hi Mykola,

> On 19 May 2026, at 15:31, Mykola Kvach <xakep.amatop@xxxxxxxxx> wrote:
> 
> From: Mykola Kvach <mykola_kvach@xxxxxxxx>
> 
> gicv3_dist_init() disables the distributor before reprogramming the
> global interrupt state. It used to do this by writing 0 to GICD_CTLR.
> 
> On a system where firmware has already enabled Non-secure affinity
> routing, a zero write clears the Non-secure view's GICD_CTLR.ARE_NS bit.
> Arm IHI 0069H.b, section 2.3.3 ("Changing affinity routing enables"),
> states that changing GICD_CTLR.ARE_NS from 1 to 0 is UNPREDICTABLE. The
> GICD_CTLR register description in section 12.9.4 carries the same rule
> for the ARE_NS field.
> 
> Preserve ARE_NS while clearing the group enable bits. If firmware left
> ARE_NS clear, the value written is still 0, preserving the existing
> initialization flow.
> 
> Fixes: bc183a0235e0 ("xen/arm: Add support for GIC v3")
> Signed-off-by: Mykola Kvach <mykola_kvach@xxxxxxxx>
> ---

Looks ok to me and aligned to the specifications, bit 4 is preserved on both
Armv8-A (ARE_NS) and Armv8-R (ARE).

Reviewed-by: Luca Fancellu <luca.fancellu@xxxxxxx>

Cheers,
Luca






 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.