Skip to content

Commit 2f6b1af

Browse files
committed
[MP1] Add the first OpenAMP middleware
1 parent 2e6ef61 commit 2f6b1af

File tree

479 files changed

+46390
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

479 files changed

+46390
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,101 @@
1+
language: minimal # setting language to C will override cross-compiler and fail
2+
3+
compiler:
4+
- gcc
5+
6+
sudo: required
7+
dist: trusty
8+
9+
env:
10+
global:
11+
- ZEPHYR_TOOLCHAIN_VARIANT=zephyr
12+
- ZEPHYR_SDK_INSTALL_DIR=/opt/zephyr-sdk
13+
- ZEPHYR_BASE=$TRAVIS_BUILD_DIR/deps/zephyr
14+
- ZEPHYR_SDK_VERSION=0.9.3
15+
- ZEPHYR_SDK_DOWNLOAD_FOLDER=https://github.com/zephyrproject-rtos/meta-zephyr-sdk/releases/download/$ZEPHYR_SDK_VERSION
16+
- ZEPHYR_SDK_SETUP_BINARY=zephyr-sdk-$ZEPHYR_SDK_VERSION-setup.run
17+
- ZEPHYR_SDK_DOWNLOAD_URL=$ZEPHYR_SDK_DOWNLOAD_FOLDER/$ZEPHYR_SDK_SETUP_BINARY
18+
- FREERTOS_ZIP_URL=https://cfhcable.dl.sourceforge.net/project/freertos/FreeRTOS/V10.0.1/FreeRTOSv10.0.1.zip
19+
- GCC_ARM_COMPILER_PACKAGE=gcc-arm-embedded_7-2018q2-1~trusty1_amd64.deb
20+
21+
matrix:
22+
fast_finish: true
23+
include:
24+
- os: linux
25+
env: TARGET="zephyr"
26+
- os: linux
27+
env: TARGET="linux"
28+
- os: linux
29+
env: TARGET="generic"
30+
- os: linux
31+
env: TARGET="freertos"
32+
33+
cache:
34+
directories:
35+
- $ZEPHYR_SDK_INSTALL_DIR
36+
- /usr/local/bin
37+
38+
before_install:
39+
- if [[ "$TARGET" == "zephyr" ]]; then
40+
sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test &&
41+
sudo apt-get update -qq &&
42+
sudo apt-get install libc6-dev-i386 make gperf gcc g++ python3-ply python3-yaml python3-pip device-tree-compiler ncurses-dev uglifyjs -qq &&
43+
sudo pip3 install pyelftools;
44+
fi
45+
- if [[ "$TARGET" == "linux" ]]; then
46+
sudo apt-get update -qq &&
47+
sudo apt-get install libsysfs-dev libhugetlbfs-dev make gcc;
48+
fi
49+
# This is to kick start CI on generic platform. Will need to have a proper way to get the required packages
50+
- if [[ "$TARGET" == "generic" || "$TARGET" == "freertos" ]]; then
51+
wget http://ppa.launchpad.net/team-gcc-arm-embedded/ppa/ubuntu/pool/main/g/gcc-arm-none-eabi/${GCC_ARM_COMPILER_PACKAGE} &&
52+
sudo dpkg -i ${GCC_ARM_COMPILER_PACKAGE};
53+
fi
54+
- if [[ "$TARGET" == "freertos" ]]; then
55+
wget $FREERTOS_ZIP_URL &&
56+
pwd && ls &&
57+
unzip FreeRTOSv10.0.1.zip > /dev/null;
58+
fi
59+
60+
install: >
61+
if [[ "$TARGET" == "zephyr" && "$(cat $ZEPHYR_SDK_INSTALL_DIR/sdk_version)" != "$ZEPHYR_SDK_VERSION" ]]; then
62+
wget $ZEPHYR_SDK_DOWNLOAD_URL &&
63+
chmod +x $ZEPHYR_SDK_SETUP_BINARY &&
64+
rm -rf $ZEPHYR_SDK_INSTALL_DIR &&
65+
./$ZEPHYR_SDK_SETUP_BINARY --quiet -- -y -d $ZEPHYR_SDK_INSTALL_DIR > /dev/null;
66+
fi
67+
68+
before_script: >
69+
if [[ "$TARGET" == "zephyr" ]]; then
70+
cd .. &&
71+
git clone --depth=1 https://github.com/zephyrproject-rtos/zephyr.git &&
72+
cd zephyr &&
73+
source zephyr-env.sh;
74+
fi
75+
76+
script:
77+
- if [[ "$TARGET" == "zephyr" ]]; then
78+
mkdir -p ../libmetal/build-zephyr &&
79+
cd ../libmetal/build-zephyr &&
80+
cmake .. -DWITH_ZEPHYR=on -DBOARD=qemu_cortex_m3 -DWITH_TESTS=on &&
81+
make VERBOSE=1;
82+
fi
83+
- if [[ "$TARGET" == "linux" ]]; then
84+
mkdir -p build-linux &&
85+
cd build-linux &&
86+
cmake .. -DWITH_TESTS_EXEC=on &&
87+
make VERBOSE=1 all test;
88+
fi
89+
- if [[ "$TARGET" == "generic" ]]; then
90+
mkdir -p build-generic &&
91+
cd build-generic &&
92+
cmake .. -DCMAKE_TOOLCHAIN_FILE=template-generic &&
93+
make VERBOSE=1;
94+
fi
95+
- if [[ "$TARGET" == "freertos" ]]; then
96+
mkdir -p build-freertos &&
97+
cd build-freertos &&
98+
export &&
99+
cmake .. -DCMAKE_TOOLCHAIN_FILE=template-freertos -DCMAKE_C_FLAGS="-I$PWD/../FreeRTOSv10.0.1/FreeRTOS/Source/include/ -I$PWD/../FreeRTOSv10.0.1/FreeRTOS/Demo/CORTEX_STM32F107_GCC_Rowley -I$PWD/../FreeRTOSv10.0.1/FreeRTOS/Source/portable/GCC/ARM_CM3" &&
100+
make VERBOSE=1;
101+
fi
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
cmake_minimum_required (VERSION 2.6)
2+
if (POLICY CMP0048)
3+
cmake_policy(SET CMP0048 NEW)
4+
endif()
5+
6+
list (APPEND CMAKE_MODULE_PATH
7+
"${CMAKE_CURRENT_SOURCE_DIR}/cmake"
8+
"${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules"
9+
"${CMAKE_CURRENT_SOURCE_DIR}/cmake/platforms")
10+
11+
include (syscheck)
12+
project (metal C)
13+
14+
include (CheckIncludeFiles)
15+
include (CheckCSourceCompiles)
16+
include (collect)
17+
include (options)
18+
include (depends)
19+
20+
foreach(_inc_path ${CMAKE_INCLUDE_PATH})
21+
collect (PROJECT_INC_DIRS "${_inc_path}")
22+
endforeach()
23+
24+
enable_testing ()
25+
26+
add_subdirectory (lib)
27+
28+
if (WITH_TESTS)
29+
add_subdirectory (test)
30+
endif (WITH_TESTS)
31+
32+
if (WITH_DOC)
33+
add_subdirectory (doc)
34+
endif (WITH_DOC)
35+
36+
if (WITH_EXAMPLES)
37+
add_subdirectory (examples)
38+
endif (WITH_EXAMPLES)
39+
40+
# vim: expandtab:ts=2:sw=2:smartindent
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
Software License Agreement (BSD License)
2+
========================================
3+
4+
Copyright (c) 2015, Xilinx Inc. and Contributors. All rights reserved.
5+
6+
Redistribution and use in source and binary forms, with or without
7+
modification, are permitted provided that the following conditions are met:
8+
9+
1. Redistributions of source code must retain the above copyright notice,
10+
this list of conditions and the following disclaimer.
11+
12+
2. Redistributions in binary form must reproduce the above copyright notice,
13+
this list of conditions and the following disclaimer in the documentation
14+
and/or other materials provided with the distribution.
15+
16+
3. Neither the name of Xilinx nor the names of its contributors may be used
17+
to endorse or promote products derived from this software without
18+
specific prior written permission.
19+
20+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
21+
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
22+
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
23+
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
24+
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
25+
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
26+
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
27+
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
28+
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
29+
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
30+
POSSIBILITY OF SUCH DAMAGE.
31+
32+
33+
Notes
34+
=========================================
35+
Use the following tag instead of the full license text in the individual files:
36+
37+
SPDX-License-Identifier: BSD-3-Clause
38+
39+
This enables machine processing of license information based on the SPDX
40+
License Identifiers that are here available: http://spdx.org/licenses/
41+
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# libmetal Maintainers
2+
3+
libmetal project is maintained by the OpenAMP open source community.
4+
Everyone is encouraged to submit issues and changes to improve libmetal.
5+
6+
The intention of this file is to provide a set of names that developers can
7+
consult when they have a question about OpenAMP and to provide a a set of
8+
names to be CC'd when submitting a patch.
9+
10+
## Project Administration
11+
Wendy Liang <wendy.liang@xilinx.com>
12+
13+
### All patches CC here
14+
open-amp@googlegroups.com
15+
16+
## Machines
17+
### Xilinx Platform - Zynq-7000
18+
Wendy Liang <wendy.liang@xilinx.com>
19+
20+
### Xilinx Platform - Zynq UltraScale+ MPSoC
21+
Wendy Liang <wendy.liang@xilinx.com>

0 commit comments

Comments
 (0)