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

Re: [PATCH] xen/arm: Enhance IPMMU-VMSA driver robustness and debug output


  • To: Jahan Murudi <jahan.murudi.zg@xxxxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
  • From: "Orzel, Michal" <michal.orzel@xxxxxxx>
  • Date: Mon, 23 Jun 2025 09:25:48 +0200
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none
  • 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=xQ8K5CW1iSp6wsw3fww2lA0NxfyiVxbhq2O0EC8zilU=; b=w3Qch6CSNaUGz32+XodX8lGFctrdYwANAHDodX/yJiJsD5E7eLMyng0Rq2sHUZMpgETNOSW5pkxMbh6hyJqZS0v2bL8+2CKplLzjH9P/2yeAyMbOhNXTmV1umX6F5j+EfXtcyaY1d4CnKODuo2bUIELdPRF19DoCMhGtqWArz6YkNKgC1AQZRo7YywtqOLbuiv0RoPEdABEMs891tM6ZpHDJbdR8LPRlJ1kkWcLD4/3udRsX8ZGfKF0s9EqBGzes+oMA+G2l5RdiPizXdfKjQUtYEhVAqsVphKm0KXB87wCqsudaFYcFRW4RXwQP2XEUA47sc/0x/HVAAadVRvHlIw==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=HzA04K424lka1oquFfBW2T/m6eQOk5i55rzQg6lK7vWaDad/v+NxutLd7Mn4AfMd2To+hhmN+YAQQH4wCL5DWZxlWk68t74rHbDH7JcXZZCSwSkztywZ+y8c6RoFmALaHoxHxrVi7Md/nYQkicJkACQVeMWPDf6ApLWVo0sfjJCSw2ys+B/JTQsHAPvewmltvLa48Mn0JJ29M7aYLz1+IM29cB3r2hJ4EVSJuK6O4IZV6I8Hzbr0KBZIeZY+Ma4DD5V57wZygFg4VLXxGHINuWxpUK4pQAKC4xREbG6qQqcZJlS1seMwGaawwwn0kdKVplLVwau7g7VB75GERYW3gA==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com;
  • Cc: Stefano Stabellini <sstabellini@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Bertrand Marquis <bertrand.marquis@xxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>
  • Delivery-date: Mon, 23 Jun 2025 07:26:05 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>


On 20/06/2025 12:31, Jahan Murudi wrote:
> - Fix typo in source comment ("you can found" -> "which can be found").
> - Add dsb(sy) after IMCTR write to ensure flush is complete before polling.
> - Add dev_info() log in ipmmu_device_reset() to indicate the number of 
> disabled contexts.
> 
> These changes improve memory operation ordering, code readability, and 
> runtime traceability
> for IPMMU on R-Car Gen3/Gen4 SoCs
> 
> Signed-off-by: Jahan Murudi <jahan.murudi.zg@xxxxxxxxxxx>
Acked-by: Michal Orzel <michal.orzel@xxxxxxx>

> ---
>  xen/drivers/passthrough/arm/ipmmu-vmsa.c | 6 +++++-
>  1 file changed, 5 insertions(+), 1 deletion(-)
> 
> diff --git a/xen/drivers/passthrough/arm/ipmmu-vmsa.c 
> b/xen/drivers/passthrough/arm/ipmmu-vmsa.c
> index d828d9cf6a..dac0dd6d46 100644
> --- a/xen/drivers/passthrough/arm/ipmmu-vmsa.c
> +++ b/xen/drivers/passthrough/arm/ipmmu-vmsa.c
> @@ -13,7 +13,7 @@
>   *
>   * Based on Linux's IPMMU-VMSA driver from Renesas BSP:
>   *    drivers/iommu/ipmmu-vmsa.c
> - * you can found at:
> + * which can be found at:
>   *    url: 
> git://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas-bsp.git
>   *    branch: v4.14.75-ltsi/rcar-3.9.6
>   *    commit: e206eb5b81a60e64c35fbc3a999b1a0db2b98044
> @@ -433,6 +433,8 @@ static void ipmmu_tlb_invalidate(struct ipmmu_vmsa_domain 
> *domain)
>      data |= IMCTR_FLUSH;
>      ipmmu_ctx_write_all(domain, IMCTR, data);
>  
> +    /* Force IMCTR write to complete before polling to avoid false 
> completion check. */
> +    dsb(sy);
Any clue why Linux (mainline) does not do that?

~Michal




 


Rackspace

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