From: Alessandro Zucchelli <alessandro.zucchelli@bugseng.com>
To: xen-devel@lists.xenproject.org
Cc: consulting@bugseng.com,
"Alessandro Zucchelli" <alessandro.zucchelli@bugseng.com>,
"Andrew Cooper" <andrew.cooper3@citrix.com>,
"Jan Beulich" <jbeulich@suse.com>,
"Julien Grall" <julien@xen.org>,
"Stefano Stabellini" <sstabellini@kernel.org>,
"Roger Pau Monné" <roger.pau@citrix.com>,
"Simone Ballarin" <simone.ballarin@bugseng.com>,
"Doug Goldstein" <cardoe@cardoe.com>,
"Bertrand Marquis" <bertrand.marquis@arm.com>,
"Michal Orzel" <michal.orzel@amd.com>,
"Volodymyr Babchuk" <Volodymyr_Babchuk@epam.com>,
"Daniel P. Smith" <dpsmith@apertussolutions.com>,
"Marek Marczykowski-Górecki" <marmarek@invisiblethingslab.com>,
"Tamas K Lengyel" <tamas@tklengyel.com>,
"Alexandru Isaila" <aisaila@bitdefender.com>,
"Petre Pircalabu" <ppircalabu@bitdefender.com>
Subject: [XEN PATCH v5 00/17] xen: address violation of MISRA C:2012 Directive 4.10
Date: Tue, 23 Jul 2024 10:14:52 +0200 [thread overview]
Message-ID: <cover.1721720583.git.alessandro.zucchelli@bugseng.com> (raw)
The Xen sources contain violations of MISRA C:2012 Directive 4.10 whose headline states:
"Precautions shall be taken in order to prevent the contents of a header file
being included more than once".
Following V2, V3 and V4, here are all the rules that have been applied:
- private headers -> <dir>__<filename>_H
- asm-generic headers -> ASM_GENERIC__<filename>_H
- arch/<architecture>/include/asm/<subdir>/<filename>.h -> ASM__<architecture>__<subdir>__<filename>_H
- include/xen -> XEN__<filename>_H
Links to the discussions:
https://lists.xenproject.org/archives/html/xen-devel/2023-09/msg01928.html
https://lists.xenproject.org/archives/html/xen-devel/2023-10/msg01784.html
https://lists.xenproject.org/archives/html/xen-devel/2023-10/msg02073.html
Furthermore, the violations arising from the autogenerated header files
include/xen/compile.h and xen/hypercall-defs.h are addressed.
Changes in v5:
edit inclusion guard naming conventions, according to feedback received
edit inclusion guards in header files reflecting the naming convention
fix some rebasing mistakes left in the previous version
Changes in v4:
add/amend inclusion guards to address violations of the Directive and the new naming convention.
drop teh XEN_ prefix when needed, according to the feedback received.
add inclusion guard naming convention section in CODING_STYLE
Changes in v3:
Add/amend inclusion guards to address violations of the Directive and the new naming convention.
Remove trailing underscores.
Modify creation rule for asm-offsets.h to conform to the new standard and to not generate conflicting
guards between architectures (which is a violation of the Directive).
Alessandro Zucchelli (3):
xen/build: address violation of MISRA C Directive 4.10
CODING_STYLE: Add a section on header guards naming conventions
include/asm-generic: rename inclusion guards for consistency
Maria Celeste Cesario (3):
xen/arm: address violations of MISRA C:2012 Directive 4.10
xen: address violations of MISRA C:2012 Directive 4.10
xen/x86: rename inclusion guards for consistency
Nicola Vetrini (1):
xen: add deviations for MISRA C 2012 Dir D4.10
Simone Ballarin (10):
misra: add deviation for headers that explicitly avoid guards
misra: modify deviations for empty and generated headers
misra: add deviations for direct inclusion guards
xen/arm: address violations of MISRA C:2012 Directive 4.10
xen/x86: address violations of MISRA C:2012 Directive 4.10
x86/EFI: address violations of MISRA C:2012 Directive 4.10
xen/common: address violations of MISRA C:2012 Directive 4.10
xen/efi: address violations of MISRA C:2012 Directive 4.10
xen: address violations of MISRA C:2012 Directive 4.10
x86/asm: address violations of MISRA C:2012 Directive 4.10
CODING_STYLE | 21 ++++++++++++
.../eclair_analysis/ECLAIR/deviations.ecl | 12 +++----
docs/misra/deviations.rst | 6 ++++
docs/misra/safe.json | 32 +++++++++++++++++++
xen/arch/arm/efi/efi-boot.h | 6 ++++
xen/arch/arm/efi/runtime.h | 1 +
xen/arch/arm/include/asm/domain.h | 6 ++--
xen/arch/arm/include/asm/efibind.h | 5 +++
xen/arch/arm/include/asm/event.h | 6 ++--
xen/arch/arm/include/asm/grant_table.h | 6 ++--
xen/arch/arm/include/asm/hypercall.h | 1 +
xen/arch/arm/include/asm/io.h | 6 ++--
xen/arch/arm/include/asm/irq.h | 6 ++--
xen/arch/arm/include/asm/smp.h | 6 ++--
xen/arch/arm/include/asm/spinlock.h | 6 ++--
xen/arch/arm/include/asm/system.h | 6 ++--
xen/arch/x86/Makefile | 9 +++---
xen/arch/x86/cpu/cpu.h | 5 +++
xen/arch/x86/efi/efi-boot.h | 5 +++
xen/arch/x86/efi/runtime.h | 5 +++
xen/arch/x86/include/asm/compat.h | 5 +++
xen/arch/x86/include/asm/cpufeatures.h | 5 +--
xen/arch/x86/include/asm/domain.h | 6 ++--
xen/arch/x86/include/asm/efibind.h | 5 +++
xen/arch/x86/include/asm/event.h | 6 ++--
xen/arch/x86/include/asm/grant_table.h | 6 ++--
xen/arch/x86/include/asm/hypercall.h | 1 +
xen/arch/x86/include/asm/io.h | 6 ++--
xen/arch/x86/include/asm/irq.h | 6 ++--
xen/arch/x86/include/asm/smp.h | 6 ++--
xen/arch/x86/include/asm/spinlock.h | 6 ++--
xen/arch/x86/include/asm/system.h | 6 ++--
xen/arch/x86/x86_64/mmconfig.h | 5 +++
xen/arch/x86/x86_emulate/private.h | 5 +++
xen/build.mk | 13 +++++---
xen/common/decompress.h | 5 +++
xen/common/efi/efi.h | 5 +++
xen/common/event_channel.h | 5 +++
xen/include/Makefile | 16 +++++++---
xen/include/asm-generic/altp2m.h | 6 ++--
xen/include/asm-generic/atomic-ops.h | 6 ++--
xen/include/asm-generic/device.h | 6 ++--
xen/include/asm-generic/div64.h | 6 ++--
xen/include/asm-generic/hardirq.h | 6 ++--
xen/include/asm-generic/iocap.h | 6 ++--
xen/include/asm-generic/monitor.h | 6 ++--
xen/include/asm-generic/paging.h | 6 ++--
xen/include/asm-generic/percpu.h | 6 ++--
xen/include/asm-generic/random.h | 6 ++--
xen/include/asm-generic/softirq.h | 6 ++--
xen/include/asm-generic/vm_event.h | 6 ++--
xen/include/public/arch-x86/cpufeatureset.h | 1 +
xen/include/public/errno.h | 1 +
xen/include/xen/err.h | 8 +++--
xen/include/xen/pci_ids.h | 5 +++
xen/include/xen/softirq.h | 8 +++--
xen/include/xen/vmap.h | 8 +++--
xen/scripts/Makefile.asm-generic | 8 ++++-
58 files changed, 268 insertions(+), 117 deletions(-)
--
2.34.1
next reply other threads:[~2024-07-23 8:15 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-23 8:14 Alessandro Zucchelli [this message]
2024-07-23 8:14 ` [XEN PATCH v5 01/17] misra: add deviation for headers that explicitly avoid guards Alessandro Zucchelli
2024-07-23 22:10 ` Stefano Stabellini
2024-07-23 8:14 ` [XEN PATCH v5 02/17] misra: modify deviations for empty and generated headers Alessandro Zucchelli
2024-07-23 8:14 ` [XEN PATCH v5 03/17] misra: add deviations for direct inclusion guards Alessandro Zucchelli
2024-07-23 8:14 ` [XEN PATCH v5 04/17] xen/arm: address violations of MISRA C:2012 Directive 4.10 Alessandro Zucchelli
2024-07-23 8:14 ` [XEN PATCH v5 05/17] xen/x86: " Alessandro Zucchelli
2024-07-24 15:53 ` Jan Beulich
2024-07-23 8:14 ` [XEN PATCH v5 06/17] x86/EFI: " Alessandro Zucchelli
2024-07-23 8:14 ` [XEN PATCH v5 07/17] xen/common: " Alessandro Zucchelli
2024-07-23 8:15 ` [XEN PATCH v5 08/17] xen/efi: " Alessandro Zucchelli
2024-07-23 8:15 ` [XEN PATCH v5 09/17] xen: " Alessandro Zucchelli
2024-07-24 15:55 ` Jan Beulich
2024-07-23 8:15 ` [XEN PATCH v5 10/17] x86/asm: " Alessandro Zucchelli
2024-07-23 22:19 ` Stefano Stabellini
2024-07-24 15:57 ` Jan Beulich
2024-07-23 8:15 ` [XEN PATCH v5 11/17] xen/arm: " Alessandro Zucchelli
2024-07-23 8:15 ` [XEN PATCH v5 12/17] xen: " Alessandro Zucchelli
2024-07-23 22:26 ` Stefano Stabellini
2024-07-23 22:29 ` Stefano Stabellini
2024-07-24 13:26 ` Alessandro Zucchelli
2024-07-23 8:15 ` [XEN PATCH v5 13/17] xen: add deviations for MISRA C 2012 Dir D4.10 Alessandro Zucchelli
2024-07-30 9:45 ` Jan Beulich
2024-07-30 9:54 ` Nicola Vetrini
2024-07-23 8:15 ` [XEN PATCH v5 14/17] xen/x86: rename inclusion guards for consistency Alessandro Zucchelli
2024-07-24 15:59 ` Jan Beulich
2024-07-23 8:15 ` [XEN PATCH v5 15/17] xen/build: address violation of MISRA C Directive 4.10 Alessandro Zucchelli
2024-07-23 22:31 ` Stefano Stabellini
2024-07-23 8:15 ` [XEN PATCH v5 16/17] CODING_STYLE: Add a section on header guards naming conventions Alessandro Zucchelli
2024-07-23 8:43 ` Jan Beulich
2024-07-23 22:40 ` Stefano Stabellini
2024-07-24 5:46 ` Jan Beulich
2024-07-24 22:14 ` Stefano Stabellini
2024-07-23 8:15 ` [XEN PATCH v5 17/17] include/asm-generic: rename inclusion guards for consistency Alessandro Zucchelli
2024-07-23 22:44 ` Stefano Stabellini
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=cover.1721720583.git.alessandro.zucchelli@bugseng.com \
--to=alessandro.zucchelli@bugseng.com \
--cc=Volodymyr_Babchuk@epam.com \
--cc=aisaila@bitdefender.com \
--cc=andrew.cooper3@citrix.com \
--cc=bertrand.marquis@arm.com \
--cc=cardoe@cardoe.com \
--cc=consulting@bugseng.com \
--cc=dpsmith@apertussolutions.com \
--cc=jbeulich@suse.com \
--cc=julien@xen.org \
--cc=marmarek@invisiblethingslab.com \
--cc=michal.orzel@amd.com \
--cc=ppircalabu@bitdefender.com \
--cc=roger.pau@citrix.com \
--cc=simone.ballarin@bugseng.com \
--cc=sstabellini@kernel.org \
--cc=tamas@tklengyel.com \
--cc=xen-devel@lists.xenproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.