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

Re: [PATCH v7 04/12] xen/arm/irq: add handling for IRQs in the eSPI range


  • To: Julien Grall <julien@xxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Leonid Komarianskyi <Leonid_Komarianskyi@xxxxxxxx>
  • Date: Fri, 5 Sep 2025 10:05:33 +0000
  • Accept-language: en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=epam.com; dmarc=pass action=none header.from=epam.com; dkim=pass header.d=epam.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=DdungOsxOzp7BSzikz/ChkxnYS9pubO+hZKQjxzrfWc=; b=hbsJisVAfCKHTADzzI7Bum1+dGo9tfGtThi4sMxbt5xk1bpWAWgpUzJZlVzNM8rPcbP2Ea1kimj+tf30CLKSHNB5Dt+skN3Zz/dAIGkgYcZ+H0S3VC9XLR21qunyS7phGxoiH9LS4BL/n//PCPbT3k6nVA9WBOhWIlQy2WxhibDarEecPlDjxtLhXwkUtkub3r2Ps3F85GIaET1qdK6q4IuaSR1nUnQZ2zH1idYSR1A7Q6D8w+DANYay0syh5KOMs9pPf9/PK6hbMH48tozE7dBLqAZgqrA/Z8QyY0Hvi1XUNt37E9urzJ5C0lRxLcVPSId3VTUStOixRdsaEl3RYQ==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=zPPymxeUQLhU6h7Au1yUzCnjdfxamn9tHtSrgag7Sgulz/lhVQqXfeYMC1WmvSapqdWOMMvfrkRlJ75xNS/u4jGaCBjUOSf9s7IPCytINofk3d7Q0Pz/8xrgdMcAvTq2q2mdIl4IcWMjpD0cpN5LisUs7+N+qUYub6qkIxRAp57DtKpeSXAgmHWYb+LvbBFgXRkwpOkjVTXFCwJ6VMT+vFeqbNGFCsZbCMWbK0W1BPud+4g9qt6/zA5/DnBsWTYHufsmZS5U4SD7mzf6MBJrhKS8BeicCkViTBu8pU1LmgmR2/ITt1ivNO2NWBaIjF/Z2Kif0KwxPYBjwdmvUWq7jQ==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=epam.com;
  • Cc: "olekstysh@xxxxxxxxx" <olekstysh@xxxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Bertrand Marquis <bertrand.marquis@xxxxxxx>, Michal Orzel <michal.orzel@xxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>
  • Delivery-date: Fri, 05 Sep 2025 10:05:48 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Thread-index: AQHcHdaxzH0gJHOWB0uscg50WGUPx7SELLEAgAAw3YA=
  • Thread-topic: [PATCH v7 04/12] xen/arm/irq: add handling for IRQs in the eSPI range

Hi Julien,

Thank you for your comment.

On 05.09.25 10:10, Julien Grall wrote:
> Hi Leonid,
> 
> On 04/09/2025 21:01, Leonid Komarianskyi wrote:
>> diff --git a/xen/arch/arm/include/asm/irq.h b/xen/arch/arm/include/ 
>> asm/irq.h
>> index 5bc6475eb4..2ff2d07d6d 100644
>> --- a/xen/arch/arm/include/asm/irq.h
>> +++ b/xen/arch/arm/include/asm/irq.h
>> @@ -32,6 +32,10 @@ struct arch_irq_desc {
>>   #define SPI_MAX_INTID   1019
>>   #define LPI_OFFSET      8192
>> +#define ESPI_BASE_INTID 4096
>> +#define ESPI_MAX_INTID  5119
>> +#define NR_ESPI_IRQS    1024
>> +
>>   /* LPIs are always numbered starting at 8192, so 0 is a good invalid 
>> case. */
>>   #define INVALID_LPI     0
>> @@ -39,7 +43,12 @@ struct arch_irq_desc {
>>   #define INVALID_IRQ     1023
>>   extern const unsigned int nr_irqs;
>> +#ifdef CONFIG_GICV3_ESPI
>> +/* This will cover the eSPI range, to allow asignmant of eSPIs to 
>> domains. */
> 
> Typo: s/asignmant/assignment/
> 
> [...]
> 
>> Unless INTIDs from the eSPI
>> + * range are mistakenly defined in Xen DTS when the appropriate 
>> config is
>> + * disabled, this function will not be reached because is_espi will 
>> return
>> + * false for non-eSPI INTIDs.
> 
> I am still confused with this paragraph. How is this function can be 
> reached if it is compiled out? Surely, if the DT is misconfigured, we 
> should get an error when trying to route the interrupt. No? If so, can 
> you point me to that code?
> 
> Cheers,
> 

Oh, sorry, the second part of the comment is redundant with the current 
implementation. It was correct when the function had an implementation 
and returned NULL. The correct comment is:

Defined as a prototype as it should not be called if 
CONFIG_GICV3_ESPI=n. Without CONFIG_GICV3_ESPI, the additional 1024 IRQ 
descriptors will not be defined, and thus, they cannot be used.

Should I prepare V8 with the comment fix, or can this be corrected on 
commit?

Best regards,
Leonid

 


Rackspace

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