address some violations of MISRA C Rule 20.7
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest11 patches 26 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/11 | xen/list: address violations of MISRA C Rule 20.7xen/ | +71 | 1 reply | |
| 2/11 | xen/xsm: add parentheses to comply with MISRA C Rule 20.7xen/ | +2 | 1 reply | |
| 3/11 | xen/efi: efibind: address violations of MISRA C Rule 20.7xen/ xen/ | +4 | 0 replies | |
| 4/11 | xentrace: address violation of MISRA C Rule 20.7xen/ | +1 | 1 reply | |
| 5/11 | xen: address MISRA C Rule 20.7 violation in generated hypercallxen/ | +2 | 1 reply | |
| 6/11 | xen/efi: address violations of MISRA C Rule 20.7xen/ | +2 | 2 replies | |
| 7/11 | xen/page_alloc: address violations of MISRA C Rule 20.7xen/ | +1 | 4 replies | |
| 8/11 | x86/altcall: address violations of MISRA C Rule 20.7xen/ | +38 | 4 replies | |
| 9/11 | x86/msi: address violation of MISRA C Rule 20.7 and coding stylexen/ | +24 | 5 replies | |
| 10/11 | x86/hvm: address violations of Rule 20.7xen/ xen/ | +5 | 2 replies | |
| 11/11 | x86/public: hvm: address violations of MISRA C Rule 20.7xen/ | +1 | 3 replies |
Reviews trailers per patch
8 of 11 patches have a Reviewed-by or Acked-by.
| Patch | Stefano Stabellini | Jan Beulich | Daniel P. Smith |
|---|---|---|---|
| 1/11 | R-b | ||
| 2/11 | R-b | A-b | |
| 3/11 | A-b | ||
| 4/11 | A-b | ||
| 5/11 | R-b | ||
| 6/11 | |||
| 7/11 | A-b | ||
| 8/11 | |||
| 9/11 | |||
| 10/11 | A-b | ||
| 11/11 | A-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.
Cover letter [XEN PATCH 00/11] address some violations of MISRA C Rule 20.7
Hi all,
this series aims to refactor some macros that cause violations of MISRA C Rule 20.7 ("Expressions resulting from the expansion of macro parameters shall be enclosed in parentheses"). All the macros touched by these patches are in some way involved in violations, and the strategy adopted to bring them into compliance is to add parentheses around macro arguments where needed.
Given that the community has previously requested a deviation from the rule, as stated in docs/misra/deviations.rst, and reported below for convenience [1], some macro parameters do not need any adjusting (e.g., when used as lhs to an assignment in statement expressions).
Patch 1 is taken, with adjustments, from [2]. Patches 2 and 3 are taken from [3] without any modifications. All other patches are new in this series and are pairwise indipendent.
[1] - Code violating Rule 20.7 is safe when macro parameters are used:
(1) as function arguments;
(2) as macro arguments;
(3) as array indices;
(4) as lhs in assignments.[2] https://lore.kernel.org/xen-devel/b93a64b93ef4210f5fe96368c2522e5e71e9c87c.1709896401.git.nicola.vetrini@bugseng.com/
[3] https://lore.kernel.org/xen-devel/[email protected]/
Nicola Vetrini (11):
xen/list: address violations of MISRA C Rule 20.7 xen/xsm: add parentheses to comply with MISRA C Rule 20.7 xen/efi: efibind: address violations of MISRA C Rule 20.7
xentrace: address violation of MISRA C Rule 20.7
xen: address MISRA C Rule 20.7 violation in generated hypercall xen/efi: address violations of MISRA C Rule 20.7 xen/page_alloc: address violations of MISRA C Rule 20.7 x86/altcall: address violations of MISRA C Rule 20.7 x86/msi: address violation of MISRA C Rule 20.7 and coding style x86/hvm: address violations of Rule 20.7
x86/public: hvm: address violations of MISRA C Rule 20.7
xen/arch/arm/include/asm/arm64/efibind.h | 4 +- xen/arch/x86/hvm/hvm.c | 6 +- xen/arch/x86/include/asm/alternative.h | 76 ++++++------ xen/arch/x86/include/asm/hvm/save.h | 4 +- xen/arch/x86/include/asm/msi.h | 47 +++---- xen/arch/x86/include/asm/x86_64/efibind.h | 4 +- xen/common/page_alloc.c | 2 +- xen/include/efi/efiapi.h | 3 +- xen/include/public/arch-x86/xen.h | 2 +- xen/include/public/trace.h | 2 +- xen/include/xen/list.h | 143 +++++++++++----------- xen/include/xsm/dummy.h | 4 +- xen/scripts/gen_hypercall.awk | 4 +- 13 files changed, 151 insertions(+), 150 deletions(-)
Signature · 1 line
2.34.1