summaryrefslogtreecommitdiffstats
path: root/vppapigen
AgeCommit message (Collapse)AuthorFilesLines
2016-12-28Reorganize source tree to use single autotools instanceDamjan Marion7-2875/+0
Change-Id: I7b51f88292e057c6443b12224486f2d0c9f8ae23 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-12-02API: Packaging of JSON files.Ole Troan2-292/+1
Change-Id: If041b6faf1a091d4758b514f0a8cd800ee0e6a89 Signed-off-by: Ole Troan <ot@cisco.com> Signed-off-by: Ole Troan <otroan@ot-vpp.cisco.com> Signed-off-by: Ole Troan <ot@cisco.com>
2016-11-23Fix coverity warnings, VPP-486Dave Barach1-0/+1
Change-Id: Id88805f77642187f304f8baef1f6b447728e4b5b Signed-off-by: Dave Barach <dave@barachs.net>
2016-11-21Add client-side msg_name_and_crc -> msg_index tableDave Barach4-37/+219
vppapigen now generates per-message crcs. Verified that whitespace and real changes in message A don't change the crc for message B, etc. Fixed the sample and flowperpkt plugins to participate. Others need the same treatment. They don't build due to python/java language binding build issues. To use the scheme: Client connects as usual. Then call: u32 vl_api_get_msg_index(char * name_and_crc) name_and_crc is a string like: "flowperpkt_tx_interface_add_del_753301f3", aka the message name with _%08x <expected crc> appended. Try these vpp-api-test commands to play with it: vat# dump_msg_api_table <snip> [366]: punt_reply_cca27fbe [367]: ipsec_spd_dump_5e9ae88e [368]: ipsec_spd_details_6f7821b0 [369]: sample_macswap_enable_disable_0f2813e2 [370]: sample_macswap_enable_disable_reply_476738e5 [371]: flowperpkt_tx_interface_add_del_753301f3 [372]: flowperpkt_tx_interface_add_del_reply_d47e6e0b vat# get_msg_id sample_macswap_enable_disable_reply_476738e5 'sample_macswap_enable_disable_reply_476738e5' has message index 370 vat# get_msg_id sample_macswap_enable_disable_reply_476738e3 'sample_macswap_enable_disable_reply_476738e3' not found CRCs may vary, etc. vppapigen is used to build a set of JSON representations of each API file from vpp-api/Makefile.am and that is in turn used by each language binding (Java, Python, Lua). Change-Id: I3d64582e779dac5f20cddec79c562c288d8fd9c6 Signed-off-by: Dave Barach <dave@barachs.net> Signed-off-by: Ole Troan <ot@cisco.com>
2016-11-15Dump routes (VPP-500)Steven1-0/+2
Change-Id: I86e7382395a8b6471a0deaf57163718d41b71b83 Signed-off-by: Steven <sluong@cisco.com>
2016-10-26python api - vla - allow the user to pass in a normal python listGabriel Ganne1-2/+11
Only add support for named variable-length-arrays as some api fo not follow the expected order of length preceding the value. Change-Id: I4c22c9b3c05f23edb3edc1cbc445be87b0a69162 Signed-off-by: Gabriel Ganne <gabriel.ganne@qosmos.com>
2016-10-12VPP-362 Implement dumping of LISP adjacenciesFilip Tehlar1-0/+2
Change-Id: Ieea56f3bf9e749878d9f2b35d39d9f7a9cdabde4 Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
2016-09-30VPP-120: include custom types to Python representation of vpe.apiMarek Gradzki2-20/+42
Change-Id: Ide97a8bf55d3baf41a1e86af2c67c6b7b26b657a Signed-off-by: Marek Gradzki <mgradzki@cisco.com>
2016-09-21vpp python api - fix vla pack generationGabriel Ganne1-20/+15
This fixes commit 1732fc1ab851c454a74efda47a383f48691d545a. Change-Id: I3d9f1384c20d2ca22eaf2aae553455789b934b6e Signed-off-by: Gabriel Ganne <gabriel.ganne@qosmos.com>
2016-09-13Python API: Re-adding rudimentary variable length array pack support.Ole Troan1-7/+19
Fixed bug in message-id mapping with non-consequtive APIs. Change-Id: Icd6073e4655f7ce5432816861ae58915e5b336af Signed-off-by: Ole Troan <ot@cisco.com>
2016-08-25VPP Python language binding - plugin supportOle Troan4-2/+283
- Moved Python generator tool to tools directory - Added build-vpp-api Makefile target - Generator now only creates a Python representation of the .api the rest of the framework is in the vpp_papi script - Each plugin has its own namespace. - Plugin Python files are installed in vpp_papi_plugins for easy use inside the build tree. Change-Id: I272c83bb7e5d5e416bdbd8a790a3cc35c5a04e38 Signed-off-by: Ole Troan <ot@cisco.com>
2016-08-05vpp-189 Clean up more coverity warningsDave Barach2-28/+31
Time to make the donuts Change-Id: I528937800f7daefce19723dda0216e58d857942c Signed-off-by: Dave Barach <dave@barachs.net>
2016-07-22VPP-189 Fix 137 coverity no-op issues from vpeapigenChris Luke1-2/+12
vpeapigen is not properly detecting no-op endian swap operations (on u8 or u8[] types) which in turn causes Coverity to currently report ~137 minor issues from the generated vpe.api.h file. This patch makes vpeapigen comment out those no-op situations thus: /* a->interface_name[0..63] = a->interface_name[0..63] (no-op) */ /* a->admin_up_down = a->admin_up_down (no-op) */ Change-Id: Ifbc5c93e1939206656e0515b528a4d167c539fd2 Signed-off-by: Chris Luke <chrisy@flirble.org>
2016-07-21VPP-123: remove japi (the old Java API)Marek Gradzki4-837/+10
MANUAL_JAVA flag (used only by the japi) was also removed. Change-Id: Ied21521b2410af1c357afb04cbf9e849632ddc5f Signed-off-by: Marek Gradzki <mgradzki@cisco.com>
2016-07-08Remove unnecessary and obsolete configure.ac directivesDamjan Marion1-1/+1
Also enable silent rules where missing Change-Id: Ia521886815c862b013f01df4cc18fd8a298aaaa1 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-06-27More janitorial workDave Barach1-5/+5
Install vpp api header files in /usr/include/vpp-api, instead of /usr/include/api. Someone will eventually complain if we continue with the status quo. Generate /usr/bin/vpp_plugin_configure, to correctly configure standalone plugin compilation against header files installed from the dev package. If a plugin's CFLAGS don't precisely match the installed vpp engine binary, subtle misbehavior can and will occur. Example: the ip4/ip6 main_t structure size / member offsets depend on DPDK=[0|1]. Screw that one up, and your brand-new configurable ip feature will mysteriously fail to appear, even though the plugin loads perfectly. Change-Id: I20c97fe1042808a79935863209d995c31953b98c Signed-off-by: Dave Barach <dave@barachs.net>
2016-06-24VPP-118: add support for variable length arrays to jvppMarek Gradzki3-2/+24
* extends VPP's message definition language with the following syntax: u32 count: u8 array[count]; which is traslated to: u32 count; u8 array[0]; but now, python API representation generated by vppapigen contains information about where the array length is stored. * modifies existing response messages to use the new syntax Change-Id: I68210bc7a3a755d03d067e9b79a567f40e2d31f3 Signed-off-by: Marek Gradzki <mgradzki@cisco.com>
2016-04-21Fix warning in vppapigenDamjan Marion1-1/+1
Change-Id: I6301ece0d772fd5a6271edd07765b05ef0b63f21 Signed-off-by: Damjan Marion <damarion@cisco.com>
2016-04-20Python-API: Inital commit of Python bindings for the VPP API.Ole Troan3-4/+89
See: https://wiki.fd.io/view/VPP/Python_API Change-Id: If135fc32208c7031787e1935b399d930e0e1ea1f Signed-off-by: Ole Troan <ot@cisco.com>
2016-04-18Add support for AArch32Christophe Fontaine1-2/+2
gcc version 4.9.2 (Raspbian 4.9.2-10) Tested on Linux raspberrypi 4.4.6-v7+ #875 SMP Tue Apr 12 16:33:02 BST 2016 armv7l GNU/Linux CPUs may be little or big endian, detect with gcc flags, not the processor architecture Add a new flag $(PLATFORM)_uses_openssl which allows to disable the link with openssl lib. vlib/vlib/threads.c: startup.conf must: - specify the heapsize as we don't have hugepages on raspbian cpu { main-core 3 } heapsize 64M Corrects in various files the assumption uword == u64 and replaces 'u64' cast with 'pointer_to_uword' and 'uword_to_pointer' where appropriate. 256 CPUs may create an OOM when testing with small memory footprint ( heapsize 64M ), allows the number of VLIB_MAX_CPUS to be set in platforms/*.mk vppinfra/vppinfra/longjmp.S: ARM - copy r1 (1st parameter of the setjmp call) to r0 (return value) vppinfra/vppinfra/time.h: On ARMv7 in AArch32 mode, we can access to a 64bit register to retreive the cycles count. gcc on rpi only declare ARM_ARCH 6. Override this info, and check if it is possible to use 'mrrc'. /!\ the time function will NOT work without allowing the user mode access to the PMU. You may download the source of the kmod here: https://github.com/christophefontaine/arm_rdtsc Change-Id: I8142606436d9671a184133b935398427f08a8bd2 Signed-off-by: Christophe Fontaine <christophe.fontaine@qosmos.com>
2016-03-14lex - yylval undeclaredVincent JARDIN1-0/+1
Fix compilation with Ubuntu 16.04/yacc: $ yacc -V yacc - 1.9 20140715 $ lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu Xenial Xerus (development branch) Release: 16.04 Codename: xenial Change-Id: Ib1a6d7b7f9485db893465041ac6bce2a98ded2f7 Signed-off-by: Vincent JARDIN <vincent.jardin@6wind.com>
2016-02-01Refactor vpp-japiRobert Varga1-46/+72
vlib does not allow concurrent connections, hence make sure the Java API does not allow the user to instantiate them. Also hide native methods from direct user invocation behind defensive methods also detect if a particular connection has been terminated. Disconnect is hidden befind standard close() method, as specified by AutoCloseable. Change-Id: Ib5079200ae4216cad84358a2174a41e90271a30b Signed-off-by: Robert Varga <nite@hq.sk>
2015-12-23ylwrap is also autotools autogenerated fileDamjan Marion1-247/+0
Change-Id: Ia6f26b5a12c2fb7847f9325519a99cf928263374 Signed-off-by: Damjan Marion <damarion@cisco.com>
2015-12-15Remove autotools generated productsDave Barach7-8613/+0
Change-Id: I7f23b8b8e5136cb56768bac3a7473e6df5ee4993 Signed-off-by: Dave Barach <dave@barachs.net>
2015-12-08Initial commit of vpp code.v1.0.0Ed Warnicke15-0/+12200
Change-Id: Ib246f1fbfce93274020ee93ce461e3d8bd8b9f17 Signed-off-by: Ed Warnicke <eaw@cisco.com>