Age | Commit message (Collapse) | Author |
|
Signed-off-by: Matias Elo <matias.elo@nokia.com>
|
|
Set the dual_dual rate shaper parameter to true when setting peak_rate
and peak_burst in addition to commit_rate and commit_burst.
Rely on the dual_rate parameter set false, instead of zero peak_rate
and peak_burst, to indicate that dual rate shaping is not used.
This makes the example code follow the API spec.
Signed-off-by: Nithin Dabilpuram <ndabilpuram@marvell.com>
Reviewed-by: Janne Peltonen <janne.peltonen@nokia.com>
|
|
Clamp shaper profile rate and burst to limits from capability.
Signed-off-by: Nithin Dabilpuram <ndabilpuram@marvell.com>
Reviewed-by: Janne Peltonen <janne.peltonen@nokia.com>
|
|
Use the new shorter session creation error names.
Signed-off-by: Janne Peltonen <janne.peltonen@nokia.com>
Reviewed-by: Anoob Joseph <anoobj@marvell.com>
|
|
Use the new cipher_iv_len session parameter for IV length and leave
the cipher IV data to its default value now that the API allows it.
Signed-off-by: Janne Peltonen <janne.peltonen@nokia.com>
Reviewed-by: Anoob Joseph <anoobj@marvell.com>
|
|
In AH the ICV field is in the authenticated packet range. Set the
hash_result_in_auth_range flag in crypto session creation for AH.
Signed-off-by: Janne Peltonen <janne.peltonen@nokia.com>
Reviewed-by: Anoob Joseph <anoobj@marvell.com>
|
|
Set correct application exit code on failure.
Signed-off-by: Matias Elo <matias.elo@nokia.com>
Reviewed-by: Tuomas Taipale <tuomas.taipale@nokia.com>
|
|
Previously, the output file was not closed if odp_init_global() or
odp_init_local() call failed.
Fixes: https://github.com/OpenDataPlane/odp/issues/1457
Signed-off-by: Matias Elo <matias.elo@nokia.com>
Reviewed-by: Tuomas Taipale <tuomas.taipale@nokia.com>
|
|
Remove application specific atomic operations and use ODP API functions
and types instead.
Signed-off-by: Matias Elo <matias.elo@nokia.com>
Reviewed-by: Tuomas Taipale <tuomas.taipale@nokia.com>
|
|
Randomizing the initial IP ID (fragment identification) value of a
tunnel may reduce IP ID clashes, but there does not seem to be any
clear benefit of jumping to a new random ID value when the ID wraps
around. Remove the re-randomization to make the code simpler.
Signed-off-by: Janne Peltonen <janne.peltonen@nokia.com>
Reviewed-by: Tuomas Taipale <tuomas.taipale@nokia.com>
|
|
Reusing the same ESP IV within the same SA should not be done.
Fix the code to not reuse pre-generated IVs but generate a new
random IV for every outbound ESP packet.
Signed-off-by: Janne Peltonen <janne.peltonen@nokia.com>
Reviewed-by: Tuomas Taipale <tuomas.taipale@nokia.com>
|
|
Signed-off-by: Matias Elo <matias.elo@nokia.com>
|
|
Fix memory leak that would occur if pattern matching rule policy
parsing is stopped due to an error.
Signed-off-by: Tuomas Taipale <tuomas.taipale@nokia.com>
Reviewed-by: Matias Elo <matias.elo@nokia.com>
|
|
Update test applications to use odp_timer_pool_param_init()
instead of memset() in timer pool parameter initialization.
Signed-off-by: Petri Savolainen <petri.savolainen@nokia.com>
Reviewed-by: Matias Elo <matias.elo@nokia.com>
|
|
Signed-off-by: Matias Elo <matias.elo@nokia.com>
|
|
Now that the CLI helper no longer creates a thread, the ODP instance
is not needed by odph_cli_init().
Signed-off-by: Jere Leppänen <jere.leppanen@nokia.com>
Reviewed-by: Matias Elo <matias.elo@nokia.com>
|
|
Fix "ISO C does not support '__int128' types" errors when building with
'pedantic' option.
Signed-off-by: Matias Elo <matias.elo@nokia.com>
Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
|
|
Fix "ISO C forbids specifying range of elements to initialize" and "range
expressions in switch statements are non-standard" errors when building
with 'pedantic' option.
Signed-off-by: Matias Elo <matias.elo@nokia.com>
Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
|
|
Fix "ISO C does not allow extra ';' outside of a function" errors when
building with 'pedantic' option.
Signed-off-by: Matias Elo <matias.elo@nokia.com>
Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
|
|
Fix "ISO C forbids zero-size array" errors when building with 'pedantic'
option.
Signed-off-by: Matias Elo <matias.elo@nokia.com>
Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
|
|
Fix "ISO C forbids braced-groups within expressions" errors when building
with 'pedantic' option.
Signed-off-by: Matias Elo <matias.elo@nokia.com>
Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
|
|
Fix "format '%x' expects argument of type 'unsigned int *'" errors when
building with 'pedantic' option.
Signed-off-by: Matias Elo <matias.elo@nokia.com>
Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
|
|
Signed-off-by: Matias Elo <matias.elo@nokia.com>
|
|
Add odph_cli_run() and remove odph_cli_start().
Don't create a thread in the CLI helper. Instead, the caller may
create a thread and call odph_cli_run() to run the CLI.
Signed-off-by: Jere Leppänen <jere.leppanen@nokia.com>
Reviewed-by: Matias Elo <matias.elo@nokia.com>
Cc: Lifang Zhang <lifang.zhang@nokia.com>
|
|
Use the newer odph_thread_create() and odph_thread_join() functions in
examples and tests instead of the deprecated odph_odpthreads_create()
and odph_odpthreads_join().
Signed-off-by: Jere Leppänen <jere.leppanen@nokia.com>
Reviewed-by: Matias Elo <matias.elo@nokia.com>
|
|
Use the new odph_thread_param_init() function to initialize
odph_thread_param_t.
Signed-off-by: Jere Leppänen <jere.leppanen@nokia.com>
Reviewed-by: Matias Elo <matias.elo@nokia.com>
|
|
Use the new odph_thread_common_param_init() function to initialize
odph_thread_common_param_t.
Signed-off-by: Jere Leppänen <jere.leppanen@nokia.com>
Reviewed-by: Matias Elo <matias.elo@nokia.com>
|
|
When the env variable ODP_IPSEC_USE_POLL_QUEUES is set,
the application tries to create plain type queues.
Otherwise the application goes for scheduled type completion
queue. Check if the selected IPsec dest queue type is
supported before creating the destination queue.
Signed-off-by: Aakash Sasidharan <asasidharan@marvell.com>
Reviewed-by: Janne Peltonen <janne.peltonen@nokia.com>
|
|
Test odp_queue_print_all() and odp_schedule_print() calls with
multiple queues created.
Signed-off-by: Petri Savolainen <petri.savolainen@nokia.com>
Reviewed-by: Matias Elo <matias.elo@nokia.com>
|
|
Signed-off-by: Matias Elo <matias.elo@nokia.com>
|
|
Signed-off-by: Matias Elo <matias.elo@nokia.com>
|
|
Use the new scheduler debug print function.
Signed-off-by: Petri Savolainen <petri.savolainen@nokia.com>
Reviewed-by: Jere Leppänen <jere.leppanen@nokia.com>
|
|
For IPsec live and router mode tests, the application needs
to be killed explicitly once the ping tests are done. The pid
of the app is buffered in app_pid file which is later read
into the env variable APP_PID.
Allow the PID file to be created before reading the file
by moving the cat command just before the kill command is
invoked.
Signed-off-by: Aakash Sasidharan <asasidharan@marvell.com>
Reviewed-by: Janne Peltonen <janne.peltonen@nokia.com>
|
|
Enable the only remaining tests for ipsec_api in CI.
Signed-off-by: Aakash Sasidharan <asasidharan@marvell.com>
Reviewed-by: Janne Peltonen <janne.peltonen@nokia.com>
|
|
Not all implementations may support MD5 auth algorithm for
AH mode. Update the run scripts for AH mode tests to use
SHA1 auth algorithm instead of MD5.
Signed-off-by: Aakash Sasidharan <asasidharan@marvell.com>
Reviewed-by: Janne Peltonen <janne.peltonen@nokia.com>
|
|
Currently AH mode supports only MD5 auth. Enable support for
SHA1 and SHA256 auth algorithms.
Signed-off-by: Aakash Sasidharan <asasidharan@marvell.com>
Reviewed-by: Janne Peltonen <janne.peltonen@nokia.com>
|
|
Allow user to register CLI commands with a name, function, and an
optional help text.
Signed-off-by: Jere Leppänen <jere.leppanen@nokia.com>
Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
|
|
Use the new timer set return codes: ODP_TIMER_TOO_NEAR,
ODP_TIMER_TOO_FAR and ODP_TIMER_FAIL.
Signed-off-by: Petri Savolainen <petri.savolainen@nokia.com>
Reviewed-by: Jere Leppänen <jere.leppanen@nokia.com>
Reviewed-by: Matias Elo <matias.elo@nokia.com>
|
|
Use the new timer set return codes: ODP_TIMER_TOO_NEAR,
ODP_TIMER_TOO_FAR and ODP_TIMER_FAIL.
Signed-off-by: Petri Savolainen <petri.savolainen@nokia.com>
Reviewed-by: Jere Leppänen <jere.leppanen@nokia.com>
Reviewed-by: Matias Elo <matias.elo@nokia.com>
|
|
Replace ODP_CLOCK_CPU with ODP_CLOCK_DEFAULT on example and
performance test applications.
Signed-off-by: Petri Savolainen <petri.savolainen@nokia.com>
Reviewed-by: Matias Elo <matias.elo@nokia.com>
Reviewed-by: Janne Peltonen <janne.peltonen@nokia.com>
|
|
Replace ODP_CLOCK_CPU and _EXT with new enums.
Signed-off-by: Petri Savolainen <petri.savolainen@nokia.com>
Reviewed-by: Matias Elo <matias.elo@nokia.com>
Reviewed-by: Janne Peltonen <janne.peltonen@nokia.com>
|
|
Use TM start to start the TM system after creation and
TM stop to stop it before destroying TM queues.
Signed-off-by: Nithin Dabilpuram <ndabilpuram@marvell.com>
Reviewed-by: Janne Peltonen <janne.peltonen@nokia.com>
|
|
Use commit_rate and peak_rate in shaper params instead of commit_bps
and peak_bps.
Signed-off-by: Nithin Dabilpuram <ndabilpuram@marvell.com>
Reviewed-by: Janne Peltonen <janne.peltonen@nokia.com>
|
|
Signed-off-by: Matias Elo <matias.elo@nokia.com>
|
|
Signed-off-by: Matias Elo <matias.elo@nokia.com>
|
|
Currently, the max and min timeout are being configured with the
minimum resolution supported by the timer implementation, instead
retrieve the resolution and min timeout supported for the given
max timeout and configure them accordingly.
Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com>
Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
|
|
The network interfaces and configurations required for
the application change based on the application mode in
which the test is being run. Introduce env variable
IPSEC_APP_MODE which will be set by run script.
The supported modes are:
0 - standalone mode, 1 - live mode and 2 - router mode.
Though linux-gen supports multiple "loop" devices like loop1
and loop2, other ODP implementations may not support
multiple loop interfaces. To allow flexibility for other
platforms, introduce following env variables in the runtime
scripts for standalone mode:
* IF_LIST env variable lists all the interfaces used for
standalone mode of test.
* For outbound tests, stream entry has source interface as IN_IF
and destination interface as OUT_IF.
* For inbound tests, stream entry has source interface as OUT_IF
and destination interface as IN_IF.
* Introduce ROUTE_IF_INB and ROUTE_IF_OUTB for routing the IPSEC
processed packets in standalone tests.
Introduce platform specific pktio_env script to define these
environment variables.
Signed-off-by: Aakash Sasidharan <asasidharan@marvell.com>
Reviewed-by: Matias Elo <matias.elo@nokia.com>
|
|
Include inbound ESP tests scripts in tests now that ESP test packet
construction has been fixed.
Signed-off-by: Janne Peltonen <janne.peltonen@nokia.com>
Reviewed-by: Matias Elo <matias.elo@nokia.com>
|
|
The length field of the IP header of a tunneled packet was left zero
when building IPsec test packets. Fix the issue by setting the length.
Suggested-by: Aakash Sasidharan <asasidharan@marvell.com>
Signed-off-by: Janne Peltonen <janne.peltonen@nokia.com>
Reviewed-by: Aakash Sasidharan <asasidharan@marvell.com>
|
|
Call odp_ipsec_result() also after synchronous IPsec processing and
check if the operation succeeded.
Signed-off-by: Janne Peltonen <janne.peltonen@nokia.com>
Reviewed-by: Aakash Sasidharan <asasidharan@marvell.com>
|