aboutsummaryrefslogtreecommitdiff
path: root/config
AgeCommit message (Collapse)Author
2021-12-08linux-gen: cpu: add configuration option to use static cpu frequencyMatias Elo
Add 'system:cpu_hz_static' configuration option for using a static CPU frequency value. When enabled, CPU frequency values returned by odp_cpu_hz() and odp_cpu_hz_id() calls are read from the OS only once during ODP initialization. Enabling this option removes system calls from odp_cpu_hz() and odp_cpu_hz_id() implementations. NOTE: This option should only be used on systems where CPU frequency scaling is disabled. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
2021-07-07linux-gen: sched: dynamic spread load balancePetri Savolainen
Estimate current load on a spread ring as number of queues allocated to it divided by number of threads preferring the spread. Each thread runs a series of spread load balance checks starting at every 1M schedule calls. This helps especially when there are less threads in a group than the number of spreads configured. Scheduler moves more queues to those spread rings that have more thread capacity. This works best when all threads and queues are equally active. Signed-off-by: Petri Savolainen <petri.savolainen@nokia.com> Reviewed-by: Matias Elo <matias.elo@nokia.com>
2021-07-05linux-gen: dpdk: add configuration option for multicast frame receptionMatias Elo
Add configuration option 'pktio_dpdk.multicast_en' for DPDK pktio to enable/disable reception of all multicast frames. Fixes: https://github.com/OpenDataPlane/odp/issues/1326 Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com> Reported-by: Bogdan Pricope <bogdan.pricope.2013@gmail.com>
2021-05-20linux-gen: ipsec: add configurable ordering modeJanne Peltonen
Add new config file parameters to control how original input queue order is maintained during asynchronous IPsec processing. When asynchronous IPsec operations are started within an ordered scheduling context, packet order is maintained in IPsec completion queues but the order in which the sequence number gets assigned or the anti-replay check done is not guaranteed. This commit adds a config option to force the stateful part of IPsec processing to be done in the correct order, at the cost of reduced parallelism. The ordering mechanism added in this commit uses the order_lock method of the internal scheduling API to stop the calling thread until it is its turn (i.e the preceding scheduling contexts associated with the same input queue have been released). Future commits may add more elaborate mechanisms. The default behaviour does not change. By default no ordering is done. Signed-off-by: Janne Peltonen <janne.peltonen@nokia.com> Reviewed-by: Jere Leppänen <jere.leppanen@nokia.com>
2021-02-05linux-gen: sched_basic: implement disabling predefined sched groupsMatias Elo
Implement odp_schedule_config_t.sched_group option for the basic scheduler. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
2021-02-05linux-gen: thread: read maximum number of threads from config fileJanne Peltonen
Add system:thread_count_max config parameter that can be used to reduce the maximum number of threads below the build time configured maximum. This can be used to reduce thread related resource consumption such as thread-local memory. Most code still uses the build time limit, ODP_THREAD_COUNT_MAX, so this change merely enables possible later optimizations in those cases. ODP-DPDK will already benefit from this change as the number of queue pairs for a crypto device can be lowered to match the actual number of threads without ODP-DPDK having worry about possible sharing of the queue pairs between threads. Signed-off-by: Janne Peltonen <janne.peltonen@nokia.com> Reviewed-by: Matias Elo <matias.elo@nokia.com>
2021-01-15linux-gen: pool: add maximum packet length config optionMatias Elo
Add configuration file option for the maximum packet data length in bytes. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Jere Leppänen <jere.leppanen@nokia.com>
2020-05-15linux-gen: pool: implement cache size parameterPetri Savolainen
Implement new cache size parameters. Cache and burst sizes are now defined per pool. Cache size value from config file is used to initialize cache size parameters. Burst size value from config file is used, when cache size is larger than 2x burst size. Signed-off-by: Petri Savolainen <petri.savolainen@nokia.com> Reviewed-by: Matias Elo <matias.elo@nokia.com>
2020-04-28linux-gen: system: read default cpu frequency values from config fileMatias Elo
Enable setting odp_cpu_hz() and odp_cpu_hz_max() values manually usinge the config file on platforms where frequencies aren't available using standard Linux methods. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
2020-01-28linux-gen: pool: set packet pool max align capaPetri Savolainen
Implement the new packet align pool parameter with minimal changes. Packet pools are aligned always to the base align, so all application requests up to that value are supported. Base align can be changed through the config file. Signed-off-by: Petri Savolainen <petri.savolainen@nokia.com> Reviewed-by: Stanislaw Kardach <skardach@marvell.com>
2019-11-26linux-gen: pktio: add pktin frame offset config optionPetri Savolainen
Added config file option to control frame start offset in packet input. Signed-off-by: Petri Savolainen <petri.savolainen@nokia.com> Reviewed-by: Matias Elo <matias.elo@nokia.com>
2019-11-26linux-gen: pool: add data align config file optionsPetri Savolainen
Added packet and buffer data alignment options into the config file. For packets, this is the segment base address alignment. For buffers, this is minimum data alignment, application alignment requirements are rounded up to this value. Signed-off-by: Petri Savolainen <petri.savolainen@nokia.com> Reviewed-by: Matias Elo <matias.elo@nokia.com>
2019-11-06linux-gen: timer: add inline_thread_type config file optionPetri Savolainen
Added option to control which thread types process (non-private) inline timer pools. Signed-off-by: Petri Savolainen <petri.savolainen@nokia.com> Reviewed-by: Matias Elo <matias.elo@nokia.com>
2019-10-23linux-gen: dpdk: make storing packet flow hash configurableMatias Elo
Make saving RX RSS hash as ODP flow hash optional (disabled by default). This improves performance by removing a write operation to an additional cache line. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
2019-10-02linux-gen: timer: add poll interval time conf optionPetri Savolainen
Improve timer accuracy by increasing timer pool scan rate to twice per resolution. Add configure file option to limit inline timer polling rate in nanoseconds. With the default value, each thread checks if timer pool scan is needed in maximum once per 500us. Polling rate is increased if a timer pool is created with a higher resolution requirement. Signed-off-by: Petri Savolainen <petri.savolainen@nokia.com> Reviewed-by: Matias Elo <matias.elo@nokia.com>
2019-04-18linux-gen: shm: increase amount of pre-reserved single va memoryMatias Elo
Due to changes in pool implementation (linux-gen: pool: use pointer ring to store buffer headers) additional single va memory is required for process mode operation. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Carl Wallen <carl.wallen@nokia.com> Reported-by: Carl Wallen <carl.wallen@nokia.com>
2019-04-15linux-gen: pool: enable setting local cache and burst size using configMatias Elo
Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
2018-11-28linux-gen: shm: remove single_va configuration optionMatias Elo
Process mode is now enabled by setting odp_init_global() parameter odp_init_t.mem_model to ODP_MEM_MODEL_PROCESS. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Reviewed-by: Petri Savolainen <petri.savolainen@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-11-16linux-gen: ishm: add config option for selecting huge page usage limitMatias Elo
Add configuration option for selecting huge page usage limit in kilobytes. Memory reservations larger than this value are done using huge pages (if available), whereas smaller reservations are done using normal pages to conserve memory. The default value is still 64 kilobytes. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-11-16linux-gen: timer: add config option for inline timer poll frequencyMatias Elo
Add configure option 'timer.inline_poll_interval' for adjusting inline timer polling frequency. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-11-16linux-gen: timer: enable inline timer implementation using config fileMatias Elo
Add configure option 'timer.inline' for enabling inline timer implementation. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-11-14linux-gen: ishm: read single va size from configMatias Elo
Simplify adjusting single VA memory size by moving the value to ODP config (shm.single_va_size). The default size is dropped to 128MB to save memory. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-10-31linux-gen: config: add schedule group config file optionsPetri Savolainen
Added options to disable unused automatic schedule groups. Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-10-29linux-gen: sched: add spread weight config file optionPetri Savolainen
Add new config file option to control scheduler internal queue preference ratio. Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-10-18linux-gen: pool: add max num packets in config filePetri Savolainen
This config is used to for maximum capability. The default capability needs to be modest so that system memory limit is not exceeded. User may increase maximum number of packets when system memory size allows (and SHM single VA is not used). Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-09-28linux-gen: shm: add option for allocating internal shm using single VAMatias Elo
Enables using ODP in process mode. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-09-28linux-gen: sched: per priority burst size configurationPetri Savolainen
Change burst size configuration to be per priority instead of only two levels of control (high/low priority). Also maximum burst size is configurable, so that application may request a large burst of events without a worry that a large burst of low priority events is received. Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-09-12linux-gen: ishm: make huge page cache size dynamicJosep Puigdemont
Signed-off-by: Josep Puigdemont <josep.puigdemont@linaro.org> Reviewed-and-tested-by: Matias Elo <matias.elo@nokia.com> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-09-12linux-gen: ishm: implement huge page cacheJosep Puigdemont
With this patch, ODP will pre-allocate several huge pages at init time. When memory is to be mapped into a huge page, one that was pre-allocated will be used, if available, this way ODP won't have to trap into the kernel to allocate huge pages. The idea with this implementation is to trick ishm into thinking that a file descriptor where to map the memory was provided, this way it it won't try to allocate one itself. This file descriptor is one of those previously allocated at init time. When the system is done with this file descriptor, instead of closing it, it is put back into the list of available huge pages, ready to be reused. A collateral effect of this patch is that memory is not zeroed out when it is reused. WARNING: This patch will not work when using process mode threads. For several reasons, this may not work when using ODP_ISHM_SINGLE_VA either, so when this flag is set, the list of pre-allocated files is not used. By default ODP will not reserve any huge pages, to tell ODP to do that, update the ODP configuration file with something like this: shm: { num_cached_hp = 32 } Example usage: $ echo odp.config odp_implementation = "linux-generic" config_file_version = "0.0.1" shm: { num_cached_hp = 32 } $ ODP_CONFIG_FILE=odp.conf ./test/validation/api/shmem/shmem_main This patch solves bug #3774: https://bugs.linaro.org/show_bug.cgi?id=3774 Signed-off-by: Josep Puigdemont <josep.puigdemont@linaro.org> Reviewed-and-tested-by: Matias Elo <matias.elo@nokia.com> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-07-11linux-gen: sched: configurable default burst sizePetri Savolainen
Make default burst sizes configurable. User can set limits for burst size round up in high/low priority. When less than burst_size_xx events are requested, scheduler rounds up the number of events to these limit and stash extra events. Requests with more events are not round down. So, user can use small values in burst size configure for better real-time support, but still request large number of events for better throughput on non real-time threads. Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-04-11linux-gen: netmap: ring configuration for VALEJuha-Matti Tilli
Configure ring for VALE. On my test laptop, this may increase odp_l2fwd performance from 1.9 MPPS to 2.3 MPPS, so it gives over 20% more performance. Signed-off-by: Juha-Matti Tilli <juha-matti.tilli@iki.fi> Reviewed-and-tested-by: Matias Elo <matias.elo@nokia.com> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-03-22linux-gen: sched: configurable priority spreadPetri Savolainen
Use configuration file to enable user to change priority queue spreading. Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org> Reviewed-by: Balasubramanian Manoharan <bala.manoharan@linaro.org> Reviewed-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-03-22linux-gen: queue: configurable max sizePetri Savolainen
Use configuration file to enable user to change the maximum queue size. Ring memory for all queues is reserved based on the max size. Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org> Reviewed-by: Balasubramanian Manoharan <bala.manoharan@linaro.org> Reviewed-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-03-22linux-gen: queue: configurable default sizePetri Savolainen
Use configuration file to enable user to change default queue size. Queue size parameter from application is used for larger queues than the default size. Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org> Reviewed-by: Balasubramanian Manoharan <bala.manoharan@linaro.org> Reviewed-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-03-06linux-gen: add runtime configuration fileMatias Elo
Enables changing ODP runtime configuration options by using an optional configuration file (libconfig). Path to the conf file is passed using environment variable ODP_CONF_FILE. If ODP_CONF_FILE or a particular option is not set, hardcoded default values are used instead. An template configuration file is provided in config/odp-linux.conf. Runtime configuration is initially used by DPDK pktio to set NIC options. Adds new dependency to libconfig library. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov@linaro.org> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2013-12-30tree-wide: introduce SPDX Unique License IdentifiersKim Phillips
ODP includes big blocks of License headers in all files. This not only blows up the source code with mostly redundant information, but also makes it very difficult to generate License Clearing Reports. An additional problem is that even the same licenses are referred to by a number of slightly varying text blocks (full, abbreviated, different indentation, line wrapping and/or white space, with obsolete address information, ...) which makes automatic processing a nightmare. To make this easier, such license headers in the source files will be replaced with a single line reference to Unique License Identifiers as defined by the Linux Foundation's SPDX project [1]. I.e, in a source file the full BSD 3-clause header text will be replaced by a single line: SPDX-License-Identifier: BSD-3-Clause We use the SPDX Unique License Identifiers here; these are available at [2]. Note: From the legal point of view, this patch is supposed to be only a change to the textual representation of the license information, but in no way any change to the actual license terms. With this patch applied, all files will still be licensed under the same terms they were before. [1] http://spdx.org/ [2] http://spdx.org/licenses/ Signed-off-by: Kim Phillips <kim.phillips@linaro.org>
2013-11-18Added pthread helpersPetri Savolainen
Style cleaning on all files. Added support for pthreads and first multithreading test app code.
2013-11-18Added initial ODP filesPetri Savolainen
Directory arch/linux-generic contains ODP headers and implementation for linux-generic target. Use 'make libs' to build ODP library and 'make docs' to build ODP API documentation. Directory test contains simple test application to test few API calls. Use 'make' to build the test app, or 'make libs' or 'make docs' to build ODP libs and docs, respectively.