Re: [PATCH 02/15] xen/arm/gic: Enable interrupt assignment to running VM

2024-05-11 Thread Henry Wang
Hi Julien, On 5/11/2024 4:22 PM, Julien Grall wrote: Hi Henry, On 11/05/2024 08:29, Henry Wang wrote: +    /* + * Handle the LR where the physical interrupt is de-assigned from the + * guest before it was EOIed + */ +    struct vcpu *v_target = vgic_get_target

Re: [PATCH 02/15] xen/arm/gic: Enable interrupt assignment to running VM

2024-05-11 Thread Julien Grall
Hi Henry, On 11/05/2024 08:29, Henry Wang wrote: +    /* + * Handle the LR where the physical interrupt is de-assigned from the + * guest before it was EOIed + */ +    struct vcpu *v_target = vgic_get_target_vcpu(d->vcpu[0], virq); This will return a vCPU from

Re: [PATCH 02/15] xen/arm/gic: Enable interrupt assignment to running VM

2024-05-11 Thread Henry Wang
Hi Julien, On 5/10/2024 4:54 PM, Julien Grall wrote: Hi, On 09/05/2024 16:31, Henry Wang wrote: On 5/9/2024 4:46 AM, Julien Grall wrote: Hi Henry, [...] ``` diff --git a/xen/arch/arm/gic.c b/xen/arch/arm/gic.c index a775f886ed..d3f9cd2299 100644 --- a/xen/arch/arm/gic.c +++ b/xen/arch/arm/gic

Re: [PATCH 02/15] xen/arm/gic: Enable interrupt assignment to running VM

2024-05-10 Thread Julien Grall
Hi, On 09/05/2024 16:31, Henry Wang wrote: On 5/9/2024 4:46 AM, Julien Grall wrote: Hi Henry, [...] we have 3 possible states which can be read from LR for this case : active, pending, pending and active. - I don't think we can do anything about the active state, so we should return -EBUSY a

Re: [PATCH 02/15] xen/arm/gic: Enable interrupt assignment to running VM

2024-05-09 Thread Henry Wang
Hi Julien, On 5/9/2024 4:46 AM, Julien Grall wrote: Hi Henry, [...] we have 3 possible states which can be read from LR for this case : active, pending, pending and active. - I don't think we can do anything about the active state, so we should return -EBUSY and reject the whole operation of

Re: [PATCH 02/15] xen/arm/gic: Enable interrupt assignment to running VM

2024-05-08 Thread Julien Grall
Hi Henry, On 08/05/2024 08:49, Henry Wang wrote: On 5/8/2024 5:54 AM, Julien Grall wrote: Hi Henry, What if the DT overlay is unloaded and then reloaded? Wouldn't the same interrupt be re-used? As a more generic case, this could also be a new bitstream for the FPGA. But even if the interrup

Re: [PATCH 02/15] xen/arm/gic: Enable interrupt assignment to running VM

2024-05-08 Thread Henry Wang
Hi Julien, On 5/8/2024 5:54 AM, Julien Grall wrote: Hi Henry, What if the DT overlay is unloaded and then reloaded? Wouldn't the same interrupt be re-used? As a more generic case, this could also be a new bitstream for the FPGA. But even if the interrupt is brand new every time for the DT o

Re: [PATCH 02/15] xen/arm/gic: Enable interrupt assignment to running VM

2024-05-07 Thread Julien Grall
Hi Henry, On 06/05/2024 09:32, Henry Wang wrote: On 5/1/2024 4:13 AM, Julien Grall wrote: Hi Henry, On 30/04/2024 04:50, Henry Wang wrote: On 4/25/2024 10:28 PM, Julien Grall wrote: Thanks for your feeedback. After checking the b8577547236f commit message I think I now understand your point.

Re: [PATCH 02/15] xen/arm/gic: Enable interrupt assignment to running VM

2024-05-06 Thread Henry Wang
Hi Julien, On 5/1/2024 4:13 AM, Julien Grall wrote: Hi Henry, On 30/04/2024 04:50, Henry Wang wrote: On 4/25/2024 10:28 PM, Julien Grall wrote: Thanks for your feeedback. After checking the b8577547236f commit message I think I now understand your point. Do you have any suggestion about how

Re: [PATCH 02/15] xen/arm/gic: Enable interrupt assignment to running VM

2024-04-30 Thread Julien Grall
Hi Henry, On 30/04/2024 04:50, Henry Wang wrote: On 4/25/2024 10:28 PM, Julien Grall wrote: Thanks for your feeedback. After checking the b8577547236f commit message I think I now understand your point. Do you have any suggestion about how can I properly add the support to route/remove the IR

Re: [PATCH 02/15] xen/arm/gic: Enable interrupt assignment to running VM

2024-04-29 Thread Henry Wang
Hi Julien, Sorry for the late reply, On 4/25/2024 10:28 PM, Julien Grall wrote: Hi, On 25/04/2024 08:06, Henry Wang wrote: Hi Julien, On 4/24/2024 8:58 PM, Julien Grall wrote: Hi Henry, On 24/04/2024 04:34, Henry Wang wrote: From: Vikram Garhwal Enable interrupt assign/remove for runnin

Re: [PATCH 02/15] xen/arm/gic: Enable interrupt assignment to running VM

2024-04-25 Thread Julien Grall
Hi, On 25/04/2024 08:06, Henry Wang wrote: Hi Julien, On 4/24/2024 8:58 PM, Julien Grall wrote: Hi Henry, On 24/04/2024 04:34, Henry Wang wrote: From: Vikram Garhwal Enable interrupt assign/remove for running VMs in CONFIG_OVERLAY_DTB. Currently, irq_route and mapping is only allowed at t

Re: [PATCH 02/15] xen/arm/gic: Enable interrupt assignment to running VM

2024-04-25 Thread Henry Wang
Hi Julien, On 4/24/2024 8:58 PM, Julien Grall wrote: Hi Henry, On 24/04/2024 04:34, Henry Wang wrote: From: Vikram Garhwal Enable interrupt assign/remove for running VMs in CONFIG_OVERLAY_DTB. Currently, irq_route and mapping is only allowed at the domain creation. Adding exception for CO

Re: [PATCH 02/15] xen/arm/gic: Enable interrupt assignment to running VM

2024-04-24 Thread Julien Grall
Hi Henry, On 24/04/2024 04:34, Henry Wang wrote: From: Vikram Garhwal Enable interrupt assign/remove for running VMs in CONFIG_OVERLAY_DTB. Currently, irq_route and mapping is only allowed at the domain creation. Adding exception for CONFIG_OVERLAY_DTB. AFAICT, this is mostly reverting b857

[PATCH 02/15] xen/arm/gic: Enable interrupt assignment to running VM

2024-04-23 Thread Henry Wang
From: Vikram Garhwal Enable interrupt assign/remove for running VMs in CONFIG_OVERLAY_DTB. Currently, irq_route and mapping is only allowed at the domain creation. Adding exception for CONFIG_OVERLAY_DTB. Signed-off-by: Vikram Garhwal Signed-off-by: Stefano Stabellini Signed-off-by: Henry Wan