vpp.git
2 months agoip: fix warning on interface ipv6 prefix remove 39/40439/2
Vladislav Grishenko [Sun, 15 May 2022 20:58:53 +0000 (01:58 +0500)]
ip: fix warning on interface ipv6 prefix remove

Type: fix
Signed-off-by: Vladislav Grishenko <themiron@yandex-team.ru>
Change-Id: I428f52abbdddd9caca9b0f619a0e934f96ac0b4a

2 months agofib: fix crash while adding intf-rx routes 49/40449/2
Vladislav Grishenko [Tue, 20 Feb 2024 06:58:01 +0000 (11:58 +0500)]
fib: fix crash while adding intf-rx routes

Fix crash while adding intf-rx ip4 and ip6 routes via api due
invalid exporting of interface rx routes as attached.
Also, add missed route path via rx-ip6 cli support.

Type: fix
Signed-off-by: Vladislav Grishenko <themiron@yandex-team.ru>
Change-Id: I15711c8c0787398dd7e3baa4787019bb1f317666

2 months agosvm: fix svm queue overwrite while adding 2 elements 44/40444/2
Vladislav Grishenko [Sat, 13 Mar 2021 15:48:35 +0000 (20:48 +0500)]
svm: fix svm queue overwrite while adding 2 elements

Adding two elements to the full svm queue passes exact
bounds check, therefore tail gets overwritten w/o any
waiting. Fix it with requiring at lease two free slots.

Type: fix
Signed-off-by: Vladislav Grishenko <themiron@yandex-team.ru>
Change-Id: I704ee606c47b523952cb965f848339ae1988cb60

2 months agoudp: fix ipv6 udp punt show 14/40414/1
Samvel Vartapetov [Tue, 28 Dec 2021 07:51:36 +0000 (10:51 +0300)]
udp: fix ipv6 udp punt show

Type: fix
Signed-off-by: Samvel Vartapetov <svartapetov@yandex-team.ru>
Signed-off-by: Vladislav Grishenko <themiron@yandex-team.ru>
Change-Id: I57cba1e724f851419c7dfdee896568fc7416feaf

2 months agosession: add api cb for listen and unlisten 11/40411/2
Florin Coras [Fri, 1 Mar 2024 02:19:30 +0000 (18:19 -0800)]
session: add api cb for listen and unlisten

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I28ccebf4d2f0728dd174ab3ee77a0d7ad4b90951

2 months agocrypto-native: fix AES-CBC encrypt loop 97/40397/2
Damjan Marion [Mon, 26 Feb 2024 16:19:56 +0000 (16:19 +0000)]
crypto-native: fix AES-CBC encrypt loop

Type: fix
Change-Id: I11cc52ff3867277e6591efb061f96cadfcc70c88
Signed-off-by: Damjan Marion <damarion@cisco.com>
2 months agodhcp: Compare DIUD_LL as a network short 87/40387/2
Tom Jones [Wed, 31 Jan 2024 09:13:44 +0000 (09:13 +0000)]
dhcp: Compare DIUD_LL as a network short

The existing comparision triggers the following clang assertion:

    error: result of comparison of constant 50331648 with expression of type
    'u16' (aka 'unsigned short') is always true

Section 9.1 of RFC3315 describes the DUID type field as:
    "A DUID consists of a two-octet type code represented in network byte"

correctly convert the local type to a network short for the comparison.

Type: fix
Change-Id: I7cb048035bd5e06372e29471ae6004ee1b2191b9
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agoocteon: add flow offload infra 76/40376/3
Monendra Singh Kushwaha [Wed, 14 Feb 2024 10:48:24 +0000 (16:18 +0530)]
octeon: add flow offload infra

Type: feature

Change-Id: I3485e1627eafc5125255985003573247e7562db2
Signed-off-by: Kommula Shiva Shankar <kshankar@marvell.com>
Signed-off-by: Monendra Singh Kushwaha <kmonendra@marvell.com>
2 months agocrypto: CLI to change dispatch mode 74/40374/5
Niyaz Murshed [Wed, 21 Feb 2024 19:54:24 +0000 (19:54 +0000)]
crypto: CLI to change dispatch mode

This change aims to affect crypto_sw_scheduler behavior,
but all the edits end up in vnet/crypto.

After 9a9604b introduced adaptive mode for crypto dispatch,
the performance of async mode at lower rate got worse.

A work around for CSIT test is done by changing dispatch mode via explicit API call
in https://github.com/FDio/vpp/commit/139aba204780f6cc2845b311820a0b4c47517d02

In this change, the CLI is brought back to allow user to fix the
dispatch mode.

set crypto async dispatch mode <polling|interrupt|adaptive>

Type: improvement
Change-Id: I029e98aa25889eddcf62e75a6c78926cdee862ef
Signed-off-by: Niyaz Murshed <niyaz.murshed@arm.com>
2 months agotls: pass reset ntf to engines 99/40399/3
Florin Coras [Tue, 27 Feb 2024 02:11:43 +0000 (18:11 -0800)]
tls: pass reset ntf to engines

Type: improvement

Change-Id: Ie042605e50656229874b7a93638f0f04c894410f
Signed-off-by: Florin Coras <fcoras@cisco.com>
2 months agosession: fix transport closed and disconnect race 98/40398/2
Florin Coras [Mon, 26 Feb 2024 22:52:34 +0000 (14:52 -0800)]
session: fix transport closed and disconnect race

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ie7ff4bac22e9dbb449610072b52d1ec4e46fe757

2 months agodev: add per-port vnet flow 75/40375/3
Monendra Singh Kushwaha [Tue, 6 Feb 2024 08:32:43 +0000 (14:02 +0530)]
dev: add per-port vnet flow

Type: feature

Change-Id: If63f39211288ab2eba8bc1ab50a2a4c7755abc66
Signed-off-by: Monendra Singh Kushwaha <kmonendra@marvell.com>
2 months agotcp: fix fin retransmit when out of buffers 96/40396/3
Florin Coras [Mon, 26 Feb 2024 01:35:21 +0000 (17:35 -0800)]
tcp: fix fin retransmit when out of buffers

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I787825dea7f82748537cc4372104cc6647cf2132

2 months agohsa: Undef libepoll-shims close on FreeBSD 88/40388/4
Tom Jones [Wed, 31 Jan 2024 09:33:16 +0000 (09:33 +0000)]
hsa: Undef libepoll-shims close on FreeBSD

libepoll-shim has some hacks to enable functionality, one of these
redefines close as a macro. This conflicts with a close call back. On
FreeBSD undefine this macro at point of use.

Type: improvement
Change-Id: I7b4f7cd874f3451d76c580cf999369426d9e89c2
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agovirtio: fix the packed ring support 90/39990/2
Mohsin Kazmi [Fri, 16 Feb 2024 17:30:41 +0000 (17:30 +0000)]
virtio: fix the packed ring support

Type: fix

Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Change-Id: If27702d2a9755e0e0a6eaeab4cf26b4974444b44

2 months agomemif: don't include prctl.h 84/40384/3
Tom Jones [Tue, 30 Jan 2024 16:43:12 +0000 (16:43 +0000)]
memif: don't include prctl.h

Type: improvement
Change-Id: I3ab8df625524b5ff85e62760f5e29daf0d650773
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agotls: initialize app session app wrk 95/40395/1
Florin Coras [Sat, 24 Feb 2024 02:01:45 +0000 (18:01 -0800)]
tls: initialize app session app wrk

Type: fix

Change-Id: I8832839738b96495bd775a778dd736bb25e1236c
Signed-off-by: Florin Coras <fcoras@cisco.com>
2 months agosvm: Use ftruncate to expand svm on FreeBSD 91/40391/2
Tom Jones [Wed, 31 Jan 2024 10:44:14 +0000 (10:44 +0000)]
svm: Use ftruncate to expand svm on FreeBSD

Linux doesn't support the Linux idiom of using lseek and a write to set
the size of a file, instead use ftruncate to accomplish the same effect.

This change is taken from the Nanoteq VPP port commit:
https://github.com/ftk-ntq/vpp/commit/04a1b19b37e791accc61b91f3f413d8bc8b1ff8f

Type: improvement
Change-Id: Ie0b83e751b8b8f20b6814e5c9f760035747dfad9
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agovcl: Use FreeBSD specific errno value for bad fd 82/40382/1
Tom Jones [Tue, 30 Jan 2024 16:21:58 +0000 (16:21 +0000)]
vcl: Use FreeBSD specific errno value for bad fd

Type: improvement
Change-Id: I7693f2647f65f662c9b20f77bbf7e1a530b58259
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agobuild: Discover libepoll-shim on FreeBSD 42/40342/4
Tom Jones [Mon, 29 Jan 2024 14:38:19 +0000 (14:38 +0000)]
build: Discover libepoll-shim on FreeBSD

FreeBSD doesn't offer epoll, but an implementation which uses kqueue is
available as an external library. On FreeBSD in subsystems which require
epoll have cmake look for libepoll-shim.

Type: improvement
Change-Id: Iafd5406a9e2ebaa53fd94034489ffbbf87a7d040
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agovlib: Use platform specific headers for sched.h 52/40252/7
Tom Jones [Thu, 25 Jan 2024 10:24:08 +0000 (10:24 +0000)]
vlib: Use platform specific headers for sched.h

FreeBSD only defines posix scheduling policies, remove the others from
the for each look to allow build.

Type: improvement
Change-Id: Ifdb9414417e8b6ffdf216fd001708b347c496b97
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agobuild: Add support to add_vpp_library for platform specific sources 40/40340/3
Tom Jones [Mon, 29 Jan 2024 10:33:36 +0000 (10:33 +0000)]
build: Add support to add_vpp_library for platform specific sources

Add support for adding Linux and FreeBSD specific sources to
add_vpp_library and support for installing Linux specific headers. Don't
add support for FreeBSD specific headers until we have some to install.

Type: improvement
Change-Id: I38549cf4d71999b71b3298e529323956e54ddc36
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agoip6: ECMP hash support for ipv6 fragments 09/39309/5
Benoît Ganne [Wed, 2 Aug 2023 09:31:46 +0000 (11:31 +0200)]
ip6: ECMP hash support for ipv6 fragments

Type: improvement

Change-Id: I41f70e5977fedbf0050205ebe52126ef373ebc06
Signed-off-by: Benoît Ganne <bganne@cisco.com>
2 months agotls: fix transport endpoint get 70/40370/3
Florin Coras [Tue, 20 Feb 2024 19:24:54 +0000 (11:24 -0800)]
tls: fix transport endpoint get

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Idb8cc576168ce0ffa8f06be1acef4be4b3b29433

2 months agopg: fix stream pg interface 64/40364/4
Maxime Peim [Mon, 19 Feb 2024 10:26:23 +0000 (11:26 +0100)]
pg: fix stream pg interface

When an other interface is specified to generate packets from, we should
bind its sw_if_index to the pg interface to use.
Fix if_index_by_sw_if_index variable name, and force to specify a pg
interface to source traffic from.

Type: fix
Change-Id: Ib3e6dca92774b307def82926fc09945b7998267d
Signed-off-by: Maxime Peim <mpeim@cisco.com>
2 months agobuild: Enable building on AlmaLinux 9 29/39629/6
Kaj Niemi [Mon, 9 Oct 2023 13:14:51 +0000 (13:14 +0000)]
build: Enable building on AlmaLinux 9

AlmaLinux is identical to Rocky and can be made to work with
the same build dependencies

Type: feature

Change-Id: I24bb8781a02c15f887c9c26cc98621e6256f4115
Signed-off-by: Kaj Niemi <kajtzu@a51.org>
2 months agovnet: include platform specific un.h 46/40346/4
Tom Jones [Mon, 29 Jan 2024 15:23:23 +0000 (15:23 +0000)]
vnet: include platform specific un.h

On FreeBSD define UNIX_PATH_MAX so it is available in punt.c. FreeBSD's
max path is 4 bytes shorter than Linux's.

Type: improvement
Change-Id: I2c4b7aa11246213575b557fab44669706885e6b7
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agovppinfra: Stub out get_current_cpu and get_current_numa on FreeBSD 62/40262/4
Tom Jones [Fri, 26 Jan 2024 13:48:49 +0000 (13:48 +0000)]
vppinfra: Stub out get_current_cpu and get_current_numa on FreeBSD

FreeBSD has its own set of syscalls for getting current CPU and NUMA
domain information. Stub out these calls and return CPU 0 and NUMA domain
0 as placeholders until we bring in FreeBSD specific calls.

Type: improvement
Change-Id: Id61df0273b0bcc6acf4844ee626e4f246f9f217b
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agodev: fix type for uint32 arg value 43/40343/2
Monendra Singh Kushwaha [Thu, 15 Feb 2024 17:37:39 +0000 (23:07 +0530)]
dev: fix type for uint32 arg value

Type: fix

Change-Id: Ib09d6a0dfc95d82ecfd2ff123be9004cb038d0d4
Signed-off-by: Monendra Singh Kushwaha <kmonendra@marvell.com>
2 months agobuild: bump octeon-roc version to 0.3 62/40362/2
Monendra Singh Kushwaha [Sun, 18 Feb 2024 18:03:41 +0000 (23:33 +0530)]
build: bump octeon-roc version to 0.3

This patch updates cache line size in octeon-roc library.

Type: fix

Signed-off-by: Monendra Singh Kushwaha <kmonendra@marvell.com>
Change-Id: Ifbb6e7d2a5436a88ef10d22c414112edc23e0b35

2 months agocrypto-openssl: refactor openssl API usage 47/40047/5
Lijian Zhang [Wed, 1 Nov 2023 07:17:31 +0000 (07:17 +0000)]
crypto-openssl: refactor openssl API usage

For the openssl crypto engine based cipher encrypt/decrypt and HMAC IPSec
use cases, the openssl API calls of doing ctx init and key expansion are
moved to initialization stage.

In current implementation , the ctx is initialized with "key" and "iv" in
EVP_EncryptInit_ex (ctx, 0, 0, key->data, op->iv)
in data plane, while the ctx can be initialized with 'key' and 'iv' separately,
which means there could be two API calls:
 1. EVP_EncryptInit_ex (ctx, 0, 0, key->data, 0)
 2. EVP_EncryptInit_ex (ctx, 0, 0, 0, op->iv)

As the 'key' for certain IPSec SA is fixed and known, so call #1 can
be placed in IPSec SA initialization stage.
While call #2 should be kept in data plane for each packet, as the "iv"
is random for each packet.

Type: feature
Signed-off-by: Lijian Zhang <Lijian.Zhang@arm.com>
Change-Id: Ided4462c1d4a38addc3078b03d618209e040a07a

2 months agowireguard: notify key changes to crypto engine 46/40046/3
Lijian Zhang [Wed, 8 Nov 2023 09:09:10 +0000 (09:09 +0000)]
wireguard: notify key changes to crypto engine

This is a prerequisite patch for the following openssl API optimization
patch, which tries to offload openssl ctx init and key expansion work to
the initialization stage.

Wireguard adds crypto keys via vnet_crypto_key_add (), and whenever it
modifies the keys, the underneath openssl crypto engine shoud be informed
of the changes to update the openssl ctx.

Type: feature
Signed-off-by: Lijian Zhang <Lijian.Zhang@arm.com>
Change-Id: I3e8f033f3f77eebcecfbd06e8e3bbbfdc95a50e2

2 months agoipsec: check each packet for no algs in esp-encrypt 36/40336/2
Matthew Smith [Mon, 12 Feb 2024 18:39:21 +0000 (18:39 +0000)]
ipsec: check each packet for no algs in esp-encrypt

In esp_encrypt_inline(), if two or more consecutive packets are
associated with the same SA which has no crypto or integrity algorithms
set, only the first one gets dropped. Subsequent packets either get sent
(synchronous crypto) or cause a segv (asynchronous crypto).

The current SA's index and pool entry are cached before it can be
determined whether the packet should be dropped due to no algorithms
being set. The check for no algorithms is only performed when the cached
SA index is different than the SA index for the current packet. So
packets after the first one associated with the "none" alg SA aren't
handled properly.

This was broken by my previous commit ("ipsec: keep esp encrypt pointer
and index synced") which fixed a segv that occurred under a different
set of circumstances.

Check whether each packet should be dropped instead of only checking
when a new SA is encountered.

Update unit tests:
- Add a test for no algs on tunnel interface which enables
  asynchronous crypto.
- Send more than one packet in the tests for no algs.

Type: fix
Fixes: dac9e566cd16fc375fff14280b37cb5135584fc6

Signed-off-by: Matthew Smith <mgsmith@netgate.com>
Change-Id: I69e951f22044051eb8557da187cb58f5535b54bf

2 months agoudp: use transport port refcnt on accept 59/40359/2
Florin Coras [Sat, 17 Feb 2024 19:45:25 +0000 (11:45 -0800)]
udp: use transport port refcnt on accept

Use udp transport refcnt instead of local port refcnt when accepting new
connections.

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ibc34677b1138682497f98e96b6fddb5b96094ff9

2 months agosvm: Only include sys/user on Linux 49/40349/2
Tom Jones [Tue, 30 Jan 2024 09:19:13 +0000 (09:19 +0000)]
svm: Only include sys/user on Linux

Type: improvement
Change-Id: Idb318eb386617013015c43153bf0bd92fa28b9b6
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agovnet: Add required header for pthread_np 51/40351/2
Tom Jones [Tue, 30 Jan 2024 09:26:42 +0000 (09:26 +0000)]
vnet: Add required header for pthread_np

Type: improvement
Change-Id: Ia9295b79340a18de6eb5fe80877dcf4ce97b35eb
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agovppinfra: Place hugepage MMAP call behind linux specific ifdef 45/40345/2
Tom Jones [Mon, 29 Jan 2024 15:16:27 +0000 (15:16 +0000)]
vppinfra: Place hugepage MMAP call behind linux specific ifdef

Type: improvement
Change-Id: I3a48ec4fd4a4063b6e3792b87def7bb796fc947c
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agovnet: Use platform specific netlink headers on FreeBSD 44/40344/2
Tom Jones [Mon, 29 Jan 2024 15:12:34 +0000 (15:12 +0000)]
vnet: Use platform specific netlink headers on FreeBSD

Type: improvement
Change-Id: Ifbd84a45edc82c79ac2850dd70ecdd2f9f1289ae
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agovnet: Disable tuntap build on not Linux 50/40350/2
Tom Jones [Tue, 30 Jan 2024 09:26:14 +0000 (09:26 +0000)]
vnet: Disable tuntap build on not Linux

tuntap requires porting on FreeBSD, only build on Linux for now.

Type: improvement
Change-Id: I448c462b31f3bc06f291a95d0ff5df9d6f8f24b8
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agovlib: Only init vfio on Linux 54/40354/2
Tom Jones [Tue, 30 Jan 2024 13:54:12 +0000 (13:54 +0000)]
vlib: Only init vfio on Linux

Type: improvement
Change-Id: Id1c72928324b85bc67860e600722bf8baeff45b2
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agovpp: Add required socket headers on FreeBSD 55/40355/2
Tom Jones [Tue, 30 Jan 2024 14:04:12 +0000 (14:04 +0000)]
vpp: Add required socket headers on FreeBSD

Type: improvement
Change-Id: I948e447082233187d9ca794ca56a62fad4592e13
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agovppinfra: Provide FreeBSD implementation of clib_mem functions 71/40271/4
Tom Jones [Fri, 26 Jan 2024 17:04:23 +0000 (17:04 +0000)]
vppinfra: Provide FreeBSD implementation of clib_mem functions

Working from the implementation in linux/mem.c add FreeBSD specific
functionality. This duplicates parts of the Linux implementation and a
depuplication job could be run in the future.

Stub out some parts of the API for now, they are either use unavailable
features on FreeBSD or require further implementation than this initial
implementation.

Type: improvement
Change-Id: I1e443e32304d19776a9a4d5e34adfa16ec919427
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agobuild: Add FreeBSD as a supported platform for cmake 48/40248/3
Tom Jones [Wed, 24 Jan 2024 10:50:14 +0000 (10:50 +0000)]
build: Add FreeBSD as a supported platform for cmake

Allow FreeBSD as a platform in the main CMakeLists file. This requires a
correct target for the compiler and an explicit name in the system
check.

The included subdirs require further changes to build, but the compiler
needs to find them before it can complain.

Type: improvement
Change-Id: Ic56fe68290519ef5d3ed61082e7fb0ba0528a3fc
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agovnet: Provide platform specific if_tap headers 47/40347/2
Tom Jones [Tue, 30 Jan 2024 09:06:47 +0000 (09:06 +0000)]
vnet: Provide platform specific if_tap headers

Type: improvement
Change-Id: Ia5cec0afc7f929491e495bb337493e64f752d75f
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agovnet: Only build tap on Linux 48/40348/2
Tom Jones [Tue, 30 Jan 2024 09:07:06 +0000 (09:07 +0000)]
vnet: Only build tap on Linux

tap requires some porting on FreeBSD, while we wait for those changes
only build tap on Linux.

Type: improvement
Change-Id: I4361bf43764fdb046c2138d4a2ee5d7efa31bd5a
Signed-off-by: Tom Jones <thj@freebsd.org>
2 months agovpp: Add platform specific headers for socket and inet 52/40352/2
Tom Jones [Tue, 30 Jan 2024 09:47:05 +0000 (09:47 +0000)]
vpp: Add platform specific headers for socket and inet

Type: improvement
Change-Id: Idcedc14089a49483d83c28a82ecb79d1b856f225
Signed-off-by: Tom Jones <thj@freebsd.org>
3 months agotcp: retransmit fins in last-ack 57/40357/2
Florin Coras [Sat, 17 Feb 2024 02:36:32 +0000 (18:36 -0800)]
tcp: retransmit fins in last-ack

Fix instances where timers are reset after programming fin.

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Ib80e3a401d585f388a97c7f2bb62e68ee774d50d

3 months agoudp: unregister ports on all cleanups 20/40320/2
Florin Coras [Wed, 7 Feb 2024 19:42:02 +0000 (11:42 -0800)]
udp: unregister ports on all cleanups

UDP transport port refcount is incremented even if port is shared. So
decrement it, by unregistering, whener udp connections are cleaned up.

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Id0a2c60c5faf4dea8b2cd9ded0334934ad9e918c

3 months agovppapitrace: Fixed trace dump API result issue. 32/40332/5
Denys Haryachyy [Wed, 7 Feb 2024 14:47:20 +0000 (16:47 +0200)]
vppapitrace: Fixed trace dump API result issue.

Set last thread id and last packet position in TRACE_DUMP_REPLY.
To enable collection of traces from multiple workers using iterator.

Type: fix

Change-Id: I69872af4f6981d50cd050fa3d16de2a3c0d6b496
Signed-off-by: Denys Haryachyy <garyachy@gmail.com>
3 months agohs-test: shortened interface names to avoid character limit 87/39987/4
adrianvillin [Tue, 13 Feb 2024 08:26:25 +0000 (03:26 -0500)]
hs-test: shortened interface names to avoid character limit

Type: test

Change-Id: I09df597ccb8a3c4af47b8a36010afb81df533236
Signed-off-by: adrianvillin <avillin@cisco.com>
3 months agotls: mark ho done atomically after ctx init 33/40333/3
Florin Coras [Tue, 13 Feb 2024 20:37:20 +0000 (15:37 -0500)]
tls: mark ho done atomically after ctx init

Make sure ctx is initialized before ho is marked as done.

Type: fix

Change-Id: If0525a9890a56e289e2ab006c669a9d64dc6505d
Signed-off-by: Florin Coras <fcoras@cisco.com>
3 months agosession: postpone ct cleanup if rx evt pending 37/40337/3
Florin Coras [Thu, 15 Feb 2024 00:14:46 +0000 (16:14 -0800)]
session: postpone ct cleanup if rx evt pending

Type: fix

Change-Id: I8cfaa62abd38d5356263b0ffd428638d1a027617
Signed-off-by: Florin Coras <fcoras@cisco.com>
3 months agobuild: add fib configuring option 22/40322/2
Benoît Ganne [Thu, 8 Feb 2024 16:06:22 +0000 (17:06 +0100)]
build: add fib configuring option

Allow to select 8-8-8-8 or 16-8-8 mtrie FIB implementation.

Type: improvement

Change-Id: I2f4aec8bfec987d3f3d9f9cc5a16fabf4b6cc2ac
Signed-off-by: Benoît Ganne <bganne@cisco.com>
3 months agohs-test: improved logging 86/39986/5
adrianvillin [Mon, 12 Feb 2024 07:44:53 +0000 (02:44 -0500)]
hs-test: improved logging

- improved readability of some error messages
- printing container logs to stdout on test failure (last 20 lines)

Type: test

Change-Id: Idbb358bdd89aa7b1a6bdc9d96bf029d4c299ce64
Signed-off-by: adrianvillin <avillin@cisco.com>
3 months agotests: refactor virtual interface tests 83/40283/5
Naveen Joy [Wed, 31 Jan 2024 16:46:18 +0000 (08:46 -0800)]
tests: refactor virtual interface tests

Split virtual interface tests in VPP into smaller and modular
tests for testing various interface types and features.

Type: test

Change-Id: Ic38af88379f75eee3090679d411edbdc8fd5d2e5
Signed-off-by: Naveen Joy <najoy@cisco.com>
3 months agotls: fix compilation error 35/40335/2
Niyaz Murshed [Wed, 14 Feb 2024 00:12:32 +0000 (00:12 +0000)]
tls: fix compilation error

After changes done in https://gerrit.fd.io/r/c/vpp/+/40281 ,
mbedtls plugin is failing to build if enabled.

Discussion https://lists.fd.io/g/vpp-dev/topic/104344802#24060

Type: fix
Signed-off-by: Niyaz Murshed <niyaz.murshed@arm.com>
Change-Id: Iee58b69301ac64f058bca0a7f7a0dedd2def4b35

3 months agoikev2: dump state and profile name in CLI and API 57/40257/11
Denys Haryachyy [Wed, 24 Jan 2024 14:31:47 +0000 (16:31 +0200)]
ikev2: dump state and profile name in CLI and API

Type: improvement

Change-Id: Ide4b45da99e3a67376281f6438997f3148be08e5
Signed-off-by: Denys Haryachyy <garyachy@gmail.com>
3 months agovcl: fix epollet test for unhandled evts 28/40328/3
Florin Coras [Tue, 13 Feb 2024 03:33:41 +0000 (22:33 -0500)]
vcl: fix epollet test for unhandled evts

Argument to vcl_epoll_ctl_add_unhandled_event is often the result of an
and between events and EPOLLET which is larger than u8

Type: fix

Change-Id: I8c98f557fa1db9f3eb79c90ecdd60ac9366d4d40
Signed-off-by: Florin Coras <fcoras@cisco.com>
3 months agosvm: Add FreeBSD specific signal handling path 74/40274/2
Tom Jones [Fri, 26 Jan 2024 17:44:33 +0000 (17:44 +0000)]
svm: Add FreeBSD specific signal handling path

FreeBSD's siginfo_t doesn't have the ptr value used on linux to encode a
token. Fow now recover the code from siginfo_t and leave the opaque
value as 0.

Type: improvement
Change-Id: Ic6ef96f018b326b99d68534a4488cfc49fdf16e1
Signed-off-by: Tom Jones <thj@freebsd.org>
3 months agovppinfra: Put clib_perf* behind Linux checks and provide stubs for FreeBSD 51/40251/3
Tom Jones [Thu, 25 Jan 2024 10:28:16 +0000 (10:28 +0000)]
vppinfra: Put clib_perf* behind Linux checks and provide stubs for FreeBSD

As a placeholder stub out clib_perf functions on FreeBSD, the interface
for performance counters on FreeBSD is different and will require its
own implementation.

Type: improvement
Change-Id: I61511ebe5ee1fd6fe93d3179c7843c811f47a846
Signed-off-by: Tom Jones <thj@freebsd.org>
3 months agovppinfra: Add netlink header on FreeBSD 66/40266/2
Tom Jones [Fri, 26 Jan 2024 14:58:18 +0000 (14:58 +0000)]
vppinfra: Add netlink header on FreeBSD

FreeBSD has support netlink since 13.2, but keeps its header in a
slightly different place. Correctly include netlink/netlink.h for
FreeBSD.

Type: improvement
Change-Id: Iec78ca72db74ea7f9c874e7039c7d17b6321f9dc
Signed-off-by: Tom Jones <thj@freebsd.org>
3 months agovppinfra: Protect Linux specific features behind CLIB_LINUX 65/40265/2
Tom Jones [Fri, 26 Jan 2024 14:54:57 +0000 (14:54 +0000)]
vppinfra: Protect Linux specific features behind CLIB_LINUX

Place Linux specific features behind CLIB_LINUX. The previous #ifdef
calls would still pass even if CLIB_LINUX is set to 0 in clib.h, instead
use #if.

Type: improvement
Change-Id: Ibe4424eee4bc0065f54764b017b9a56a3e854380
Signed-off-by: Tom Jones <thj@freebsd.org>
3 months agobuild: Limit external libraries on FreeBSD 47/40247/2
Tom Jones [Wed, 24 Jan 2024 10:46:44 +0000 (10:46 +0000)]
build: Limit external libraries on FreeBSD

Limit the libraries we build on FreeBSD. This change intends to get us
closer to building on FreeBSD, DPDK will require a larger set of changes
so remove it until those changes are ready to integrate.

Type: improvement
Change-Id: I0f672a2b5bc30f2228020049fa71a81a2569ef54
Signed-off-by: Tom Jones <thj@freebsd.org>
3 months agosvm: Include stdint on FreeBSD 72/40272/2
Tom Jones [Fri, 26 Jan 2024 17:32:02 +0000 (17:32 +0000)]
svm: Include stdint on FreeBSD

On FreeBSD we need to include stdint.h to get __WORDSIZE.

Type: improvement
Change-Id: I784aa0856fd8298f33016b7ccedecfa3672d5429
Signed-off-by: Tom Jones <thj@freebsd.org>
3 months agovppinfra: Make program counter printing more portable 68/40268/2
Tom Jones [Fri, 26 Jan 2024 15:16:57 +0000 (15:16 +0000)]
vppinfra: Make program counter printing more portable

Finding the program counter in the ucontext struct is platform and
architecture specific, place the Linux checks inside an #ifdef and add a
look up for the FreeBSD amd64 specific naming.

Type: improvement
Change-Id: I42fcef5f20227c23d84acee336e37c4870146bb4
Signed-off-by: Tom Jones <thj@freebsd.org>
3 months agovnet: Don't use __unused for struct padding 61/40261/2
Tom Jones [Fri, 26 Jan 2024 13:26:28 +0000 (13:26 +0000)]
vnet: Don't use __unused for struct padding

__unused is a clang keyword, this struct member will trip the build when
using clang. Instead call the unused padding 'pad' which should be clear
to the purpose if not the usage.

Type: improvement
Change-Id: I0abae34841651be1ef6b7d94864f0dc8185f0733
Signed-off-by: Tom Jones <thj@freebsd.org>
3 months agovppinfra: Add a stubbed out test_perf function for FreeBSD 69/40269/2
Tom Jones [Fri, 26 Jan 2024 15:20:02 +0000 (15:20 +0000)]
vppinfra: Add a stubbed out test_perf function for FreeBSD

Type: improvement
Change-Id: If136e0854dbaecfa62fc009ca2b0b94e8d9a56f2
Signed-off-by: Tom Jones <thj@freebsd.org>
3 months agovppinfra: MAP_HUGETLB isn't available on FreeBSD 64/40264/2
Tom Jones [Fri, 26 Jan 2024 14:15:54 +0000 (14:15 +0000)]
vppinfra: MAP_HUGETLB isn't available on FreeBSD

Don't use the MAP_HUGETLB mmap flag on FreeBSD as it isn't available on
the platform.

Type: improvement
Change-Id: Ie2046601c693f9ef12cf8113d6dbd87c322f1cf0
Signed-off-by: Tom Jones <thj@freebsd.org>
3 months agovppinfra: Only prealloc hugepages on Linux 73/40273/2
Tom Jones [Fri, 26 Jan 2024 17:34:51 +0000 (17:34 +0000)]
vppinfra: Only prealloc hugepages on Linux

FreeBSD doesn't support sysfs or preallocating hugepages directly.  In
lieu of refactoring clib_sysfs calls place this one behind an #ifdef
linux.

Type: improvement
Change-Id: I4079ca70175e4cec44d913db2b0407a3ca6306c9
Signed-off-by: Tom Jones <thj@freebsd.org>
3 months agovppinfra: Don't build perfmon on FreeBSD 63/40263/3
Tom Jones [Fri, 26 Jan 2024 14:13:39 +0000 (14:13 +0000)]
vppinfra: Don't build perfmon on FreeBSD

FreeBSD has platform specific APIs for interfacing with performance
counters. Until we bring in FreeBSD support, don't build perfmon on
platforms which aren't linux.

Type: improvement
Change-Id: Iabc418922c0d2e851c6098508761135f53433ae8
Signed-off-by: Tom Jones <thj@freebsd.org>
3 months agovppinfra: Place SIGPWR behind a linux define 67/40267/2
Tom Jones [Fri, 26 Jan 2024 15:00:31 +0000 (15:00 +0000)]
vppinfra: Place SIGPWR behind a linux define

The SIGPWR signal is specific to Linux, place it behind a Linux flag to
help the build on FreeBSD.

Type: improvement
Change-Id: Ie36c2ceb201afff98e92bbe64595c3953b11c457
Signed-off-by: Tom Jones <thj@freebsd.org>
3 months agofib: contention with DP on deleting a route 27/40327/1
Steven Luong [Tue, 13 Feb 2024 00:47:22 +0000 (16:47 -0800)]
fib: contention with DP on deleting a route

Add vlib_worker_wait_one_loop prior to invoking dpo_reset
upon uninstalling a fib entry to avoid contention with DP.

Type: fix

Change-Id: If2a6c4cb9b5629dd61e506ab9f9c3e6aef121b45
Signed-off-by: Steven Luong <sluong@cisco.com>
3 months agoaf_packet : fix crash on interface creation 50/40250/2
hsandid [Wed, 24 Jan 2024 12:58:03 +0000 (13:58 +0100)]
af_packet : fix crash on interface creation

Type: fix

Attempting to create a host-interface with an invalid af_packet name
causes a crash, as we attempt to read the contents of a null ptr.

Change-Id: Ia31ae21684c2b66baa1ceaadf29e19fae33c4ed4
Signed-off-by: hsandid <halsandi@cisco.com>
3 months agobuffers: bring back cache occupancy improvement 91/40291/3
Vratko Polak [Tue, 6 Feb 2024 11:45:59 +0000 (12:45 +0100)]
buffers: bring back cache occupancy improvement

The improvement was removed in 40129,
causing 5-40% regressions in AVF tests.

There is a memory-speed trade-off,
this change prefers speed over memory efficiency.

Ideally, the choice should be configurable,
but that is not easy to achieve, considering
how early is vlib_buffer_main_init called.

Type: fix
Fixes: 038dad7ef29b0b724071edb5f8cc7a9845584454

Change-Id: I4746f3634abe6d233c9d092a372de05b3d1ae4b6
Signed-off-by: Vratko Polak <vrpolak@cisco.com>
3 months agoip_session_redirect: export symbols 21/40321/2
Benoît Ganne [Thu, 8 Feb 2024 16:08:28 +0000 (17:08 +0100)]
ip_session_redirect: export symbols

Add/del functions can be used from external modules.

Type: improvement

Change-Id: I267bcfacd58970bcacae13744d8acc690b87d2fc
Signed-off-by: Benoît Ganne <bganne@cisco.com>
3 months agoikev2: accept rekey request for IKE SA 35/36935/3
Atzm Watanabe [Thu, 18 Aug 2022 08:57:53 +0000 (17:57 +0900)]
ikev2: accept rekey request for IKE SA

RFC 7296 describes the way to rekey IKE SAs: to rekey an IKE SA,
establish a new equivalent IKE SA with the peer to whom the old
IKE SA is shared using a CREATE_CHILD_SA within the existing IKE
SA.  An IKE SA so created inherits all of the original IKE SA's
Child SAs, and the new IKE SA is used for all control messages
needed to maintain those Child SAs.

Type: improvement
Signed-off-by: Atzm Watanabe <atzmism@gmail.com>
Change-Id: Icdf43b67c38bf183913a28a08a85236ba16343af

3 months agoudp: add cli to dump transport ports 95/40295/2
Florin Coras [Wed, 7 Feb 2024 00:31:50 +0000 (16:31 -0800)]
udp: add cli to dump transport ports

show udp transport ports

Dumps list of ports registered by udp transport, as opposed to udp
local, and their refcount.

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: If3cbe51a7176cb89fa38b524defffbbd76af8f58

3 months agosession: guard session lookup table allocs 86/40286/2
Florin Coras [Fri, 2 Feb 2024 21:01:07 +0000 (13:01 -0800)]
session: guard session lookup table allocs

Session lookup tables could be allocated from workers, e.g., connects
are done from first worker. Make sure consumers are not affected by
stopping workers.

Type: fix

Change-Id: I63b53c58b41ce91b08f50a2325c69c9f9fd25ed3
Signed-off-by: Florin Coras <fcoras@cisco.com>
3 months agovlib: flush rpcs on worker sync 85/40285/2
Florin Coras [Fri, 2 Feb 2024 05:13:10 +0000 (21:13 -0800)]
vlib: flush rpcs on worker sync

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I89624254649089e497d119eb6cee2cecf3dc11f3

3 months agovlib api: move wrkr rpc flushing to vlib 84/40284/4
Florin Coras [Fri, 2 Feb 2024 04:46:15 +0000 (20:46 -0800)]
vlib api: move wrkr rpc flushing to vlib

Move vlib worker rpc flushing to main worker from memclnt api into vlib.
RPCs are no longer delivered via binary api queues

Type: refactor

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I5b8761a57d1f4a1f2220e860cfb2e6b980f46f6d

3 months agotls: set app closed flag in framework 82/40282/3
Florin Coras [Thu, 1 Feb 2024 00:18:17 +0000 (16:18 -0800)]
tls: set app closed flag in framework

Set the flag in tls framework as opposed to tls engines. This is similar
to passive close.

Type: improvement

Change-Id: I0c2a774b1ef9d7ec6ba74daf1678ea449815184f
Signed-off-by: Florin Coras <fcoras@cisco.com>
3 months agotls: convert ctx fields to connection flags 81/40281/2
Florin Coras [Wed, 31 Jan 2024 21:45:39 +0000 (13:45 -0800)]
tls: convert ctx fields to connection flags

Type: refactor

Change-Id: I527bbc1cf2e7b6d06fd0c88b7563fb59ed28bc40
Signed-off-by: Florin Coras <fcoras@cisco.com>
3 months agolinux-cp: add add_del_v3 and get_v2 methods 77/40277/2
Anton Nikolaev [Tue, 30 Jan 2024 11:54:00 +0000 (11:54 +0000)]
linux-cp: add add_del_v3 and get_v2 methods

Added vl_api_lcp_itf_pair_add_del_v3_t_handler method, it can return
vif_index in reply. Also added vl_api_lcp_itf_pair_get_v2_t_handler
methods, this method is able to dump only one lcp pair or dump all
lcp pairs via stream_msg.

Type: improvement
Change-Id: I1d25344ee57f8fac8b857bb3a9a03116230b4d2c
Signed-off-by: Anton Nikolaev <anikolaev@netgate.com>
3 months agoapi: provide api definition over api 45/40245/7
Ole Troan [Tue, 23 Jan 2024 17:56:23 +0000 (18:56 +0100)]
api: provide api definition over api

This patch allows a client to bootstrap itself by downloading the
JSON API definitions over the API itself.

This patch enables it for Python (probably need a dynamic language).
Call VPPApiClient with the new bootstrapapi=True parameter.

Example (Python):

from vpp_papi import VPPApiClient
vpp = VPPApiClient(bootstrapapi=True)
rv = vpp.connect("foobar")
assert rv == 0
print(f'SHOW VERSION: {vpp.api.show_version()}')
vpp.disconnect()

Type: feature
Change-Id: Id903fdccc82b2e22aa1994331d2c150253f2ccae
Signed-off-by: Ole Troan <otroan@employees.org>
3 months agohs-test: update docs on debugging 53/40253/2
Filip Tehlar [Wed, 24 Jan 2024 14:11:27 +0000 (15:11 +0100)]
hs-test: update docs on debugging

Type: docs

Change-Id: I3bd89feb53a35532c79283bcdac2c87635c60920
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
3 months agohs-test: use relative paths for docker volumes 49/40249/3
Filip Tehlar [Wed, 24 Jan 2024 10:59:44 +0000 (11:59 +0100)]
hs-test: use relative paths for docker volumes

Type: test

Change-Id: I9d5c15662e50ceea08d2ccc653db36c5e3df869e
Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
3 months agoip: don't export useless error counters for ip6 rewrite 53/40153/3
Arthur de Kerhor [Mon, 8 Jan 2024 18:30:57 +0000 (19:30 +0100)]
ip: don't export useless error counters for ip6 rewrite

the error node is set to ip6_input in the inline funcition
associated with ip6_rewrite. Thus, error counters defined
for node ip6 rewrite are never used.

Type: fix
Change-Id: Id6bef633928b0fff9069498c2e39e9f5bea2cf9b
Signed-off-by: Arthur de Kerhor <arthurdekerhor@gmail.com>
3 months agohs-test: updated golang and packages 82/39982/2
adrianvillin [Wed, 24 Jan 2024 06:45:59 +0000 (01:45 -0500)]
hs-test: updated golang and packages

ioutil.ReadFile is deprecated, replaced with os.ReadFile

Type: test

Change-Id: I9f8075796d05d47ea4dddd7e986026a267a7fe0c
Signed-off-by: adrianvillin <avillin@cisco.com>
3 months agoudp: update rx sw_if_index to ip-local selected one 44/40244/2
Florin Coras [Tue, 23 Jan 2024 17:40:45 +0000 (09:40 -0800)]
udp: update rx sw_if_index to ip-local selected one

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I0afd1b9ddbc17825aab3bfa3e5f9c6c0fbc561ca

3 months agomisc: Initial 24.06-rc0 commit 83/39983/1 v24.06-rc0
Andrew Yourtchenko [Wed, 24 Jan 2024 12:27:20 +0000 (12:27 +0000)]
misc: Initial 24.06-rc0 commit

Type: docs
Change-Id: Ia459d5ba6f7da3081192c6aba156e66fb2d6377c
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
3 months agovppinfra: fix clib_array_mask_u32 OOB reads 51/40151/5
Dmitry Valter [Thu, 18 Jan 2024 09:09:12 +0000 (09:09 +0000)]
vppinfra: fix clib_array_mask_u32 OOB reads

Handle non-even n_elts for the larger array instead of reading past
the source buffer.

Type: fix
Fixes: f62ed3f9c1ec3e8db36f63d6a54f46b7bea43723
Signed-off-by: Dmitry Valter <d-valter@yandex-team.com>
Change-Id: Ic1708a3f33fe71ca752345b5c77b6ae7a2d42bcd

3 months agotls: fix ho leak on tcp connect return 35/40235/5
Florin Coras [Tue, 23 Jan 2024 02:27:43 +0000 (18:27 -0800)]
tls: fix ho leak on tcp connect return

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I40345d635b8067dcffbbdd39d0a5b0c0934a6d54

3 months agopapi: support old style of providing apidir 31/40231/2
Vratko Polak [Mon, 22 Jan 2024 13:56:02 +0000 (14:56 +0100)]
papi: support old style of providing apidir

77caeb1b193404e76beb27a1aa81321e8eb1cf1f has changed the behavior
in an incompatible way, breaking users (including CSIT).

The new behavior is more pythonic,
but the old behavior has to be supported
at least one release after publicly deprecating it.

Type: fix

Change-Id: I9dfdd2229065010216e49db80b14b856c545965c
Signed-off-by: Vratko Polak <vrpolak@cisco.com>
3 months agotls: overlap parent opaque with listener ctx 36/40236/3
Florin Coras [Tue, 23 Jan 2024 02:38:08 +0000 (18:38 -0800)]
tls: overlap parent opaque with listener ctx

Type: improvement

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I0a0d0b8721f5a15da47c7ac0e58cd50e159b2f54

3 months agotls: set flag whenever app session is freed 34/40234/3
Florin Coras [Tue, 23 Jan 2024 02:06:41 +0000 (18:06 -0800)]
tls: set flag whenever app session is freed

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: I3d44ff851da00573343e15712284af3b9c3912e3

3 months agosession: flag instead of state for filtering ntf 33/40233/1
Florin Coras [Tue, 23 Jan 2024 01:04:36 +0000 (17:04 -0800)]
session: flag instead of state for filtering ntf

Avoid situations when notifications are delayed for long enough for
transports to start closing/cleaning up.

Type: fix

Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Id35b0099adb5242108154a5e19d5ee15e6ca0058

3 months agobuild: Explicitly use gmake 16/40216/3
Tom Jones [Thu, 18 Jan 2024 10:48:17 +0000 (10:48 +0000)]
build: Explicitly use gmake

VPP requires GNU Make to build, on GNU systems (such as Debian), GNU
Make is installed as 'make', typically with a symlink from 'gmake'.

On other systems (such as FreeBSD), 'make' is a BSD Make derriviative
and GNU Make is installed a 'gmake'.

Use $(MAKE) variable for make calls from within Makefiles.  This
variable is set to the path of the calling make program, i.e.,
/usr/local/bin/gmake on a bsd system.

This is the recommended way to call make from Makefiles in the GNU Make
documentation.

Type: improvement
Change-Id: Id9162a34a0f8358f22090718087918dae31c0fce
Signed-off-by: Tom Jones <thj@freebsd.org>
3 months agobuffers: add compile-time option to set buffer alignment 19/40219/2
Damjan Marion [Fri, 19 Jan 2024 20:19:57 +0000 (21:19 +0100)]
buffers: add compile-time option to set buffer alignment

Type: improvement
Change-Id: I88c4c45bed0bdd8686e17e4f77a7d32a08c995aa
Signed-off-by: Damjan Marion <damarion@cisco.com>
3 months agobuild: disable plugins which require openssl if openssl is not available 20/40220/1
Damjan Marion [Fri, 19 Jan 2024 20:55:03 +0000 (21:55 +0100)]
build: disable plugins which require openssl if openssl is not available

Type: improvement
Change-Id: I4591fcb31dd28d1771b3d6e5afdaa14f29efe6ef
Signed-off-by: Damjan Marion <damarion@cisco.com>
3 months agobuild: fix default platform 18/40218/2
Benoît Ganne [Fri, 19 Jan 2024 16:43:44 +0000 (17:43 +0100)]
build: fix default platform

When unsetting VPP_PLATFORM in cmake, it unmasks the cached value
instead, misleading the platform selection logic in src/cmake/cpu.cmake

Type: fix
Fixes: 01fe7ab88e

Change-Id: I676cd0af9ba28150f8ac07724c03df8ef24b640f
Signed-off-by: Benoît Ganne <bganne@cisco.com>