Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 1 | Contributing to Trusted Firmware-A Tests |
| 2 | ======================================== |
| 3 | |
| 4 | Getting Started |
| 5 | --------------- |
| 6 | |
| 7 | - Make sure you have a Github account and you are logged on |
| 8 | `developer.trustedfirmware.org`_. |
| 9 | |
| 10 | For any non-trivial piece of work, we advise you to create a `task`_ if one |
| 11 | does not already exist. This gives everyone visibility of whether others are |
| 12 | working on something similar. |
| 13 | |
| 14 | Please select the `Trusted Firmware-A Tests` tag in the task creation form. |
| 15 | |
| 16 | - Clone the repository from the Gerrit server. The project details may be found |
| 17 | on the `tf-a-tests project page`_. We recommend the "`Clone with commit-msg |
| 18 | hook`" clone method, which will setup the git commit hook that automatically |
| 19 | generates and inserts appropriate `Change-Id:` lines in your commit messages. |
| 20 | |
| 21 | - Base you work on the latest ``master`` branch. |
| 22 | |
| 23 | Making Changes |
| 24 | -------------- |
| 25 | |
| 26 | - Make commits of logical units. See these general `Git guidelines`_ for |
| 27 | contributing to a project. |
| 28 | |
| 29 | - Follow the `Linux coding style`_; this style is enforced for the TF-A Tests |
| 30 | project (style errors only, not warnings). |
| 31 | |
| 32 | Use the ``checkpatch.pl`` script provided with the Linux source tree. A |
| 33 | Makefile target is provided for convenience (see section `Checking source |
| 34 | code style`_ in the User Guide). |
| 35 | |
| 36 | - Keep the commits on topic. If you need to fix another bug or make another |
| 37 | enhancement, please address it on a separate patch series. |
| 38 | |
| 39 | - Avoid long commit series. If you do have a long series, consider whether |
| 40 | some commits should be squashed together or addressed in a separate series. |
| 41 | |
| 42 | - Where appropriate, please update the documentation. |
| 43 | |
| 44 | - Ensure that each changed file has the correct copyright and license |
| 45 | information. |
| 46 | |
| 47 | - Please test your changes. As a minimum, ensure that all standard tests pass |
| 48 | on the Foundation FVP. See `Running the TF-A Tests`_ for more information. |
| 49 | |
| 50 | Submitting Changes |
| 51 | ------------------ |
| 52 | |
| 53 | - Ensure that each commit in the series has at least one ``Signed-off-by:`` |
| 54 | line, using your real name and email address. If anyone else contributes to |
| 55 | the commit, they must also add their own ``Signed-off-by:`` line. |
| 56 | |
| 57 | By adding this line the contributor certifies the contribution is made under |
| 58 | the terms of the `Developer Certificate of Origin (DCO)`_. |
| 59 | |
| 60 | More details may be found in the `Gerrit Signed-off-by Lines guidelines`_. |
| 61 | |
| 62 | - Ensure that each commit also has a unique ``Change-Id:`` line. If you have |
| 63 | cloned the repository with the "`Clone with commit-msg hook`" clone method |
| 64 | (as advised in section `Getting started`_), this should already be the case. |
| 65 | |
| 66 | More details may be found in the `Gerrit Change-Ids documentation`_. |
| 67 | |
| 68 | - Submit your patches to the Gerrit review server. Please choose a Gerrit topic |
| 69 | for your patch series - that is, a short tag associated with all of the |
| 70 | changes in the same group, such as the local topic branch name. |
| 71 | |
| 72 | Refer to the `Gerrit documentation`_ for more details. |
| 73 | |
| 74 | - Once the patch has had sufficient peer review and has passed the checks run |
| 75 | by the continuous integration system, the `maintainers`_ will merge your |
| 76 | patch. |
| 77 | |
| 78 | -------------- |
| 79 | |
| 80 | *Copyright (c) 2018, Arm Limited. All rights reserved.* |
| 81 | |
| 82 | .. _maintainers: maintainers.rst |
| 83 | .. _license.rst: license.rst |
| 84 | .. _Developer Certificate of Origin (DCO): dco.txt |
John Tsichritzis | 4586e0d | 2018-10-18 10:00:28 +0100 | [diff] [blame] | 85 | .. _Checking source code style: docs/user-guide.rst#checking-source-code-style |
| 86 | .. _Running the TF-A Tests: docs/user-guide.rst#running-the-tf-a-tests |
Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 87 | |
| 88 | .. _Git guidelines: http://git-scm.com/book/ch5-2.html |
| 89 | .. _Linux coding style: https://www.kernel.org/doc/html/latest/process/coding-style.html |
| 90 | |
| 91 | .. _developer.trustedfirmware.org: https://developer.trustedfirmware.org |
| 92 | .. _task: https://developer.trustedfirmware.org/maniphest/query/open/ |
Sandrine Bailleux | 2d0136e | 2018-11-05 14:21:27 +0100 | [diff] [blame] | 93 | .. _tf-a-tests project page: https://review.trustedfirmware.org/#/admin/projects/TF-A/tf-a-tests |
Sandrine Bailleux | 3cd87d7 | 2018-10-09 11:12:55 +0200 | [diff] [blame] | 94 | .. _Gerrit documentation: https://review.trustedfirmware.org/Documentation/user-upload.html |
| 95 | .. _Gerrit Signed-off-by Lines guidelines: https://review.trustedfirmware.org/Documentation/user-signedoffby.html |
| 96 | .. _Gerrit Change-Ids documentation: https://review.trustedfirmware.org/Documentation/user-changeid.html |