Buffer System

Napatech Link-Capture™ Software Features

Platform
Napatech SmartNIC
Content Type
Feature Description
Capture Software Version
Link™ Capture Software 12.11

In this chapter

This chapter describes the buffer system, which handles temporary storing in SDRAM, and bandwidth shaping of frames transferred over the host interface to the allocated buffers in the host memory.

Number of buffers

The number of host buffers used depends on the HostBuffersRx and HostBuffersTx parameters in the ntservice.ini file (see DN-0449).The maximum number of RX host buffers is 128 with dynamic segment size and 64 with static segment size, and the maximum number of TX host buffers is 128 with dynamic segment size and 64 with static segment size. The RX host buffer segment size is determined by the HostBufferSegmentSizeRx parameter in the ntservice.ini file (see DN-0449). With dynamic RX segment size the segment size changes every time a segment is delivered. This together with packet-based interface gives the best performance. If a fixed RX segment length is required and a static RX segment size is selected, extra memory is used for handling segment meta data. The TX host buffer segment size can be set to 1 MB, 2 MB or 4 MB.

The minimum RX buffer size is 16 Mbytes and the minimum TX buffer size is 4 Mbytes. The maximum host buffer size is 1 Tbyte. The buffer size can be set in increments of 4 Mbytes. A maximum host buffer memory of 1 Tbyte in total is available for RX host buffers and the same for TX host buffers.

The hostBufferAllowance parameter in the NT_NetRxOpen function (see DN-0449) allows different applications to share host buffers in such a way that a slow application does not occupy all of the host buffers and thereby causes a faster application to lose packets. This applies especially to capture applications.

Tuning throughput, CPU load and latency

Two parameters in the ntservice.ini file can be used for tuning throughput, CPU load and latency: HostBufferPollInterval and HostBufferSegmentTimeOut.
CAUTION:
These parameters must be set with caution since mismatching values can result in packet loss.

The HostBufferPollInterval parameter determines how often in μs the ntservice daemon polls for new data in the host buffers. The parameter can take these values: default, 100, 250, 500 and 1000. Changing the value from default results in a higher latency, but a lower CPU utilization, which allows ntservice more time to service the host buffers.

The HostBufferSegmentTimeOut parameter determines how often in μs the FPGA releases segments that are not full. The parameter can take these values: default, 100, 250, 500, 1000, 10000, 25000, 50000 and 100000. Changing the value from default results in a higher latency, but a lower CPU utilization, which allows ntservice more time to service the host buffers.

Reconfiguration of the buffer system

Reconfiguring the buffer system requires that ntservice is first stopped and then started (see DN-0379 or DN-1067).