Re: [Xen-devel] [PATCH v6 10/36] ARM: GIC: Add checks for NULL pointer pending_irq's

2017-04-07 Thread André Przywara
On 07/04/17 23:09, Stefano Stabellini wrote: > On Fri, 7 Apr 2017, Stefano Stabellini wrote: >> On Fri, 7 Apr 2017, Julien Grall wrote: >>> Hi Andre, >>> >>> On 04/07/2017 09:46 PM, André Przywara wrote: On 07/04/17 20:07, Stefano Stabellini wrote: > On Fri, 7 Apr 2017, Andre Przywara wrot

Re: [Xen-devel] [PATCH v6 10/36] ARM: GIC: Add checks for NULL pointer pending_irq's

2017-04-07 Thread Stefano Stabellini
On Fri, 7 Apr 2017, Stefano Stabellini wrote: > On Fri, 7 Apr 2017, Julien Grall wrote: > > Hi Andre, > > > > On 04/07/2017 09:46 PM, André Przywara wrote: > > > On 07/04/17 20:07, Stefano Stabellini wrote: > > > > On Fri, 7 Apr 2017, Andre Przywara wrote: > > > > > For LPIs the struct pending_irq

Re: [Xen-devel] [PATCH v6 10/36] ARM: GIC: Add checks for NULL pointer pending_irq's

2017-04-07 Thread Stefano Stabellini
On Fri, 7 Apr 2017, Julien Grall wrote: > Hi Andre, > > On 04/07/2017 09:46 PM, André Przywara wrote: > > On 07/04/17 20:07, Stefano Stabellini wrote: > > > On Fri, 7 Apr 2017, Andre Przywara wrote: > > > > For LPIs the struct pending_irq's are somewhat dynamically allocated and > > > > the pointe

Re: [Xen-devel] [PATCH v6 10/36] ARM: GIC: Add checks for NULL pointer pending_irq's

2017-04-07 Thread Julien Grall
Hi Andre, On 04/07/2017 09:46 PM, André Przywara wrote: On 07/04/17 20:07, Stefano Stabellini wrote: On Fri, 7 Apr 2017, Andre Przywara wrote: For LPIs the struct pending_irq's are somewhat dynamically allocated and the pointers are stored in a radix tree. While I convinced myself that an inva

Re: [Xen-devel] [PATCH v6 10/36] ARM: GIC: Add checks for NULL pointer pending_irq's

2017-04-07 Thread André Przywara
On 07/04/17 20:07, Stefano Stabellini wrote: > On Fri, 7 Apr 2017, Andre Przywara wrote: >> For LPIs the struct pending_irq's are somewhat dynamically allocated and >> the pointers are stored in a radix tree. While I convinced myself that >> an invalid LPI number can't make it into the core code, p

Re: [Xen-devel] [PATCH v6 10/36] ARM: GIC: Add checks for NULL pointer pending_irq's

2017-04-07 Thread Stefano Stabellini
On Fri, 7 Apr 2017, Andre Przywara wrote: > For LPIs the struct pending_irq's are somewhat dynamically allocated and > the pointers are stored in a radix tree. While I convinced myself that > an invalid LPI number can't make it into the core code, people might be > concerned about NULL pointer dere

Re: [Xen-devel] [PATCH v6 10/36] ARM: GIC: Add checks for NULL pointer pending_irq's

2017-04-07 Thread Julien Grall
Hi Andre, On 07/04/17 18:32, Andre Przywara wrote: For LPIs the struct pending_irq's are somewhat dynamically allocated and When I read "dynamically", I directly ask myself. What is protecting the pending_irq structure to be freed whilst in-use in the vgic code? In the current design, this

[Xen-devel] [PATCH v6 10/36] ARM: GIC: Add checks for NULL pointer pending_irq's

2017-04-07 Thread Andre Przywara
For LPIs the struct pending_irq's are somewhat dynamically allocated and the pointers are stored in a radix tree. While I convinced myself that an invalid LPI number can't make it into the core code, people might be concerned about NULL pointer dereferences. So add checks in some places just to be