Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id DECC8EB64DD for ; Thu, 29 Jun 2023 20:02:19 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.557066.870091 (Exim 4.92) (envelope-from ) id 1qExpw-00049l-Po; Thu, 29 Jun 2023 20:01:52 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 557066.870091; Thu, 29 Jun 2023 20:01:52 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1qExpw-00049e-NC; Thu, 29 Jun 2023 20:01:52 +0000 Received: by outflank-mailman (input) for mailman id 557066; Thu, 29 Jun 2023 20:01:51 +0000 Received: from mail.xenproject.org ([104.130.215.37]) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1qExpv-00049Y-OW for xen-devel@lists.xenproject.org; Thu, 29 Jun 2023 20:01:51 +0000 Received: from xenbits.xenproject.org ([104.239.192.120]) by mail.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1qExpv-0006Qa-AJ; Thu, 29 Jun 2023 20:01:51 +0000 Received: from gw1.octic.net ([88.97.20.152] helo=[10.0.1.240]) by xenbits.xenproject.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1qExpv-0008Ck-4f; Thu, 29 Jun 2023 20:01:51 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=xen.org; s=20200302mail; h=Content-Transfer-Encoding:Content-Type:In-Reply-To:From: References:Cc:To:Subject:MIME-Version:Date:Message-ID; bh=5WDmSaeH4byCh/tPtHYG9Yuj8Q24M45GwU5agwKYVZM=; b=hZtLqGNKIVqIYv4cSr6g/Ar3rf qASsIub6S+ESGt9WpymM3/VJE3511PB+wAH9RAyTyiO7PebSp76v1SB1n/Txl+8iBJEutaYVlqA5K iiSCdePE6KSLTrLURoTxMVkO5xjKEACQmuhkt3CPx7E839yYvOW/bGxlP1mX9hxGOQS0=; Message-ID: Date: Thu, 29 Jun 2023 21:01:49 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.12.0 Subject: Re: [PATCH 8/9] xen/arm: Allow the user to build Xen with USBAN Content-Language: en-US To: Henry Wang , "xen-devel@lists.xenproject.org" Cc: Luca Fancellu , "michal.orzel@amd.com" , Julien Grall , Stefano Stabellini , Bertrand Marquis , Volodymyr Babchuk References: <20230625204907.57291-1-julien@xen.org> <20230625204907.57291-9-julien@xen.org> <3caaf967-b7ba-0915-56aa-aeff5450a456@xen.org> From: Julien Grall In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 29/06/2023 02:36, Henry Wang wrote: > Hi Julien, Hi Henry, >> -----Original Message----- >> Subject: Re: [PATCH 8/9] xen/arm: Allow the user to build Xen with USBAN >> >> On 26/06/2023 08:29, Henry Wang wrote: >>> Hi Julien, >> Hi Henry, >> >>> Reviewed-by: Henry Wang >> >> Thanks, I will fix both typos. > > Great, thanks! > >> >>> >>> Just want to make sure you also noticed this, otherwise maybe you >>> can include another patch in the series to fix this? >> >> I haven't seen this one. Probably because you would need a setup where >> interrupts are around ID 1022. > > I took a closer look today, I think the reason is from this device tree node > for the FVP: > > ethernet@202000000 { > compatible = "smsc,lan91c111"; > reg = <0x2 0x2000000 0x10000>; > interrupts = <0xf>; > }; > > The value 0xf is passed to vgic_get_virq_type() as "index" then "intr" in > VGIC_ICFG_MASK. Hence the 31 in > "(XEN) left shift of 1 by 31 places cannot be represented in type 'int'". > >> >> Or I can do that >>> in case you don't have enough bandwidth. >> >> You have the setup to exercise the problem. So it would be best if you >> do it. > > I've prepared below on top of your series: > -#define VGIC_ICFG_MASK(intr) (1 << ((2 * ((intr) % 16)) + 1)) > +#define VGIC_ICFG_MASK(intr) (1U << ((2 * ((intr) % 16)) + 1)) This LGTM. Feel free to send a patch. Cheers, -- Julien Grall