Compare commits

..

25 Commits

Author SHA1 Message Date
Dave Barach
cf6511560e VPP-83: fix collateral damage
Accidentally removed pthread_mutex_unlock (&root_rp->mutex) in the
dead client scan case. Oops. Bad idea.

Change-Id: I488b7e39d01c267052785bd346e8846351db90a9
Signed-off-by: Dave Barach <dave@barachs.net>
2016-06-07 17:36:12 -04:00
Filip Tehlar
3f23e9a3c8 ONE-18: Fix trailing garbage string in LISP status dump API
Change-Id: I5cba5eae5a981e41df3f227834a079e10982537f
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2016-06-06 13:29:10 +02:00
Dave Wallace
fe82e14267 VPP-112: linux kernel info missing from build log
Change-Id: I343418d409d682b00e74e41236382fdc6b3c780c
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
2016-06-05 13:49:55 +00:00
John Lo
1904214884 VPP-113: BVI shall filter unicast DMAC for L2 to L3 forwading
As BVI receive a packet with unicast DMAC from the BD, including unknown
unicast flood packet, the packet should not be L3 forwarded unless its
DMAC matches the MAC of the BVI.

Change-Id: I46e18629c901062592c8ebe3a238c5cfdc1096b4
Signed-off-by: John Lo <loj@cisco.com>
2016-06-04 00:02:37 -04:00
John Lo
2671f1188d VPP-100: Fix IP4 local handling of TCP/IP fragmented packet
Fix previous change that does not work on little endian machines.
Use inline call ip4_is_fragment() which is endian neutral.

Change-Id: I5a35d89d936650ab6c628dfc388b8c992a74a589
Signed-off-by: John Lo <loj@cisco.com>
2016-06-03 20:48:31 -04:00
Chris Luke
b98a3a87a9 VPP-91 fix sr tunnel add_del collision check
The add_del function was not properly checking if a tunnel already
existed; instead it was checking if the given tunnel name existed.
If no tunnel name was given it flat out refused to add a tunnel
even though that is optional.

Cleanup the add/del parameter validation to "do what I expect" it
to do:

When adding a tunnel:
- If a "name" is given, it must not exist.
- The "key" is always checked, and must not exist.

When deleting a tunnel:
- If the "name" is given, and it exists, then use it.
- If the "name" is not given, use the "key".
- If the "name" and the "key" are given, then both must point to the
  same thing.

Change-Id: I9b48ae0203f9664cf8af0f7dc49bf480ddec10d5
Signed-off-by: Chris Luke <chrisy@flirble.org>
(cherry picked from commit e54436005341800f76a584299ef8bf99e8d66227)
2016-06-03 00:58:17 +00:00
Chris Luke
1f752a3f8f VPP-92 Fixup some srv6 issues
Some small fixes to the srv6 code to bring it toward
conformance with draft-previdi-6man-segment-routing-header-05.

- The first segment needs to remain in the segment list.
- The segment list template needs a space for the ultimate
  destination.
- The ultimate destination needs to be inserted into that
  space when adding the SRH.

Change-Id: I66db6912e0128da084f14ceca20918ef67ccff79
Signed-off-by: Chris Luke <chrisy@flirble.org>
(cherry picked from commit 4b8b718ff9bbba3bea018505ac591bb737f68001)
2016-06-03 00:57:10 +00:00
Ed Warnicke
45eb9713fe VPP-107 Fix for mistake that breaks pkg-rpm in
https://gerrit.fd.io/r/#/c/1338/

Change-Id: I8b7fffe24cbeb435b18faaada9ef1cea9fd93d39
Signed-off-by: Ed Warnicke <eaw@cisco.com>
2016-06-03 00:28:49 +00:00
John Lo
5faba3aae6 VPP-106: Patch e40i driver to support VLAN sub-interface
Check packet for presence of VLAN tag in the MAC header and set
the PKT_RX_VLAN_PKT flag to trigger sub-interface lookup in VPP
ethernet-input node.

Change-Id: Iadbfc59d08ef85efb936c88323a90194f3cd656f
Signed-off-by: John Lo <loj@cisco.com>
2016-06-02 15:52:21 -04:00
John Lo
142db43bb6 VPP-100: Fix IPv4 local handling of IP fragmented packets
Before VPP is enhenced to do IP reassembly of local packets, just set
the protocol path to "experimental" for now so they will be error-punted
as unknow IP protocol.

Change-Id: I2ffefb0b4205357653ba24d80c722cafd5972fba
Signed-off-by: John Lo <loj@cisco.com>
2016-06-02 14:16:29 +00:00
Chris Luke
a0e1f31b3d VPP-105 Map API SHM uid/gid name to number
When providing uid or gid for the API SHM, if non-numeric values
are given look them up in the local system user database and if
found use the values discovered.

Change-Id: I95152f58646643bc44d2af4cbad6338901935c69
Signed-off-by: Chris Luke <chrisy@flirble.org>
2016-06-01 19:50:09 -04:00
Chris Luke
966bef4ad1 VPP-98 Dedicated storage for VXLAN over IPv6 hash keys
When creating VXLAN over IPv6 the code was using storage for the
hash key that could later be moved. Since the key is larger than
the word size this was being referenced as a pointer; when the
storage moves that breaks the hash.

Instead allocate dedicated storage for the key.

This patch also includes other minor cleanups, including using
clib_memcpy in places it should be used and some whitespace
fixes.

Change-Id: I579f2cb515853ef56dedcca350fcad08aa6111a9
Signed-off-by: Chris Luke <chrisy@flirble.org>
2016-06-01 19:53:54 +00:00
Dave Barach
db0cf7963b VPP-83 Allow non-privileged clients to use the vpp binary API.
Use the command line argument "api-segment { uid <nnn> gid <nnn> }" to
configure shared memory segment file ownership. Defaults to uid = gid
= 0.  Shared-memory segments are explicitly set to 0770 mode, aka
"rwxrwx---".

Change-Id: Ic5d596b68139add61e7de6ace035c57dfd030111
Signed-off-by: Dave Barach <dave@barachs.net>
2016-06-01 19:21:58 +00:00
John Lo
8d9e80583f VPP-102: vHost reconnect to previously used sockets on VPP restart
Change-Id: Ida11bddb52268e0e8513b7b379eeed6103bd48f1
Signed-off-by: John Lo <loj@cisco.com>
2016-05-31 23:32:09 +00:00
Ed Warnicke
6795fb9f70 Fix build-root/scripts/version to not have spurious ~
Change-Id: Id28f134e3a4aa19c5756014d53004501db0d0c88
Signed-off-by: Ed Warnicke <eaw@cisco.com>
2016-05-31 21:35:22 +00:00
John Lo
245576a438 VPP97: Flooding of pkts with multiple buffers in BD with BVI crashes VPP
The loopback interface should use vnet_interface_output_no_flatten so
follow-on buffers of a jumbo packet do not get put on the output frame
and be sent back to ethernet-input or l2-input node.

The replication_recycle_callback() function should not assume follow-on
buffers of a jumbo packet are on the buffer free list.

Change-Id: Ide646a6d9b43e82782c0581ea3022a9e70f82582
Signed-off-by: John Lo <loj@cisco.com>
2016-05-31 16:25:13 -04:00
Andrej Kozemcak
68660906e6 ONE-15: Fix duplicate locator, refactoring locator
Check duplication locator and clean after locator when remove it.
Refactoring locator_set code.

Change-Id: Ib83cbcddc7a363a60fa5b6a366203d0dc0ea7ca6
Signed-off-by: Andrej Kozemcak <akozemca@cisco.com>
2016-05-30 09:17:17 +02:00
John Lo
3d4110fe0c VPP-96 ENID driver update for rx of jumbo pkts using muliple mbuf's
Change-Id: I0e985b079da3224f4886e3ee2cece4d046e291eb
Signed-off-by: John Lo <loj@cisco.com>
2016-05-28 11:44:45 -04:00
Chris Luke
f090a30eef VPP-95 VXLAN add_del API intermittent failure
The VXLAN add_del API sometimes rejects calls with
VNET_API_ERROR_SAME_SRC_DST when the two parameters are obviously
different. This is because the API code is checking the "is_ip6" flag in
a not-yet initialized area of memory leading to random results.

Also fix help text for vxlan_add_del_tunnel in vat.

This does not change the API; it repairs intermittent failure.

Change-Id: I41863694f478c1f669078f82f69d8cca4841c989
Signed-off-by: Chris Luke <chrisy@flirble.org>
2016-05-27 12:11:24 -04:00
Andrej Kozemcak
edc40dbda0 ONE-14: Fix crash when re-enable Lisp
Change-Id: Ib95338d7055dea9036eddb7dff5ca7ccbcb35639
Signed-off-by: Andrej Kozemcak <akozemca@cisco.com>
(cherry picked from commit 94e34764b46a2babcaea6b309158524a7c1bb632)
2016-05-25 12:20:03 +00:00
Hongjun Ni
aafe40deae VPP-89: Fix an issue in format_vxlan_gpe_tunnel
Change-Id: Ie81e2eb918e441ddaa9e7ab57e8bb0129f0f4f8f
Signed-off-by: Hongjun Ni <hongjun.ni@intel.com>
2016-05-25 17:35:51 +08:00
Marek Gradzki
205c75c8db VPP-86: fix array copy in generated JNI code
Change-Id: Ic67b3c0623d98c5ee3f1ffa1e1bd9cfb96b233bd
Signed-off-by: Marek Gradzki <mgradzki@cisco.com>
2016-05-24 17:33:16 +02:00
Chris Luke
1728f85066 VPP-77 Creating VXLAN over IPv6 via API fails
Tunnel dst is incorrectly being set to the requested src address.

Change-Id: I44e2ee475f0572e78d148951c5d4684e85e08ce7
Signed-off-by: Chris Luke <chrisy@flirble.org>
2016-05-20 12:14:32 -04:00
Ed Warnicke
2c386b26c6 Add newline to the end of .gitreview
Change-Id: I9a5a97c4a42b8aebbb6ba132879b7843ca7cfacd
Signed-off-by: Ed Warnicke <eaw@cisco.com>
2016-05-16 20:37:19 -05:00
Ed Warnicke
826d4f7b1f Initial changes for stable/1606 branch
This patch adds an entry for the defaultbranch
in .gitreview and also changes the generated
jar file version to 16.06.

Change-Id: I9acd35745eee7daa90d9abcc33e75b76c11af76e
Signed-off-by: Ed Warnicke <eaw@cisco.com>
2016-05-16 15:03:17 -05:00
5257 changed files with 304265 additions and 1317776 deletions

View File

@ -1,48 +0,0 @@
# Minimal clang-format version is 11
BasedOnStyle: GNU
UseTab: Always
SpaceAfterCStyleCast: true
SortIncludes: false
AlignConsecutiveMacros: true
BreakBeforeTernaryOperators: false
BreakBeforeBinaryOperators: None
ContinuationIndentWidth: 2
ForEachMacros:
- 'clib_bitmap_foreach'
- 'pool_foreach'
- 'pool_foreach_index'
- 'pool_foreach_pointer'
- 'vec_foreach'
- 'vec_foreach_backwards'
- 'vec_foreach_index'
- 'vec_foreach_index_backwards'
- 'vec_foreach_pointer'
- 'vlib_foreach_rx_tx'
- 'foreach_int'
- 'foreach_pointer'
- 'foreach_vlib_main'
- 'foreach_set_bit_index'
- 'foreach_vlib_frame_bitmap_set_bit_index'
- 'FOREACH_ARRAY_ELT'
- 'RTE_ETH_FOREACH_DEV'
- 'foreach_vnet_dev_rx_queue_runtime'
- 'foreach_vnet_dev_counter'
- 'foreach_vnet_dev_port_rx_queue'
- 'foreach_vnet_dev_port_tx_queue'
- 'foreach_vnet_dev_port'
- 'foreach_vnet_dev_args'
- 'foreach_vnet_dev_port_args'
StatementMacros:
- 'CLIB_MULTIARCH_FN'
- 'VLIB_NODE_FN'
- 'VNET_DEV_NODE_FN'
- 'VNET_DEVICE_CLASS_TX_FN'
- '__clib_section'
- '__clib_aligned'
WhitespaceSensitiveMacros:
- 'WARN_ON'
- 'WARN_OFF'

View File

@ -1,8 +0,0 @@
Checks: "-*,\
misc-*,\
bugprone-*,\
-bugprone-reserved-identifier,\
-performance-*,\
clang-analyzer-*,\
-clang-analyzer-valist.Uninitialized,\
"

View File

@ -1,48 +0,0 @@
# <feature-name>: <subject>
# |<---- Using a maximum of 50 characters ---->|
#
# Explain why this change is being made
# |<---- Try to limit each line to a maximum of 72 characters ---->|
# Ticket: <JIRA #id>
# Type: <type>
# Fixes: <offending-git-commit-id>
# Change-Id: <sha1>
# Signed-off-by: <email>
#
#
# --- COMMIT END ---
#
# Type can be
# feature (new feature)
# fix (bug fix)
# refactor (refactoring production code)
# improvement (minor improvements in existing feature)
# style (formatting, missing semi colons, etc; no code change)
# docs (changes to documentation)
# test (adding or refactoring tests; no production code change)
# make (change the build process, or tools, or infrastructure)
#
# feature-name: Is the name of the VPP feature, plugin or directory.
# Commits across multiple components should be split.
# E.g. ip, fib, nat, acl, host, api
#
# Fixes: If type is fix refers to the original commit (optional).
# Ticket: Refers to JIRA ticket if it exists (optional).
#
# --------------------
# Remember to:
# Lowercase the subject line.
# Use the imperative mood in the subject line.
# Not end the subject line with a period.
# Separate subject from body with a blank line.
# Use the body to explain what and why vs. how.
# Use multiple lines with "-" for bullet points in body.
# --------------------
# Usage:
#
# The template is automatically added to the current repository by
# make install-dep.
# (git config commit.template .git_commit_template.txt)
#
# --------------------

View File

@ -1,21 +0,0 @@
---
name: Close Pull Request
on:
pull_request_target:
types: [opened]
jobs:
run:
runs-on: ubuntu-latest
steps:
- uses: superbrothers/close-pull-request@v3
with:
# Optional. Post a issue comment just before closing a pull request.
comment: "Thank you so much for your interest! VPP takes patches at https://gerrit.fd.io/
```
git clone https://gerrit.fd.io/r/vpp
```
Using [git review](https://www.mediawiki.org/wiki/Gerrit/git-review) to contribute patches is recommended"

99
.gitignore vendored
View File

@ -1,5 +1,4 @@
*~
*.sw[op]
/build-root/.ccache
/build-root/build-*/
@ -8,35 +7,30 @@
/build-root/dpdk-includes/
/build-root/packages-vpp/
/build-root/path_setup
/build-root/deb/debian/vpp-plugins/
/build-root/deb/.pybuild/
/build-root/*.buildinfo
/build-root/build-config.mk
/build-root/*.deb
/build-root/*.rpm
/build-root/*.tar.xz
/build-root/*.changes
/build-root/rpmbuild/
/build-root/test-coverage/
/build-root/test/
/build-config.mk
/build/external/*.tar.gz
/build/external/*.tar.xz
/build/external/vpp-*
/build/external/dpdk_mlx_default.sh
/build/external/downloads/
/vpp-api/python/vpp_papi/vpp_papi.py
/dpdk/*.tar.gz
/path_setup
/tools/
# start autotools ignore
autom4te.cache/
config/
Makefile
Makefile.in
aclocal.m4
app.info
compile
config.h
config.h.in
config.log
config.guess
config.sub
config.status
configure
configure.scan
coverage_report
depcomp
@ -49,91 +43,20 @@ ltmain.sh
ylwrap
test-driver
.cproject
*.iml
.deps.ok
.bootstrap.ok
.settings
.autotools
# stop autotools ignore
# OSX and some IDE
# OSX and some IDE
.DS_Store
.idea/
.project
.cproject
.pydevproject
.vscode/
cmake-build*/
# cscope and ctags
/cscope.*
/tags
ID
TAGS
# ggtags
GPATH
GRTAGS
GTAGS
# Generated documentation
/build-root/docs
/build-root/.doxygen-bootstrap.ok
/build-root/.doxygen-siphon.dep
/docs/venv
# language servers
compile_commands.json
.clangd
.cache
# indent backup files
*.BAK
# Python bytecode
*.pyc
# Python api generator
/src/vpp-api/python/build
/src/vpp-api/python/dist
/src/vpp-api/python/vpp_papi.egg-info
/src/vpp_api/.tox
/src/vpp_api/.stestr
# vppctl command list
/src/scripts/vppctl-cmd-list
# No core files
**/core
# extra scripts config
/extras/scripts/.config/
# extras gomemif build files
/extras/gomemif/bazel*
# vpptop build files
/extras/vpptop/build/*
# debian packaging
.pc
# No test log files
**/test-run-*-*-*
# host stack test framework
/extras/hs-test/vpp-data
/extras/hs-test/hs-test
/extras/hs-test/http_server
/extras/hs-test/.build.ok
/extras/hs-test/summary/
# ./configure
/CMakeFiles
/bin
/lib
/.ninja_deps
/.ninja_log
/.cmake
/CMakeCache.txt
/build.ninja
/cmake_install.cmake
/startup.conf
/startup.vpp

View File

@ -2,4 +2,4 @@
host=gerrit.fd.io
port=29418
project=vpp
defaultbranch=stable/2406
defaultbranch=stable/1606

105
INFO.yaml
View File

@ -1,105 +0,0 @@
---
project: 'vpp'
project_creation_date: '2015-12-08'
project_category: ''
lifecycle_state: 'Incubation'
project_lead: &vpp_ptl
name: 'Damjan Marion'
email: 'dmarion@me.com'
id: 'dmarion'
company: 'cisco'
timezone: 'Europe/Zagreb'
primary_contact: *vpp_ptl
issue_tracking:
type: 'jira'
url: 'https://jira.fd.io/projects/vpp'
key: 'VPP'
mailing_list:
type: 'groups.io'
url: 'https://lists.fd.io/g/vpp-dev'
tag: '<[sub-project_name]>'
realtime_discussion:
type: 'irc'
server: 'freenode.net'
channel: 'fdio-vpp'
meetings:
- type: 'zoom'
agenda: 'n/a'
url: 'https://wiki.fd.io/view/VPP/Meeting'
server: 'n/a'
channel: 'fdio-vpp'
repeats: 'weekly'
time: '08:00 PT'
repositories:
- 'vpp'
committers:
- <<: *vpp_ptl
- name: 'Dave Barach'
company: 'cisco'
email: 'openvpp@barachs.net'
id: 'dbarach'
- name: 'Florin Coras'
company: 'cisco'
email: 'florin.coras@gmail.com'
id: 'florin.coras'
- name: 'Benoit Ganne'
company: 'cisco'
email: 'bganne@cisco.com'
id: 'bganne'
- name: 'John Lo'
company: 'cisco'
email: 'loj@cisco.com'
id: 'lojohn'
- name: 'Chris Luke'
company: 'comcast'
email: 'chris_luke@comcast.com'
id: 'chrisluke'
- name: 'Neale Ranns'
company: 'cisco'
email: 'nranns@cisco.com'
id: 'nranns'
- name: 'Matthew Smith'
company: 'netgate'
email: 'mgsmith@netgate.com'
id: 'mgsmith'
- name: 'Ole Trøan'
company: 'employees'
email: 'otroan@employees.org'
id: 'otroan'
- name: 'Paul Vinciguerra'
company: 'vinciconsulting'
email: 'pvinci@vinciconsulting.com'
id: 'pvinci'
- name: 'Dave Wallace'
company: 'gmail'
email: 'dwallacelf@gmail.com'
id: 'dwallacelf'
- name: 'Ed Warnicke'
company: 'gmail'
email: 'hagbard@gmail.com'
id: 'hagbard'
- name: 'Andrew Yourtchenko'
company: 'cisco'
email: 'ayourtch@cisco.com'
id: 'ayourtch'
- name: 'Fan Zhang'
company: 'intel'
email: 'roy.fan.zhang@intel.com'
id: 'royzhang1980'
- name: 'Mohammed HAWARI'
company: 'cisco'
email: 'momohawari@gmail.com'
id: 'momohawari'
tsc:
# yamllint disable rule:line-length
approval: 'https://wiki.fd.io/view/TSC/Meeting_Minutes'
changes:
- type: 'Promotion'
name: 'Damjan Marion'
link: 'https://lists.fd.io/g/vpp-dev/message/17521'
- type: 'Addition'
name: 'Fan Zhang'
link: 'https://lists.fd.io/g/vpp-dev/message/19068'
- type: 'Approval'
name: 'Mohammed HAWARI'
link: 'https://ircbot.wl.linuxfoundation.org/meetings/fdio-meeting/2023/fd_io_tsc/fdio-meeting-fd_io_tsc.2023-06-01-15.00.html'

File diff suppressed because it is too large Load Diff

846
Makefile

File diff suppressed because it is too large Load Diff

View File

@ -1,7 +1,7 @@
Vector Packet Processing
========================
## Introduction
## Introduction.
The VPP platform is an extensible framework that provides out-of-the-box
production quality switch/router functionality. It is the open source version
@ -16,37 +16,34 @@ For more information on VPP and its features please visit the
[What is VPP?](https://wiki.fd.io/view/VPP/What_is_VPP%3F) pages.
## Changes
## Directory layout.
Details of the changes leading up to this version of VPP can be found under
doc/releasenotes.
Directory name | Description
---------------------- | -------------------------------------------
build-data | Build metadata
build-root | Build output directory
doxygen | Documentation generator configuration
dpdk | DPDK patches and build infrastructure
g2 | Event log visualization tool
gmod | perf related?
perftool | Performance tool
sample-plugin | A sample plugin
@ref svm | Shared virtual memory allocation library
test | Unit tests
@ref vlib | VPP application library source
@ref vlib-api | VPP API library source
@ref vnet | VPP networking source
@ref vpp | VPP application source
@ref vpp-api | VPP application API source
vppapigen | VPP API generator source
vpp-api-test | VPP API test program source
@ref vppinfra | VPP core library source
(If the page you are viewing is not generated by Doxygen then
ignore any @@ref labels in the above table.)
## Directory layout
| Directory name | Description |
| ---------------------- | ------------------------------------------- |
| build-data | Build metadata |
| build-root | Build output directory |
| docs | Sphinx Documentation |
| dpdk | DPDK patches and build infrastructure |
| extras/libmemif | Client library for memif |
| src/examples | VPP example code |
| src/plugins | VPP bundled plugins directory |
| src/svm | Shared virtual memory allocation library |
| src/tests | Standalone tests (not part of test harness) |
| src/vat | VPP API test program |
| src/vlib | VPP application library |
| src/vlibapi | VPP API library |
| src/vlibmemory | VPP Memory management |
| src/vnet | VPP networking |
| src/vpp | VPP application |
| src/vpp-api | VPP application API bindings |
| src/vppinfra | VPP core library |
| src/vpp/api | Not-yet-relocated API bindings |
| test | Unit tests and Python test harness |
## Getting started
## Getting started.
In general anyone interested in building, developing or running VPP should
consult the [VPP wiki](https://wiki.fd.io/view/VPP) for more complete
@ -60,13 +57,13 @@ coverage of the topic.
For the impatient, some salient information is distilled below.
### Quick-start: On an existing Linux host
### Quick-start: On an existing Linux host.
To install system dependencies, build VPP and then install it, simply run the
build script. This should be performed a non-privileged user with `sudo`
access from the project base directory:
./extras/vagrant/build.sh
./build-root/vagrant/build.sh
If you want a more fine-grained approach because you intend to do some
development work, the `Makefile` in the root directory of the source tree
@ -76,9 +73,9 @@ interest. To see the available targets run:
make
### Quick-start: Vagrant
### Quick-start: Vagrant.
The directory `extras/vagrant` contains a `VagrantFile` and supporting
The directory `build-root/vagrant` contains a `VagrantFile` and supporting
scripts to bootstrap a working VPP inside a Vagrant-managed Virtual Machine.
This VM can then be used to test concepts with VPP or as a development
platform to extend VPP. Some obvious caveats apply when using a VM for VPP
@ -91,11 +88,7 @@ for this can be found [on the Setting up Vagrant wiki page]
(https://wiki.fd.io/view/DEV/Setting_Up_Vagrant).
## More information
Several modules provide documentation, see @subpage user_doc for more
end-user-oriented information. Also see @subpage dev_doc for developer notes.
## More information.
Visit the [VPP wiki](https://wiki.fd.io/view/VPP) for details on more
advanced building strategies and other development notes.
advanced building strategies and development notes.

View File

@ -1,12 +0,0 @@
# Copyright (c) 2015 Cisco and/or its affiliates.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at:
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

View File

@ -0,0 +1,55 @@
# Temporary until Cavium upstreams their work
cavium-dpdk_configure = \
src_dir=$(call find_source_fn,$(PACKAGE_SOURCE)) ; \
dst_dir=$(PACKAGE_BUILD_DIR) ; \
tar -C $${src_dir} -cf - . | tar -C $${dst_dir} -xf - ; \
cd $${dst_dir} ; \
: colossal hemorrhoid to configure headroom ; \
if [ x$($(PACKAGE)_configure_args_$(PLATFORM)) = "x" ] ; then \
HR=256 ; \
else \
dpdk_configure_args=$($(PACKAGE)_configure_args_$(PLATFORM)) ; \
if [ $$dpdk_configure_args = "--with-headroom=256" ] ; then \
HR=256 ; \
elif [ $$dpdk_configure_args = "--with-headroom=384" ] ; then \
HR=384 ; \
else \
HR=256 ; \
fi ; \
fi ; \
env HR=$$HR \
spp -o \
$(PACKAGE_BUILD_DIR)/config/common_linuxapp \
$(PACKAGE_BUILD_DIR)/config/common_linuxapp.spp \
; \
env $(CONFIGURE_ENV) \
make config T=arm64-thunderx-linuxapp-gcc RTE_ARCH=arm64 \
CC=aarch64-thunderx-linux-gnu-gcc V=0 \
RTE_SDK=$(PACKAGE_BUILD_DIR) \
RTE_TARGET=arm-default-linuxapp-gcc
# Note: add e.g. "-O0" to EXTRA_CFLAGS if desired: EXTRA_CFLAGS='-g -O0'
cavium-dpdk_make_args = install T=arm64-thunderx-linuxapp-gcc RTE_ARCH=arm64 \
CC=aarch64-thunderx-linux-gnu-gcc V=0 \
RTE_SDK=$(PACKAGE_BUILD_DIR) \
RTE_TARGET=arm-default-linuxapp-gcc
cavium-dpdk_install = \
src_dir=$(PACKAGE_BUILD_DIR) ; \
dst_dir=$(PACKAGE_INSTALL_DIR) ; \
tar -h -C $${src_dir}/arm64-thunderx-linuxapp-gcc -cf - . \
| tar -C $${dst_dir} -xf -
# dpdk libraries end up in .../lib not .../lib64. Fix it.
cavium-dpdk_post_install = \
if [ "$(arch_lib_dir)" != "lib" ] ; then \
mkdir -p $(PACKAGE_INSTALL_DIR)/$(arch_lib_dir) ; \
cd $(PACKAGE_INSTALL_DIR)/lib ; \
tar cf - . | ( cd $(PACKAGE_INSTALL_DIR)/$(arch_lib_dir); tar xf - ) ; \
fi
# nothing to install, all static libraries
cavium-dpdk_image_include = echo

View File

@ -0,0 +1,24 @@
DPDK_MARCH = $(strip $($(PLATFORM)_dpdk_arch))
ifeq ($(DPDK_MARCH),)
DPDK_MARCH="native"
endif
ifneq (,$(findstring debug,$(TAG)))
DPDK_DEBUG=y
else
DPDK_DEBUG=n
endif
DPDK_MAKE_ARGS = -C $(call find_source_fn,$(PACKAGE_SOURCE)) \
DPDK_BUILD_DIR=$(PACKAGE_BUILD_DIR) \
DPDK_INSTALL_DIR=$(PACKAGE_INSTALL_DIR) \
DPDK_MARCH=$(DPDK_MARCH) \
DPDK_DEBUG=$(DPDK_DEBUG)
dpdk_configure = echo
dpdk_make_args = $(DPDK_MAKE_ARGS) config
dpdk_install = make $(DPDK_MAKE_ARGS) build

View File

@ -1,45 +0,0 @@
# Copyright (c) 2015 Cisco and/or its affiliates.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at:
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
external_source = build
ifneq (,$(findstring debug,$(TAG)))
DPDK_DEBUG=y
else
DPDK_DEBUG=n
endif
DPDK_MAKE_ARGS = -C $(call find_source_fn,$(PACKAGE_SOURCE)) \
BUILD_DIR=$(PACKAGE_BUILD_DIR) \
INSTALL_DIR=$(PACKAGE_INSTALL_DIR) \
DPDK_DEBUG=$(DPDK_DEBUG)
DPDK_MLX5_PMD=$(strip $($(PLATFORM)_uses_dpdk_mlx5_pmd))
ifneq ($(DPDK_MLX5_PMD),)
DPDK_MAKE_ARGS += DPDK_MLX5_PMD=y
endif
DPDK_MLX4_PMD=$(strip $($(PLATFORM)_uses_dpdk_mlx4_pmd))
ifneq ($(DPDK_MLX4_PMD),)
DPDK_MAKE_ARGS += DPDK_MLX4_PMD=y
endif
ifeq ("$(V)","1")
DPDK_MAKE_ARGS += DPDK_VERBOSE=1
endif
external_configure = echo
external_build = echo
external_install = $(MAKE) $(DPDK_MAKE_ARGS) -C external ebuild-build ebuild-install

View File

@ -1 +0,0 @@
# empty file

View File

@ -0,0 +1,5 @@
g2_configure_depend = vppinfra-install
g2_CPPFLAGS = $(call installed_includes_fn, vppinfra)
g2_LDFLAGS = $(call installed_libs_fn, vppinfra)

View File

@ -1,22 +1,9 @@
# Copyright (c) 2015 Cisco and/or its affiliates.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at:
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
gmod_configure_depend = vpp-install
gmod_configure_depend = vppinfra-install svm-install
gmod_configure_args = --libdir=$(PACKAGE_INSTALL_DIR)/$(arch_lib_dir)/ganglia
gmod_CPPFLAGS = $(call installed_includes_fn, vpp)
gmod_CPPFLAGS = $(call installed_includes_fn, vppinfra svm)
gmod_CPPFLAGS += -I/usr/include/apr-1.0 -I/usr/include/apr-1 -I/usr/include
gmod_LDFLAGS = $(call installed_libs_fn, vpp)
gmod_LDFLAGS = $(call installed_libs_fn, vppinfra svm)
gmod_image_include = echo $(arch_lib_dir)/ganglia/libgmodvpp.so etc

View File

@ -1,35 +0,0 @@
# Copyright (c) 2017-2018 Cisco and/or its affiliates.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at:
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
libmemif_source = extras
libmemif_configure_subdir = libmemif
ifneq ($(shell which cmake3),)
CMAKE?=cmake3
else
CMAKE?=cmake
endif
libmemif_cmake_args ?=
libmemif_cmake_args += -DCMAKE_INSTALL_PREFIX:PATH=$(PACKAGE_INSTALL_DIR)
libmemif_cmake_args += -DCMAKE_C_FLAGS="$($(TAG)_TAG_CFLAGS)"
libmemif_cmake_args += -DCMAKE_SHARED_LINKER_FLAGS="$($(TAG)_TAG_LDFLAGS)"
libmemif_cmake_args += -DCMAKE_PREFIX_PATH:PATH="$(PACKAGE_INSTALL_DIR)/../vpp"
libmemif_configure = \
cd $(PACKAGE_BUILD_DIR) && \
$(CMAKE) -G Ninja $(libmemif_cmake_args) $(call find_source_fn,$(PACKAGE_SOURCE))$(PACKAGE_SUBDIR)
libmemif_build = $(CMAKE) --build $(PACKAGE_BUILD_DIR) -- $(MAKE_PARALLEL_FLAGS)
libmemif_install = $(CMAKE) --build $(PACKAGE_BUILD_DIR) -- install

View File

@ -0,0 +1,5 @@
perftool_configure_depend = vppinfra-install
perftool_CPPFLAGS = $(call installed_includes_fn, vppinfra)
perftool_LDFLAGS = $(call installed_libs_fn, vppinfra)

View File

@ -1,40 +1,47 @@
# Copyright (c) 2015 Cisco and/or its affiliates.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at:
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
sample-plugin_configure_depend = \
vppinfra-install \
svm-install \
vlib-api-install \
vlib-install \
vnet-install \
vpp-install \
vpp-api-test-install
sample-plugin_source = src
sample-plugin_configure_subdir = examples/sample-plugin
sample-plugin_configure_depend = vpp-install
sample-plugin_CPPFLAGS = $(call installed_includes_fn, vpp)
sample-plugin_LDFLAGS = $(call installed_libs_fn, vpp)
sample-plugin_PATH = $(call package_install_dir_fn,vpp)/bin
sample-plugin_CPPFLAGS = $(call installed_includes_fn, \
vppinfra \
openssl \
svm \
vlib \
vlib-api \
vnet \
vpp \
vpp-api-test)
ifneq ($(shell which cmake3),)
CMAKE?=cmake3
sample-plugin_LDFLAGS = $(call installed_libs_fn, \
vppinfra \
openssl \
svm \
vlib \
vlib-api \
vnet \
vpp \
vpp-api-test)
sample-plugin_post_install = \
mkdir -p $(PACKAGE_INSTALL_DIR)/$(arch_lib_dir)/vlib_plugins ; \
cp $(PACKAGE_INSTALL_DIR)/$(arch_lib_dir)/*.so \
$(PACKAGE_INSTALL_DIR)/$(arch_lib_dir)/vlib_plugins
sample-plugin_image_include = echo $(arch_lib_dir)/vlib_plugins
ifneq ($($(PLATFORM)_uses_dpdk),no)
sample-plugin_configure_args = --with-dpdk
ifeq ($($(PLATFORM)_uses_external_dpdk),yes)
sample-plugin_CPPFLAGS += -I$($(PLATFORM)_dpdk_inc_dir)
sample-plugin_LDFLAGS += -L$($(PLATFORM)_dpdk_lib_dir)
else
CMAKE?=cmake
sample-plugin_configure_depend += dpdk-install
sample-plugin_CPPFLAGS += $(call installed_includes_fn, dpdk)
sample-plugin_LDFLAGS += $(call installed_libs_fn, dpdk)
endif
endif
sample-plugin_cmake_args ?=
sample-plugin_cmake_args += -DCMAKE_INSTALL_PREFIX:PATH=$(PACKAGE_INSTALL_DIR)
sample-plugin_cmake_args += -DCMAKE_C_FLAGS="$($(TAG)_TAG_CFLAGS)"
sample-plugin_cmake_args += -DCMAKE_SHARED_LINKER_FLAGS="$($(TAG)_TAG_LDFLAGS)"
sample-plugin_cmake_args += -DCMAKE_PREFIX_PATH:PATH="$(PACKAGE_INSTALL_DIR)/../vpp"
sample-plugin_configure = \
cd $(PACKAGE_BUILD_DIR) && \
$(CMAKE) -G Ninja $(sample-plugin_cmake_args) \
$(call find_source_fn,$(PACKAGE_SOURCE))$(PACKAGE_SUBDIR)
sample-plugin_build = $(CMAKE) --build $(PACKAGE_BUILD_DIR) -- $(MAKE_PARALLEL_FLAGS)
sample-plugin_install = $(CMAKE) --build $(PACKAGE_BUILD_DIR) -- install

View File

@ -1,12 +0,0 @@
# Copyright (c) 2015 Cisco and/or its affiliates.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at:
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

View File

@ -0,0 +1,5 @@
svm_top_srcdir = $(call find_source_fn,svm)
svm_configure_depend = vppinfra-install
svm_CPPFLAGS = $(call installed_includes_fn, vppinfra)
svm_LDFLAGS = $(call installed_libs_fn, vppinfra)

View File

@ -0,0 +1,6 @@
vlib-api-cavium-dpdk_source = vlib-api
vlib-api-cavium-dpdk_configure_depend = vppinfra-install svm-install vlib-cavium-dpdk-install
vlib-api-cavium-dpdk_CPPFLAGS = $(call installed_includes_fn, vppinfra svm vlib-cavium-dpdk)
vlib-api-cavium-dpdk_LDFLAGS = $(call installed_libs_fn, vppinfra svm vlib-cavium-dpdk)

View File

@ -0,0 +1,4 @@
vlib-api_configure_depend = vppinfra-install svm-install vlib-install
vlib-api_CPPFLAGS = $(call installed_includes_fn, vppinfra svm vlib)
vlib-api_LDFLAGS = $(call installed_libs_fn, vppinfra svm vlib)

View File

@ -0,0 +1,7 @@
vlib-cavium-dpdk_source = vlib
vlib-cavium-dpdk_configure_depend = vppinfra-install cavium-dpdk-install
vlib-cavium-dpdk_configure_args += --with-dpdk
vlib-cavium-dpdk_CPPFLAGS = $(call installed_includes_fn, vppinfra cavium-dpdk)
vlib-cavium-dpdk_LDFLAGS = $(call installed_libs_fn, vppinfra cavium-dpdk)

View File

@ -0,0 +1,16 @@
vlib_configure_depend = vppinfra-install
vlib_CPPFLAGS = $(call installed_includes_fn, vppinfra)
vlib_LDFLAGS = $(call installed_libs_fn, vppinfra)
ifneq ($($(PLATFORM)_uses_dpdk),no)
vlib_configure_args += --with-dpdk
ifeq ($($(PLATFORM)_uses_external_dpdk),yes)
vlib_CPPFLAGS += -I$($(PLATFORM)_dpdk_inc_dir)
vlib_LDFLAGS += -L$($(PLATFORM)_dpdk_lib_dir)
else
vlib_configure_depend += dpdk-install
vlib_CPPFLAGS += $(call installed_includes_fn, dpdk)
vlib_LDFLAGS += $(call installed_libs_fn, dpdk)
endif
endif

View File

@ -0,0 +1,29 @@
vnet-cavium-dpdk_source = vnet
vnet-cavium-dpdk_configure_depend = \
vppinfra-install \
cavium-dpdk-install \
svm-install \
vlib-api-cavium-dpdk-install \
vlib-cavium-dpdk-install
vnet-cavium-dpdk_CPPFLAGS = $(call installed_includes_fn, \
vppinfra \
cavium-dpdk \
openssl \
svm \
vlib-cavium-dpdk \
vlib-api-cavium-dpdk)
vnet-cavium-dpdk_LDFLAGS = $(call installed_libs_fn, \
vppinfra \
cavium-dpdk \
openssl \
svm \
vlib-cavium-dpdk \
vlib-api-cavium-dpdk)
# Platform dependent configure flags
vnet-cavium-dpdk_configure_args += $(vnet-cavium-dpdk_configure_args_$(PLATFORM))

View File

@ -0,0 +1,41 @@
vnet_configure_depend = \
vppinfra-install \
svm-install \
vlib-api-install \
vlib-install
vnet_CPPFLAGS = $(call installed_includes_fn, \
vppinfra \
svm \
vlib \
vlib-api)
vnet_LDFLAGS = $(call installed_libs_fn, \
vppinfra \
svm \
vlib \
vlib-api)
ifeq ($($(PLATFORM)_enable_tests),yes)
vnet_configure_args += --enable-tests
endif
# Platform dependent configure flags
vnet_configure_args += $(vnet_configure_args_$(PLATFORM))
# include & link with openssl only if needed
ifneq ($($(PLATFORM)_uses_openssl),no)
vnet_CPPFLAGS += $(call installed_includes_fn, openssl)
vnet_LDFLAGS += $(call installed_libs_fn, openssl)
endif
ifneq ($($(PLATFORM)_uses_dpdk),no)
ifeq ($($(PLATFORM)_uses_external_dpdk),yes)
vnet_CPPFLAGS += -I$($(PLATFORM)_dpdk_inc_dir)
vnet_LDFLAGS += -L$($(PLATFORM)_dpdk_lib_dir)
else
vnet_configure_depend += dpdk-install
vnet_CPPFLAGS += $(call installed_includes_fn, dpdk)
vnet_LDFLAGS += $(call installed_libs_fn, dpdk)
endif
endif

View File

@ -0,0 +1,32 @@
vpp-api-test-cavium-dpdk_source = vpp-api-test
vpp-api-test-cavium-dpdk_configure_depend = \
vppinfra-install \
cavium-dpdk-install \
svm-install \
vlib-api-cavium-dpdk-install \
vlib-cavium-dpdk-install \
vnet-cavium-dpdk-install \
vpp-cavium-dpdk-install
#
vpp-api-test-cavium-dpdk_configure_args = --with-dpdk
vpp-api-test-cavium-dpdk_CPPFLAGS = $(call installed_includes_fn, \
vppinfra \
cavium-dpdk \
svm \
vlib-cavium-dpdk \
vlib-api-cavium-dpdk \
vnet-cavium-dpdk \
vpp-cavium-dpdk)
vpp-api-test-cavium-dpdk_LDFLAGS = $(call installed_libs_fn, \
vppinfra \
cavium-dpdk \
svm \
vlib-cavium-dpdk \
vlib-api-cavium-dpdk \
vnet-cavium-dpdk \
vpp-cavium-dpdk)

View File

@ -0,0 +1,35 @@
vpp-api-test_configure_depend = \
vppinfra-install \
svm-install \
vlib-api-install \
vlib-install \
vnet-install \
vpp-install
vpp-api-test_CPPFLAGS = $(call installed_includes_fn, \
vppinfra \
svm \
vlib \
vlib-api \
vnet \
vpp)
vpp-api-test_LDFLAGS = $(call installed_libs_fn, \
vppinfra \
svm \
vlib \
vlib-api \
vnet \
vpp)
ifneq ($($(PLATFORM)_uses_dpdk),no)
vpp-api-test_configure_args = --with-dpdk
ifeq ($($(PLATFORM)_uses_external_dpdk),yes)
vpp-api-test_CPPFLAGS += -I$($(PLATFORM)_dpdk_inc_dir)
vpp-api-test_LDFLAGS += -L$($(PLATFORM)_dpdk_lib_dir)
else
vpp-api-test_configure_depend += dpdk-install
vpp-api-test_CPPFLAGS += $(call installed_includes_fn, dpdk)
vpp-api-test_LDFLAGS += $(call installed_libs_fn, dpdk)
endif
endif

Some files were not shown because too many files have changed in this diff Show More