Difference between revisions of "FuSa SIG/Contributing"

From Xen
 
(2 intermediate revisions by the same user not shown)
Line 10: Line 10:
 
There is an effort in progress to align Xen with MISRA C coding guidelines. A few MISRA C rules are already officially part of the Xen coding style, they are available here: [https://gitlab.com/xen-project/xen/-/blob/staging/docs/misra/rules.rst rules.rst]
 
There is an effort in progress to align Xen with MISRA C coding guidelines. A few MISRA C rules are already officially part of the Xen coding style, they are available here: [https://gitlab.com/xen-project/xen/-/blob/staging/docs/misra/rules.rst rules.rst]
   
You can scan the Xen code for violations of this set of MISRA C rules using *cppcheck*.
+
You can scan the Xen code for violations of this set of MISRA C rules using *cppcheck* (needs to be version 2.7 or greater):
  +
  +
cd xen.git/xen/
  +
export CPPCHECK=/path/to/cppcheck/cppcheck
  +
export CPPCHECK_HTMLREPORT=/path/to/cppcheck/htmlreport/cppcheck-htmlreport
  +
export CPPCHECK_MISRA=y
  +
make cppcheck-html
  +
  +
The output will be under *cppcheck-htmlreport/index.html* by default.
   
 
Your help to reduce MISRA C violations in Xen is very welcome!
 
Your help to reduce MISRA C violations in Xen is very welcome!
Line 29: Line 37:
 
Xen Project is using Gitlab-CI to test individual hypervisor features. See the existing tests under [https://gitlab.com/xen-project/xen/-/tree/staging/automation automation]:
 
Xen Project is using Gitlab-CI to test individual hypervisor features. See the existing tests under [https://gitlab.com/xen-project/xen/-/tree/staging/automation automation]:
 
* https://gitlab.com/xen-project/xen/-/blob/staging/.gitlab-ci.yml
 
* https://gitlab.com/xen-project/xen/-/blob/staging/.gitlab-ci.yml
  +
* https://gitlab.com/xen-project/xen/-/blob/staging/automation/gitlab-ci/test.yaml
 
* https://gitlab.com/xen-project/xen/-/blob/staging/automation/scripts/qemu-smoke-arm64.sh
 
* https://gitlab.com/xen-project/xen/-/blob/staging/automation/scripts/qemu-smoke-arm64.sh
   
Please add new tests for any features that you see missing. For instance [https://patchwork.kernel.org/project/xen-devel/cover/20220421081645.40235-1-luca.fancellu@arm.com/ Boot Time Cpupools].
+
Please add new tests for any features that you see missing, especially static configuration features (e.g. dom0less and related configurations). For instance:
  +
* Boot Time Cpupools: https://gitlab.com/xen-project/xen/-/blob/staging/docs/misc/arm/device-tree/cpupools.txt

Latest revision as of 22:54, 11 August 2022

Join the FuSa SIG meetings to participate in safety improvements for Xen.

In this page we can find a list of small items for newcomers and seasoned contributors alike to improve Xen safety compliance. The development items below are for the hypervisor (xen subdirectory).

Please send fixes to the xen-devel list following the Xen contribution process. For instance, see this example.


MISRA C

There is an effort in progress to align Xen with MISRA C coding guidelines. A few MISRA C rules are already officially part of the Xen coding style, they are available here: rules.rst

You can scan the Xen code for violations of this set of MISRA C rules using *cppcheck* (needs to be version 2.7 or greater):

 cd xen.git/xen/
 export CPPCHECK=/path/to/cppcheck/cppcheck
 export CPPCHECK_HTMLREPORT=/path/to/cppcheck/htmlreport/cppcheck-htmlreport
 export CPPCHECK_MISRA=y
 make cppcheck-html

The output will be under *cppcheck-htmlreport/index.html* by default.

Your help to reduce MISRA C violations in Xen is very welcome!


SPDX

SPDX is an open standard for communicating software bill of material information, such as the license of a source file. It consists of a single line comment at the top of the file with licensing information, for example:

 // SPDX-License-Identifier: GPL-2.0


Xen wants to be SPDX compliant. Please help! Xen is GPLv2, licensing information available | here.


Testing

Xen Project is using Gitlab-CI to test individual hypervisor features. See the existing tests under automation:

Please add new tests for any features that you see missing, especially static configuration features (e.g. dom0less and related configurations). For instance: