[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v1 2/4] arm/gic: Use static irqaction
- To: "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- From: Mykyta Poturai <Mykyta_Poturai@xxxxxxxx>
- Date: Thu, 18 Sep 2025 12:16:34 +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=NN+9v4HUcACKQP3UTIJ7uIDFEXsmW14cpvwu+bPQxAM=; b=X36EViaamCgUl7S0uZstEwyp0QwDnTUad8+dRG5STkT714Vq6hD8Q3LwCE+N4Wpq+XX/Aaiz7+0rRpAMGEZ91zrc0xdlW3UUu8b1yltw8G0raDNn6IpzSRtkJS+55PYvjdSOD2lYgjJgyzGY48Xx3M3yHNtiyrKjurXOzApichaEb3ZdGpjnOxQJtTwR4R2zy4JRATkUAXzMYCb3l+/lmwutR0qjaaq0tenu7liSBOcQ6MmVoGFzkBV9hjbkf593RiHvL8z0NgYUX/OEKfZCyeW8uBVHGV15zxAHl+WzTe39N6r8NaVwdB7B62xBS4LM/ZeCMS/Tm8wYho51vK71fg==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=Wt0C7Lz5i7UvO9H6f+Td0B39yB88DHo0AhgBQfbR7RQhNhcigsDy8xr2ST8O/pW1JfkyeeVvPEkt9kyBmG3wX/B+xBUPVmm5ZD2JFGJo6KKAd3DEc7e1WQrWZEg31CSPKdoLBiqYIhZidmswZls60elT4Xcmmi3Hn88vl+MjUQDFkfTR0uamV7jVK++VsVQ9fyZS2Byxjg0/u67aUFFOHPkshO7vtkHYyAYSBEZwP+hPESzFsUhmqJhFxwpKlTUg4HvN6GvY5IzqEHIJV8XM4v73aMx1qpKfdQDLXryyAEfpA4k0xLDF9G6Q5pT7Kfc81wMT1OphyZzEpkad67GaSw==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=epam.com;
- Cc: Mykyta Poturai <Mykyta_Poturai@xxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Bertrand Marquis <bertrand.marquis@xxxxxxx>, Michal Orzel <michal.orzel@xxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>
- Delivery-date: Thu, 18 Sep 2025 12:16:49 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
- Thread-index: AQHcKJYSC7sAxQi7Lk6HVSEybUuLWA==
- Thread-topic: [PATCH v1 2/4] arm/gic: Use static irqaction
When stopping a core cpu_gic_callback is called in non-alloc
context, which causes xfree in release_irq to fail an assert.
To fix this, switch to a statically allocated irqaction that does not
need to be freed in release_irq.
Signed-off-by: Mykyta Poturai <mykyta_poturai@xxxxxxxx>
---
xen/arch/arm/gic.c | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/xen/arch/arm/gic.c b/xen/arch/arm/gic.c
index 260ee64cca..b00747a250 100644
--- a/xen/arch/arm/gic.c
+++ b/xen/arch/arm/gic.c
@@ -386,10 +386,16 @@ void gic_dump_info(struct vcpu *v)
gic_hw_ops->dump_state(v);
}
+static struct irqaction __read_mostly irq_maintenance = {
+ .name = "irq-maintenance",
+ .handler = maintenance_interrupt,
+ .dev_id = NULL,
+ .free_on_release = 0,
+};
+
void init_maintenance_interrupt(void)
{
- request_irq(gic_hw_ops->info->maintenance_irq, 0, maintenance_interrupt,
- "irq-maintenance", NULL);
+ setup_irq(gic_hw_ops->info->maintenance_irq, 0, &irq_maintenance);
}
int gic_make_hwdom_dt_node(const struct domain *d,
--
2.34.1
|