- <variable_name_N> = <value_N>
-
-
-Application resources present in the configuration file
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
-.. _table_ip_pipelines_resource_name:
-
-.. tabularcolumns:: |p{4cm}|p{6cm}|p{6cm}|
-
-.. table:: Application resource names in the configuration file
-
- +----------------------------+-----------------------------+-------------------------------------------------+
- | Resource type | Format | Examples |
- +============================+=============================+=================================================+
- | Pipeline | ``PIPELINE<ID>`` | ``PIPELINE0``, ``PIPELINE1`` |
- +----------------------------+-----------------------------+-------------------------------------------------+
- | Mempool | ``MEMPOOL<ID>`` | ``MEMPOOL0``, ``MEMPOOL1`` |
- +----------------------------+-----------------------------+-------------------------------------------------+
- | Link (network interface) | ``LINK<ID>`` | ``LINK0``, ``LINK1`` |
- +----------------------------+-----------------------------+-------------------------------------------------+
- | Link RX queue | ``RXQ<LINK_ID>.<QUEUE_ID>`` | ``RXQ0.0``, ``RXQ1.5`` |
- +----------------------------+-----------------------------+-------------------------------------------------+
- | Link TX queue | ``TXQ<LINK_ID>.<QUEUE_ID>`` | ``TXQ0.0``, ``TXQ1.5`` |
- +----------------------------+-----------------------------+-------------------------------------------------+
- | Software queue | ``SWQ<ID>`` | ``SWQ0``, ``SWQ1`` |
- +----------------------------+-----------------------------+-------------------------------------------------+
- | Traffic Manager | ``TM<LINK_ID>`` | ``TM0``, ``TM1`` |
- +----------------------------+-----------------------------+-------------------------------------------------+
- | KNI (kernel NIC interface) | ``KNI<LINK_ID>`` | ``KNI0``, ``KNI1`` |
- +----------------------------+-----------------------------+-------------------------------------------------+
- | Source | ``SOURCE<ID>`` | ``SOURCE0``, ``SOURCE1`` |
- +----------------------------+-----------------------------+-------------------------------------------------+
- | Sink | ``SINK<ID>`` | ``SINK0``, ``SINK1`` |
- +----------------------------+-----------------------------+-------------------------------------------------+
- | Message queue | ``MSGQ<ID>`` | ``MSGQ0``, ``MSGQ1``, |
- | | ``MSGQ-REQ-PIPELINE<ID>`` | ``MSGQ-REQ-PIPELINE2``, ``MSGQ-RSP-PIPELINE2,`` |
- | | ``MSGQ-RSP-PIPELINE<ID>`` | ``MSGQ-REQ-CORE-s0c1``, ``MSGQ-RSP-CORE-s0c1`` |
- | | ``MSGQ-REQ-CORE-<CORE_ID>`` | |
- | | ``MSGQ-RSP-CORE-<CORE_ID>`` | |
- +----------------------------+-----------------------------+-------------------------------------------------+
-
-``LINK`` instances are created implicitly based on the ``PORT_MASK`` application startup argument.
-``LINK0`` is the first port enabled in the ``PORT_MASK``, port 1 is the next one, etc.
-The LINK ID is different than the DPDK PMD-level NIC port ID, which is the actual position in the bitmask mentioned above.
-For example, if bit 5 is the first bit set in the bitmask, then ``LINK0`` is having the PMD ID of 5.
-This mechanism creates a contiguous LINK ID space and isolates the configuration file against changes in the board
-PCIe slots where NICs are plugged in.
-
-``RXQ``, ``TXQ``, ``TM`` and ``KNI`` instances have the LINK ID as part of their name.
-For example, ``RXQ2.1``, ``TXQ2.1`` and ``TM2`` are all associated with ``LINK2``.
-
-
-Rules to parse the configuration file
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
-The main rules used to parse the configuration file are:
-
-1. Application resource name determines the type of resource based on the name prefix.
-
- *Example*: all software queues need to start with ``SWQ`` prefix, so ``SWQ0`` and ``SWQ5`` are valid software
- queue names.
-
-2. An application resource is defined by creating a configuration file section with its name.
- The configuration file section allows fine tuning on any of the resource parameters.
- Some resource parameters are mandatory, in which case it is required to have them specified as part of the
- section, while some others are optional, in which case they get assigned their default value when not present.
-
- *Example*: section ``SWQ0`` defines a software queue named SWQ0, whose parameters are detailed as part of this section.
-
-3. An application resource can also be defined by referencing it.
- Referencing a resource takes place by simply using its name as part of the value assigned to a variable in any
- configuration file section.
- In this case, the resource is registered with all its parameters having their default values.
- Optionally, a section with the resource name can be added to the configuration file to fine tune some or all
- of the resource parameters.
-
- *Example*: in section ``PIPELINE3``, variable ``pktq_in`` includes ``SWQ5`` as part of its list, which results
- in defining a software queue named ``SWQ5``; when there is no ``SWQ5`` section present in the configuration file,
- ``SWQ5`` gets registered with default parameters.
-
-
-.. _ip_pipeline_pipeline_section:
-
-PIPELINE section
-~~~~~~~~~~~~~~~~
-
-.. _table_ip_pipelines_pipeline_section_1:
-
-.. tabularcolumns:: |p{2.5cm}|p{7cm}|p{1.5cm}|p{1.5cm}|p{1.5cm}|
-
-.. table:: Configuration file PIPELINE section (1/2)
-
- +---------------+-----------------------------------------------------------+---------------+------------------------+----------------+
- | Section | Description | Optional | Range | Default value |
- +===============+===========================================================+===============+========================+================+
- | type | Pipeline type. Defines the functionality to be | NO | See "List | N/A |
- | | executed. | | of pipeline types" | |
- +---------------+-----------------------------------------------------------+---------------+------------------------+----------------+
- | core | CPU core to run the current pipeline. | YES | See "CPU Core | CPU socket 0, |
- | | | | notation" | core 0, |
- | | | | | hyper-thread 0 |
- +---------------+-----------------------------------------------------------+---------------+------------------------+----------------+
- | pktq_in | Packet queues to serve as input ports for the | YES | List of input | Empty list |
- | | current pipeline instance. The acceptable packet | | packet queue IDs | |
- | | queue types are: ``RXQ``, ``SWQ``, ``TM`` and ``SOURCE``. | | | |
- | | First device in this list is used as pipeline input port | | | |
- | | 0, second as pipeline input port 1, etc. | | | |
- +---------------+-----------------------------------------------------------+---------------+------------------------+----------------+
- | pktq_out | Packet queues to serve as output ports for the | YES | List of output | Empty list |
- | | current pipeline instance. The acceptable packet | | packet queue IDs. | |
- | | queue types are: ``TXQ``, ``SWQ``, ``TM`` and ``SINK``. | | | |
- | | First device in this list is used as pipeline output | | | |
- | | port 0, second as pipeline output port 1, etc. | | | |
- +---------------+-----------------------------------------------------------+---------------+------------------------+----------------+
-
-.. _table_ip_pipelines_pipeline_section_2:
-
-.. tabularcolumns:: |p{2.5cm}|p{7cm}|p{1.5cm}|p{1.5cm}|p{1.5cm}|
-
-.. table:: Configuration file PIPELINE section (2/2)
-
- +---------------+-----------------------------------------------------------+---------------+------------------------+----------------+
- | Section | Description | Optional | Range | Default value |
- +===============+===========================================================+===============+========================+================+
- | msgq_in | Input message queues. These queues contain | YES | List of message | Empty list |
- | | request messages that need to be handled by the | | queue IDs | |
- | | current pipeline instance. The type and format of | | | |
- | | request messages is defined by the pipeline type. | | | |
- | | For each pipeline instance, there is an input | | | |
- | | message queue defined implicitly, whose name is: | | | |
- | | ``MSGQ-REQ-<PIPELINE_ID>``. This message queue | | | |
- | | should not be mentioned as part of msgq_in list. | | | |
- +---------------+-----------------------------------------------------------+---------------+------------------------+----------------+
- | msgq_out | Output message queues. These queues are used by | YES | List of message | Empty list |
- | | the current pipeline instance to write response | | queue IDs | |
- | | messages as result of request messages being | | | |
- | | handled. The type and format of response | | | |
- | | messages is defined by the pipeline type. | | | |
- | | For each pipeline instance, there is an output | | | |
- | | message queue defined implicitly, whose name is: | | | |
- | | ``MSGQ-RSP-<PIPELINE_ID>``. This message queue | | | |
- | | should not be mentioned as part of msgq_out list. | | | |
- +---------------+-----------------------------------------------------------+---------------+------------------------+----------------+
- | timer_period | Time period, measured in milliseconds, | YES | milliseconds | 1 ms |
- | | for handling the input message queues. | | | |
- +---------------+-----------------------------------------------------------+---------------+------------------------+----------------+
- | <any other> | Arguments to be passed to the current pipeline | Depends on | Depends on | Depends on |
- | | instance. Format of the arguments, their type, | pipeline type | pipeline type | pipeline type |
- | | whether each argument is optional or mandatory | | | |
- | | and its default value (when optional) are defined | | | |
- | | by the pipeline type. | | | |
- | | The value of the arguments is applicable to the | | | |
- | | current pipeline instance only. | | | |
- +---------------+-----------------------------------------------------------+---------------+------------------------+----------------+
-
-
-CPU core notation
-^^^^^^^^^^^^^^^^^
-
-The CPU Core notation is::
-
- <CPU core> ::= [s|S<CPU socket ID>][c|C]<CPU core ID>[h|H]
-
-For example::
-
- CPU socket 0, core 0, hyper-thread 0: 0, c0, s0c0
-
- CPU socket 0, core 0, hyper-thread 1: 0h, c0h, s0c0h
-
- CPU socket 3, core 9, hyper-thread 1: s3c9h
-
-
-MEMPOOL section
-~~~~~~~~~~~~~~~
-
-.. _table_ip_pipelines_mempool_section:
-
-.. tabularcolumns:: |p{2.5cm}|p{6cm}|p{1.5cm}|p{1.5cm}|p{3cm}|
-
-.. table:: Configuration file MEMPOOL section
-
- +---------------+-----------------------------------------------+----------+----------+---------------------------+
- | Section | Description | Optional | Type | Default value |
- +===============+===============================================+==========+==========+===========================+
- | buffer_size | Buffer size (in bytes) for the current | YES | uint32_t | 2048 |
- | | buffer pool. | | | + sizeof(struct rte_mbuf) |
- | | | | | + HEADROOM |
- +---------------+-----------------------------------------------+----------+----------+---------------------------+
- | pool_size | Number of buffers in the current buffer pool. | YES | uint32_t | 32K |
- +---------------+-----------------------------------------------+----------+----------+---------------------------+
- | cache_size | Per CPU thread cache size (in number of | YES | uint32_t | 256 |
- | | buffers) for the current buffer pool. | | | |
- +---------------+-----------------------------------------------+----------+----------+---------------------------+
- | cpu | CPU socket ID where to allocate memory for | YES | uint32_t | 0 |
- | | the current buffer pool. | | | |
- +---------------+-----------------------------------------------+----------+----------+---------------------------+
-
-
-LINK section
-~~~~~~~~~~~~
-
-.. _table_ip_pipelines_link_section:
-
-.. tabularcolumns:: |p{3cm}|p{7cm}|p{1.5cm}|p{1.5cm}|p{2cm}|
-
-.. table:: Configuration file LINK section
-
- +-----------------+----------------------------------------------+----------+----------+-------------------+
- | Section entry | Description | Optional | Type | Default value |
- +=================+==============================================+==========+==========+===================+
- | arp_q | NIC RX queue where ARP packets should | YES | 0 .. 127 | 0 (default queue) |
- | | be filtered. | | | |
- +-----------------+----------------------------------------------+----------+----------+-------------------+
- | tcp_syn_local_q | NIC RX queue where TCP packets with SYN | YES | 0 .. 127 | 0 (default queue) |
- | | flag should be filtered. | | | |
- +-----------------+----------------------------------------------+----------+----------+-------------------+
- | ip_local_q | NIC RX queue where IP packets with local | YES | 0 .. 127 | 0 (default queue) |
- | | destination should be filtered. | | | |
- | | When TCP, UDP and SCTP local queues are | | | |
- | | defined, they take higher priority than this | | | |
- | | queue. | | | |
- +-----------------+----------------------------------------------+----------+----------+-------------------+
- | tcp_local_q | NIC RX queue where TCP packets with local | YES | 0 .. 127 | 0 (default queue) |
- | | destination should be filtered. | | | |
- +-----------------+----------------------------------------------+----------+----------+-------------------+
- | udp_local_q | NIC RX queue where TCP packets with local | YES | 0 .. 127 | 0 (default queue) |
- | | destination should be filtered. | | | |
- +-----------------+----------------------------------------------+----------+----------+-------------------+
- | sctp_local_q | NIC RX queue where TCP packets with local | YES | 0 .. 127 | 0 (default queue) |
- | | destination should be filtered. | | | |
- +-----------------+----------------------------------------------+----------+----------+-------------------+
- | promisc | Indicates whether current link should be | YES | YES/NO | YES |
- | | started in promiscuous mode. | | | |
- +-----------------+----------------------------------------------+----------+----------+-------------------+
-
-
-RXQ section
-~~~~~~~~~~~
-
-.. _table_ip_pipelines_rxq_section:
-
-.. tabularcolumns:: |p{3cm}|p{7cm}|p{1.5cm}|p{1.5cm}|p{2cm}|
-
-.. table:: Configuration file RXQ section
-
- +---------------+--------------------------------------------+----------+----------+---------------+
- | Section | Description | Optional | Type | Default value |
- +===============+============================================+==========+==========+===============+
- | mempool | Mempool to use for buffer allocation for | YES | uint32_t | MEMPOOL0 |
- | | current NIC RX queue. The mempool ID has | | | |
- | | to be associated with a valid instance | | | |
- | | defined in the mempool entry of the global | | | |
- | | section. | | | |
- +---------------+--------------------------------------------+----------+----------+---------------+
- | Size | NIC RX queue size (number of descriptors) | YES | uint32_t | 128 |
- +---------------+--------------------------------------------+----------+----------+---------------+
- | burst | Read burst size (number of descriptors) | YES | uint32_t | 32 |
- +---------------+--------------------------------------------+----------+----------+---------------+
-
-
-TXQ section
-~~~~~~~~~~~
-
-.. _table_ip_pipelines_txq_section:
-
-.. tabularcolumns:: |p{2.5cm}|p{7cm}|p{1.5cm}|p{2cm}|p{1.5cm}|
-
-.. table:: Configuration file TXQ section
-
- +---------------+----------------------------------------------+----------+------------------+---------------+
- | Section | Description | Optional | Type | Default value |
- +===============+==============================================+==========+==================+===============+
- | size | NIC TX queue size (number of descriptors) | YES | uint32_t | 512 |
- | | | | power of 2 | |
- | | | | > 0 | |
- +---------------+----------------------------------------------+----------+------------------+---------------+
- | burst | Write burst size (number of descriptors) | YES | uint32_t | 32 |
- | | | | power of 2 | |
- | | | | 0 < burst < size | |
- +---------------+----------------------------------------------+----------+------------------+---------------+
- | dropless | When dropless is set to NO, packets can be | YES | YES/NO | NO |
- | | dropped if not enough free slots are | | | |
- | | currently available in the queue, so the | | | |
- | | write operation to the queue is non- | | | |
- | | blocking. | | | |
- | | When dropless is set to YES, packets cannot | | | |
- | | be dropped if not enough free slots are | | | |
- | | currently available in the queue, so the | | | |
- | | write operation to the queue is blocking, as | | | |
- | | the write operation is retried until enough | | | |
- | | free slots become available and all the | | | |
- | | packets are successfully written to the | | | |
- | | queue. | | | |
- +---------------+----------------------------------------------+----------+------------------+---------------+
- | n_retries | Number of retries. Valid only when dropless | YES | uint32_t | 0 |
- | | is set to YES. When set to 0, it indicates | | | |
- | | unlimited number of retries. | | | |
- +---------------+----------------------------------------------+----------+------------------+---------------+
-
-
-SWQ section
-~~~~~~~~~~~
-
-.. _table_ip_pipelines_swq_section:
-
-.. tabularcolumns:: |p{2.5cm}|p{7cm}|p{1.5cm}|p{1.5cm}|p{1.5cm}|
-
-.. table:: Configuration file SWQ section
-
- +---------------+----------------------------------------------+----------+------------------+---------------+
- | Section | Description | Optional | Type | Default value |
- +===============+==============================================+==========+==================+===============+
- | size | Queue size (number of packets) | YES | uint32_t | 256 |
- | | | | power of 2 | |
- +---------------+----------------------------------------------+----------+------------------+---------------+
- | burst_read | Read burst size (number of packets) | YES | uint32_t | 32 |
- | | | | power of 2 | |
- | | | | 0 < burst < size | |
- +---------------+----------------------------------------------+----------+------------------+---------------+
- | burst_write | Write burst size (number of packets) | YES | uint32_t | 32 |
- | | | | power of 2 | |
- | | | | 0 < burst < size | |
- +---------------+----------------------------------------------+----------+------------------+---------------+
- | dropless | When dropless is set to NO, packets can be | YES | YES/NO | NO |
- | | dropped if not enough free slots are | | | |
- | | currently available in the queue, so the | | | |
- | | write operation to the queue is non- | | | |
- | | blocking. | | | |
- | | When dropless is set to YES, packets cannot | | | |
- | | be dropped if not enough free slots are | | | |
- | | currently available in the queue, so the | | | |
- | | write operation to the queue is blocking, as | | | |
- | | the write operation is retried until enough | | | |
- | | free slots become available and all the | | | |
- | | packets are successfully written to the | | | |
- | | queue. | | | |
- +---------------+----------------------------------------------+----------+------------------+---------------+
- | n_retries | Number of retries. Valid only when dropless | YES | uint32_t | 0 |
- | | is set to YES. When set to 0, it indicates | | | |
- | | unlimited number of retries. | | | |
- +---------------+----------------------------------------------+----------+------------------+---------------+
- | cpu | CPU socket ID where to allocate memory | YES | uint32_t | 0 |
- | | for this SWQ. | | | |
- +---------------+----------------------------------------------+----------+------------------+---------------+
-
-
-TM section
-~~~~~~~~~~
-
-.. _table_ip_pipelines_tm_section:
-
-.. tabularcolumns:: |p{2.5cm}|p{7cm}|p{1.5cm}|p{1.5cm}|p{1.5cm}|
-
-.. table:: Configuration file TM section
-
- +---------------+---------------------------------------------+----------+----------+---------------+
- | Section | Description | Optional | Type | Default value |
- +===============+=============================================+==========+==========+===============+
- | Cfg | File name to parse for the TM configuration | YES | string | tm_profile |
- | | to be applied. The syntax of this file is | | | |
- | | described in the examples/qos_sched DPDK | | | |
- | | application documentation. | | | |
- +---------------+---------------------------------------------+----------+----------+---------------+
- | burst_read | Read burst size (number of packets) | YES | uint32_t | 64 |
- +---------------+---------------------------------------------+----------+----------+---------------+
- | burst_write | Write burst size (number of packets) | YES | uint32_t | 32 |
- +---------------+---------------------------------------------+----------+----------+---------------+
-
-
-KNI section
-~~~~~~~~~~~
-
-.. _table_ip_pipelines_kni_section:
-
-.. tabularcolumns:: |p{2.5cm}|p{7cm}|p{1.5cm}|p{1.5cm}|p{1.5cm}|
-
-.. table:: Configuration file KNI section
-
- +---------------+----------------------------------------------+----------+------------------+---------------+
- | Section | Description | Optional | Type | Default value |
- +===============+==============================================+==========+==================+===============+
- | core | CPU core to run the KNI kernel thread. | YES | See "CPU Core | Not set |
- | | When core config is set, the KNI kernel | | notation" | |
- | | thread will be bound to the particular core. | | | |
- | | When core config is not set, the KNI kernel | | | |
- | | thread will be scheduled by the OS. | | | |
- +---------------+----------------------------------------------+----------+------------------+---------------+
- | mempool | Mempool to use for buffer allocation for | YES | uint32_t | MEMPOOL0 |
- | | current KNI port. The mempool ID has | | | |
- | | to be associated with a valid instance | | | |
- | | defined in the mempool entry of the global | | | |
- | | section. | | | |
- +---------------+----------------------------------------------+----------+------------------+---------------+
- | burst_read | Read burst size (number of packets) | YES | uint32_t | 32 |
- | | | | power of 2 | |
- | | | | 0 < burst < size | |
- +---------------+----------------------------------------------+----------+------------------+---------------+
- | burst_write | Write burst size (number of packets) | YES | uint32_t | 32 |
- | | | | power of 2 | |
- | | | | 0 < burst < size | |
- +---------------+----------------------------------------------+----------+------------------+---------------+
- | dropless | When dropless is set to NO, packets can be | YES | YES/NO | NO |
- | | dropped if not enough free slots are | | | |
- | | currently available in the queue, so the | | | |
- | | write operation to the queue is non- | | | |
- | | blocking. | | | |
- | | When dropless is set to YES, packets cannot | | | |
- | | be dropped if not enough free slots are | | | |
- | | currently available in the queue, so the | | | |
- | | write operation to the queue is blocking, as | | | |
- | | the write operation is retried until enough | | | |
- | | free slots become available and all the | | | |
- | | packets are successfully written to the | | | |
- | | queue. | | | |
- +---------------+----------------------------------------------+----------+------------------+---------------+
- | n_retries | Number of retries. Valid only when dropless | YES | uint64_t | 0 |
- | | is set to YES. When set to 0, it indicates | | | |
- | | unlimited number of retries. | | | |
- +---------------+----------------------------------------------+----------+------------------+---------------+
-
-
-SOURCE section
-~~~~~~~~~~~~~~
-
-.. _table_ip_pipelines_source_section:
-
-.. tabularcolumns:: |p{2.5cm}|p{7cm}|p{1.5cm}|p{1.5cm}|p{2cm}|
-
-.. table:: Configuration file SOURCE section
-
- +---------------+---------------------------------------+----------+----------+---------------+
- | Section | Description | Optional | Type | Default value |
- +===============+=======================================+==========+==========+===============+
- | Mempool | Mempool to use for buffer allocation. | YES | uint32_t | MEMPOOL0 |
- +---------------+---------------------------------------+----------+----------+---------------+
- | Burst | Read burst size (number of packets) | | uint32_t | 32 |
- +---------------+---------------------------------------+----------+----------+---------------+
-
-
-SINK section
-~~~~~~~~~~~~
-
-Currently, there are no parameters to be passed to a sink device, so
-SINK section is not allowed.