From d982eac37eed8594534685ad94a65b86a1bed0bb Mon Sep 17 00:00:00 2001 From: Arnaud Pouliquen Date: Tue, 21 Apr 2020 11:20:26 +0200 Subject: [PATCH 1/6] readme: fix the source structure The OpenAMP source structure is no more up to date. fix it. Signed-off-by: Arnaud Pouliquen --- README.md | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index a2c158365..b05c1b23d 100644 --- a/README.md +++ b/README.md @@ -20,26 +20,22 @@ enable development of software applications for Asymmetric Multiprocessing ## OpenAMP Source Structure ``` |- lib/ -| |- common/ # common helper functions | |- virtio/ # virtio implementation | |- rpmsg/ # rpmsg implementation | |- remoteproc/ # remoteproc implementation -| | |- drivers # remoteproc drivers | |- proxy/ # implement one processor access device on the | | # other processor with file operations |- apps/ # demonstration/testing applications +| |- examples/ # Application samples using the OpenAMP framework. | |- machine/ # common files for machine can be shared by applications -| # It is up to each app to decide whether to use these files. +| | # It is up to each app to decide whether to use these files. | |- system/ # common files for system can be shared by applications | # It is up to each app to decide whether to use these files. -|- obsolete # It is used to build libs which may also required when -| # building the apps. It will be removed in future since -| # user can specify which libs to use when compiling the apps. |- cmake # CMake files +|- script # helper scripts (such as checkpatch) for contributors. ``` OpenAMP library libopen_amp is composed of the following directories in `lib/`: -* `common/` * `virtio/` * `rpmsg/` * `remoteproc/` From b2b716bea6c671055c00dfe700bf0da85d2da87a Mon Sep 17 00:00:00 2001 From: Arnaud Pouliquen Date: Tue, 21 Apr 2020 11:21:53 +0200 Subject: [PATCH 2/6] readme: add cmake options description Add the list of the cmake options with a short description Signed-off-by: Arnaud Pouliquen --- README.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/README.md b/README.md index b05c1b23d..4f36387be 100644 --- a/README.md +++ b/README.md @@ -77,6 +77,24 @@ compile libmetal library separately before you compiling OpenAMP library. In future, we will try to make libmetal as a submodule to OpenAMP to make this flow easier. +Some Cmake options are available to allow user to customize to the OpenAMP +library for it project: +* **WITH_PROXY** (default OFF): Include proxy support in the library. +* **WITH APPS** (default OFF): Build with sample applications. +* **WITH_PROXY_APPS** (default OFF):Build with proxy sample applications. +* **WITH_VIRTIO_MASTER** (default ON): Build with virtio master enabled. + This option can be set to OFF if the only the remote mode is implemented. +* **WITH_VIRTIO_SLAVE** (default ON): Build with virtio slave enabled. + This option can be set to OFF if the only the master mode is implemented. +* **WITH_STATIC_LIB** (default ON): Build with a static library. +* **WITH_SHARED_LIB** (default ON): Build with a shared library. +* **WITH_ZEPHYR** (default OFF): Build open-amp as a zephyr library. This option + is mandatory in a Zephyr environment. +* **RPMSG_BUFFER_SIZE** (default 512): adjust the size of the RPMsg buffers. + The default value of the RPMsg size is compatible with the Linux Kernel hard + coded value. If you AMP configuration is Linux kernel master/ OpenAMP remote, + this option must not be used. + ### Example to compile OpenAMP for Zephyr You can compile OpenAMP library for Zephyr. As OpenAMP uses libmetal, please refer to libmetal README to build libmetal From 6030dad5f43c00cf0c4abc176a7211b041af8fa4 Mon Sep 17 00:00:00 2001 From: Arnaud Pouliquen Date: Tue, 21 Apr 2020 12:11:22 +0200 Subject: [PATCH 3/6] readme: update zephyr example chapter As zephyr has is own fork of the lib, refer to it. Signed-off-by: Arnaud Pouliquen --- README.md | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 4f36387be..ebb13c66f 100644 --- a/README.md +++ b/README.md @@ -96,7 +96,13 @@ library for it project: this option must not be used. ### Example to compile OpenAMP for Zephyr -You can compile OpenAMP library for Zephyr. +The [Zephyr open-amp repo](https://github.com/zephyrproject-rtos/open-amp) +implements the open-amp library for the Zephyr project. It is mainly a fork of +this repository, with some add-ons for integration in the Zephyr project. +The standard way to compile OpenAMP for a Zephyr project is to use Zephyr build +environment. Please refer to [Zephyr OpenAMP samples](https://github.com/zephyrproject-rtos/zephyr/tree/master/samples/subsys/ipc) for examples. + +Nevertheless you can compile the OpenAMP project for Zephyr. As OpenAMP uses libmetal, please refer to libmetal README to build libmetal for Zephyr before building OpenAMP library for Zephyr. As Zephyr uses CMake, we build OpenAMP library as a target of Zephyr CMake From 5ceec8a69da70c950594caf8f3d3ac190b3a8816 Mon Sep 17 00:00:00 2001 From: Arnaud Pouliquen Date: Tue, 21 Apr 2020 11:23:25 +0200 Subject: [PATCH 4/6] readme: change the address of the mailing list The address of the mailing list is now openamp-rp@lists.openampproject.org The google group is no more used. Signed-off-by: Arnaud Pouliquen --- README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index ebb13c66f..6f87ff751 100644 --- a/README.md +++ b/README.md @@ -258,5 +258,7 @@ For now, it supports: 2. `sudo` is required to run the OpenAMP demos between Linux processes, as it doesn't work on some systems if you are normal users. +## Communication and Collaboration +[Subscribe](https://lists.openampproject.org/mailman/listinfo/openamp-rp) to the OpenAMP mailing list(openamp-rp@lists.openampproject.org). + For using the framework please refer to the wiki of the OpenAMP repo. -Subscribe to the open-amp mailing list at https://groups.google.com/group/open-amp. From 455b283be718ca3c847dd2c30abb7ab0a5bfb2b5 Mon Sep 17 00:00:00 2001 From: Arnaud Pouliquen Date: Tue, 21 Apr 2020 12:13:22 +0200 Subject: [PATCH 5/6] Readme: update reference to the wiki Provide direct link to the wiki page Signed-off-by: Arnaud Pouliquen --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 6f87ff751..1237182e1 100644 --- a/README.md +++ b/README.md @@ -261,4 +261,4 @@ For now, it supports: ## Communication and Collaboration [Subscribe](https://lists.openampproject.org/mailman/listinfo/openamp-rp) to the OpenAMP mailing list(openamp-rp@lists.openampproject.org). -For using the framework please refer to the wiki of the OpenAMP repo. +For more details on the framework please refer to the the [OpenAMP wiki](https://github.com/OpenAMP/open-amp/wiki). From 78a8973ae6c79c7a967581674ffa1db8e18b0f69 Mon Sep 17 00:00:00 2001 From: Arnaud Pouliquen Date: Tue, 21 Apr 2020 11:24:53 +0200 Subject: [PATCH 6/6] readme: Add a how to contribute chapter Waiting the wiki, add a chapter to inform how to contribute. this chapter is inspired from zephyr documentation. Signed-off-by: Arnaud Pouliquen --- README.md | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/README.md b/README.md index 1237182e1..90b585199 100644 --- a/README.md +++ b/README.md @@ -258,6 +258,47 @@ For now, it supports: 2. `sudo` is required to run the OpenAMP demos between Linux processes, as it doesn't work on some systems if you are normal users. +## How to contribute: +As an open-source project, we welcome and encourage the community to submit patches directly to the project. As a contributor you should be familiar with common developer tools such as Git and CMake, and platforms such as GitHub. +Then following points should be rescpected to facilitate the review process. + +### Licencing +Code is contributed to the Linux kernel under a number of licenses, but all code must be compatible with version the [BSD License](https://github.com/OpenAMP/open-amp/blob/master/LICENSE.md), which is the license covering the OpenAMP distribution as a whole. In practice, use the following tag instead of the full license text in the individual files: + + ``` + SPDX-License-Identifier: BSD-3-Clause + SPDX-License-Identifier: BSD-2-Clause + ``` +### Signed-off-by +Commit message must contain Signed-off-by: line and your email must match the change authorship information. Make sure your .gitconfig is set up correctly: + + ``` + git config --global user.name "first-name Last-Namer" + git config --global user.email "yourmail@company.com" + ``` +### gitlint +Before you submit a pull request to the project, verify your commit messages meet the requirements. The check can be performed locally using the the gitlint command. + +Run gitlint locally in your tree and branch where your patches have been committed: + + ```gitlint``` +Note, gitlint only checks HEAD (the most recent commit), so you should run it after each commit, or use the --commits option to specify a commit range covering all the development patches to be submitted. + +### Code style +In general, follow the Linux kernel coding style, with the following exceptions: + +* Use /** */ for doxygen comments that need to appear in the documentation. + +The Linux kernel GPL-licensed tool checkpatch is used to check coding style conformity.Checkpatch is available in the scripts directory. + +To check your \ commits in your git branch: + ``` + ./scripts/checkpatch.pl --strict -g HEAD- + + ``` +### Send a pull request +We use standard github mechanism for pull request. Please refer to github documentation for help. + ## Communication and Collaboration [Subscribe](https://lists.openampproject.org/mailman/listinfo/openamp-rp) to the OpenAMP mailing list(openamp-rp@lists.openampproject.org).