Re: [XEN PATCH 03/10] x86: address some violations of MISRA C Rule 20.7

2024-03-05 Thread Nicola Vetrini
On 2024-02-29 18:05, Jan Beulich wrote: On 29.02.2024 17:45, Nicola Vetrini wrote: On 2024-02-29 17:37, Jan Beulich wrote: On 29.02.2024 16:27, Nicola Vetrini wrote: --- a/xen/arch/x86/include/asm/irq.h +++ b/xen/arch/x86/include/asm/irq.h @@ -179,9 +179,9 @@ void cleanup_domain_irq_mapping(st

Re: [XEN PATCH 03/10] x86: address some violations of MISRA C Rule 20.7

2024-02-29 Thread Jan Beulich
On 29.02.2024 17:45, Nicola Vetrini wrote: > On 2024-02-29 17:37, Jan Beulich wrote: >> On 29.02.2024 16:27, Nicola Vetrini wrote: >>> --- a/xen/arch/x86/include/asm/irq.h >>> +++ b/xen/arch/x86/include/asm/irq.h >>> @@ -179,9 +179,9 @@ void cleanup_domain_irq_mapping(struct domain *d); >>> vo

Re: [XEN PATCH 03/10] x86: address some violations of MISRA C Rule 20.7

2024-02-29 Thread Nicola Vetrini
On 2024-02-29 17:37, Jan Beulich wrote: On 29.02.2024 16:27, Nicola Vetrini wrote: --- a/xen/arch/x86/include/asm/irq.h +++ b/xen/arch/x86/include/asm/irq.h @@ -179,9 +179,9 @@ void cleanup_domain_irq_mapping(struct domain *d); void *__ret = radix_tree_lookup(&(d)->arch.hvm.emuirq_pirq, em

Re: [XEN PATCH 03/10] x86: address some violations of MISRA C Rule 20.7

2024-02-29 Thread Jan Beulich
On 29.02.2024 16:27, Nicola Vetrini wrote: > --- a/xen/arch/x86/include/asm/irq.h > +++ b/xen/arch/x86/include/asm/irq.h > @@ -179,9 +179,9 @@ void cleanup_domain_irq_mapping(struct domain *d); > void *__ret = radix_tree_lookup(&(d)->arch.hvm.emuirq_pirq, emuirq);\ > __ret ? radix_tree_pt

[XEN PATCH 03/10] x86: address some violations of MISRA C Rule 20.7

2024-02-29 Thread Nicola Vetrini
MISRA C Rule 20.7 states: "Expressions resulting from the expansion of macro parameters shall be enclosed in parentheses". Therefore, some macro definitions should gain additional parentheses to ensure that all current and future users will be safe with respect to expansions that can possibly alter