summaryrefslogtreecommitdiff
path: root/usertools
AgeCommit message (Collapse)Author
2024-11-19usertools/devbind: support all VFIO no-IOMMU sysfs valuesRogelio Domínguez Hernández
This patch adds support for 'y' and 'Y' values when reading vfio-pci unsafe_noiommu_mode flag. Possible values were taken from linux kernel (sysfs__read_bool() in tools/lib/api/fs/fs.c) Signed-off-by: Rogelio Domínguez Hernández <[email protected]> Reviewed-by: Robin Jarry <[email protected]>
2024-10-17usertools/devbind: support VFIO non-IOMMU modeFidaullah Noonari
This patch adds noiommu option to dpdk-devbind. If the no IOMMU is detected, then if noiommu flag is set the vfio-pci unsafe_noiommu_mode flag is set. Signed-off-by: Fidaullah Noonari <[email protected]> Signed-off-by: Stephen Hemminger <[email protected]> Acked-by: Bruce Richardson <[email protected]>
2024-07-09usertools/devbind: add ODM DMAAnoob Joseph
Add support for ODM DMA device in devbind. Signed-off-by: Anoob Joseph <[email protected]> Signed-off-by: Gowrishankar Muthukrishnan <[email protected]> Signed-off-by: Vidya Sagar Velumuri <[email protected]> Acked-by: Robin Jarry <[email protected]>
2024-07-09usertools: add telemetry exporterRobin Jarry
For now the telemetry socket is local to the machine running a DPDK application. Also, there is no official "schema" for the exposed metrics. Add a framework and a script to collect and expose these metrics to telemetry and observability agree gators such as Prometheus, Carbon or Influxdb. The exposed data must be done with end-users in mind, some DPDK terminology or internals may not make sense to everyone. The script only serves as an entry point and does not know anything about any specific metrics nor JSON data structures exposed in the telemetry socket. It uses dynamically loaded endpoint exporters which are basic python files that must implement two functions: def info() -> dict[MetricName, MetricInfo]: Mapping of metric names to their description and type. def metrics(sock: TelemetrySocket) -> list[MetricValue]: Request data from sock and return it as metric values. A metric value is a 3-tuple: (name: str, value: any, labels: dict). Each name must be present in info(). The sock argument passed to metrics() has a single method: def cmd(self, uri: str, arg: any = None) -> dict | list: Request JSON data to the telemetry socket and parse it to python values. The main script invokes endpoints and exports the data into an output format. For now, only two formats are implemented: * openmetrics/prometheus: text based format exported via a local HTTP server. * carbon/graphite: binary (python pickle) format exported to a distant carbon TCP server. As a starting point, 3 built-in endpoints are implemented: * counters: ethdev hardware counters * cpu: lcore usage * memory: overall memory usage The goal is to keep all built-in endpoints in the DPDK repository so that they can be updated along with the telemetry JSON data structures. Example output for the openmetrics:// format: ~# dpdk-telemetry-exporter.py -o openmetrics://:9876 & INFO using endpoint: counters (from .../telemetry-endpoints/counters.py) INFO using endpoint: cpu (from .../telemetry-endpoints/cpu.py) INFO using endpoint: memory (from .../telemetry-endpoints/memory.py) INFO listening on port 9876 [1] 838829 ~$ curl http://127.0.0.1:9876/ # HELP dpdk_cpu_total_cycles Total number of CPU cycles. # TYPE dpdk_cpu_total_cycles counter # HELP dpdk_cpu_busy_cycles Number of busy CPU cycles. # TYPE dpdk_cpu_busy_cycles counter dpdk_cpu_total_cycles{cpu="73", numa="0"} 4353385274702980 dpdk_cpu_busy_cycles{cpu="73", numa="0"} 6215932860 dpdk_cpu_total_cycles{cpu="9", numa="0"} 4353385274745740 dpdk_cpu_busy_cycles{cpu="9", numa="0"} 6215932860 dpdk_cpu_total_cycles{cpu="8", numa="0"} 4353383451895540 dpdk_cpu_busy_cycles{cpu="8", numa="0"} 6171923160 dpdk_cpu_total_cycles{cpu="72", numa="0"} 4353385274817320 dpdk_cpu_busy_cycles{cpu="72", numa="0"} 6215932860 # HELP dpdk_memory_total_bytes The total size of reserved memory in bytes. # TYPE dpdk_memory_total_bytes gauge # HELP dpdk_memory_used_bytes The currently used memory in bytes. # TYPE dpdk_memory_used_bytes gauge dpdk_memory_total_bytes 1073741824 dpdk_memory_used_bytes 794197376 Link: https://prometheus.io/docs/instrumenting/exposition_formats/#text-based-format Link: https://github.com/OpenObservability/OpenMetrics/blob/main/specification/OpenMetrics.md#text-format Link: https://graphite.readthedocs.io/en/latest/feeding-carbon.html#the-pickle-protocol Link: https://github.com/influxdata/telegraf/tree/master/plugins/inputs/prometheus Signed-off-by: Robin Jarry <[email protected]> Tested-by: Anthony Harivel <[email protected]>
2024-07-09usertools/pmdinfo: remove unneeded whitespaceStephen Hemminger
Fix the warning $ flake8 --max-line-length=100 dpdk-pmdinfo.py dpdk-pmdinfo.py:217:40: E203 whitespace before ':' Signed-off-by: Stephen Hemminger <[email protected]> Acked-by: Robin Jarry <[email protected]>
2024-07-09usertools/devbind: fix indentationStephen Hemminger
The python check tool (flake8) is picky about the indentation of continuation lines, and dpdk-devbind was not following standard. Error is: E127 continuation line over-indented for visual indent Fixes: 2ff801515e49 ("usertools/devbind: update octeontx2 DMA device") Signed-off-by: Stephen Hemminger <[email protected]> Acked-by: Robin Jarry <[email protected]>
2023-11-23usertools/rss: add cnxk default keyRobin Jarry
Add default RSS key for CNXK platforms. CNXK platform uses 48 bytes long key for hash calculations and a default RETA size of 64. Example: ~$ usertools/dpdk-rss-flows.py 8 28.0.0.0/24 40.0.0.0/24 -k cnxk SRC_IP DST_IP QUEUE 28.0.0.1 40.0.0.1 7 28.0.0.1 40.0.0.2 2 28.0.0.1 40.0.0.3 4 28.0.0.1 40.0.0.7 1 28.0.0.1 40.0.0.8 3 28.0.0.1 40.0.0.9 5 28.0.0.1 40.0.0.10 0 28.0.0.1 40.0.0.11 6 Suggested-by: Sunil Kumar Kori <[email protected]> Signed-off-by: Robin Jarry <[email protected]> Acked-by: Sunil Kumar Kori <[email protected]>
2023-11-23usertools/rss: add --info flagRobin Jarry
Add a flag to print the RSS key and RETA size that are used to compute balanced traffic. Example: $ usertools/dpdk-rss-flows.py -i 4 1.0.0.0 2.2.0.0/24 -k mlx RSS key: 2cc681d15bdbf4f7fca28319db1a3e946b9e38d92c9c03d1ad9944a7d… RETA size: 4 SRC_IP DST_IP QUEUE 1.0.0.0 2.2.0.1 2 1.0.0.0 2.2.0.2 0 1.0.0.0 2.2.0.4 1 1.0.0.0 2.2.0.6 3 The flag is only available with the default text output. Signed-off-by: Robin Jarry <[email protected]> Acked-by: Sunil Kumar Kori <[email protected]>
2023-11-23usertools/rss: add driver abstractionsRobin Jarry
The default RETA size is not the same for all drivers. In some drivers (mlx5), the RETA size may also be dependent on the number of RX queues. Introduce a new DriverInfo abstraction for known keys. Define a simple API to expose the RSS key and RETA size (based on the number of RX queues). Use that abstraction for all three known keys. Signed-off-by: Robin Jarry <[email protected]> Acked-by: Sunil Kumar Kori <[email protected]>
2023-11-23usertools/pmdinfo: fix usage typosRobin Jarry
The docs and script usages are not consistent. There is no .devices, .vendor_id nor .device_id fields. Fix usage to the correct field names. Some drivers do not expose any pci_ids, show how to use the []? jq operator to avoid spurious errors. Fixes: 0ce3cf4afd04 ("usertools/pmdinfo: rewrite simpler script") Cc: [email protected] Signed-off-by: Robin Jarry <[email protected]> Reviewed-by: David Marchand <[email protected]>
2023-08-25build: limit what is built for MSVCTyler Retzlaff
Build only kvargs and telemetry when is_ms_compiler. Signed-off-by: Tyler Retzlaff <[email protected]> Acked-by: Bruce Richardson <[email protected]>
2023-07-22usertools/rss: fix byte order of default i40e keyRobin Jarry
The key is represented as uint32 words in the driver source code but it is actually stored as little endian in the NIC registers. Fix the byte ordering in the python script. Fixes: 106a231ae528 ("usertools: add tool to generate balanced rss traffic flows") Reported-by: Abhiram R N <[email protected]> Signed-off-by: Robin Jarry <[email protected]>
2023-07-20usertools/rss: generate balanced RSS traffic flowsRobin Jarry
usage: dpdk-rss-flows.py [-h] [-s SPORT_RANGE] [-d DPORT_RANGE] [-r] [-k RSS_KEY] [-t RETA_SIZE] [-a] [-j] RX_QUEUES SRC DST Craft IP{v6}/{TCP/UDP} traffic flows that will evenly spread over a given number of RX queues according to the RSS algorithm. positional arguments: RX_QUEUES The number of RX queues to fill. SRC The source IP network/address. DST The destination IP network/address. options: -h, --help show this help message and exit -s SPORT_RANGE, --sport-range SPORT_RANGE The layer 4 (TCP/UDP) source port range. Can be a single fixed value or a range <start>-<end>. -d DPORT_RANGE, --dport-range DPORT_RANGE The layer 4 (TCP/UDP) destination port range. Can be a single fixed value or a range <start>-<end>. -r, --check-reverse-traffic The reversed traffic (source <-> dest) should also be evenly balanced in the queues. -k RSS_KEY, --rss-key RSS_KEY The random 40-bytes key used to compute the RSS hash. This option supports either a well- known name or the hex value of the key (well- known names: "intel", "mlx", default: "intel"). -t RETA_SIZE, --reta-size RETA_SIZE Size of the redirection table or "RETA" (default: 128). -a, --all-flows Output ALL flows that can be created based on source and destination address/port ranges along their matched queue number. ATTENTION: this option can produce very long outputs depending on the address and port range sizes. -j, --json Output in parseable JSON format. Examples: ~$ dpdk-rss-flows.py 8 28.0.0.0/24 40.0.0.0/24 SRC_IP DST_IP QUEUE 28.0.0.1 40.0.0.1 5 28.0.0.1 40.0.0.2 4 28.0.0.1 40.0.0.3 2 28.0.0.1 40.0.0.6 3 28.0.0.1 40.0.0.8 0 28.0.0.1 40.0.0.9 6 28.0.0.1 40.0.0.10 7 28.0.0.1 40.0.0.11 1 ~$ dpdk-rss-flows.py 8 28.0.0.0/24 40.0.0.0/24 -r SRC_IP DST_IP QUEUE QUEUE_REVERSE 28.0.0.1 40.0.0.1 5 3 28.0.0.1 40.0.0.2 4 2 28.0.0.1 40.0.0.8 0 6 28.0.0.1 40.0.0.9 6 7 28.0.0.1 40.0.0.16 2 4 28.0.0.1 40.0.0.19 3 5 28.0.0.1 40.0.0.24 1 0 28.0.0.1 40.0.0.25 7 1 ~$ dpdk-rss-flows.py 8 28.0.0.0/24 40.0.0.0/24 -s 32000-64000 -d 53 SRC_IP SPORT DST_IP DPORT QUEUE 28.0.0.1 32000 40.0.0.1 53 0 28.0.0.1 32001 40.0.0.1 53 1 28.0.0.1 32004 40.0.0.1 53 4 28.0.0.1 32005 40.0.0.1 53 5 28.0.0.1 32008 40.0.0.1 53 2 28.0.0.1 32009 40.0.0.1 53 3 28.0.0.1 32012 40.0.0.1 53 6 28.0.0.1 32013 40.0.0.1 53 7 ~$ dpdk-rss-flows.py 4 2a01:cb00:f8b:9700::/64 2620:52:0:2592::/64 -rj [ { "queue": 0, "queue_reverse": 3, "src_ip": "2a01:cb00:f8b:9700::1", "dst_ip": "2620:52:0:2592::1", "src_port": 0, "dst_port": 0 }, { "queue": 3, "queue_reverse": 0, "src_ip": "2a01:cb00:f8b:9700::1", "dst_ip": "2620:52:0:2592::2", "src_port": 0, "dst_port": 0 }, { "queue": 2, "queue_reverse": 1, "src_ip": "2a01:cb00:f8b:9700::1", "dst_ip": "2620:52:0:2592::3", "src_port": 0, "dst_port": 0 }, { "queue": 1, "queue_reverse": 2, "src_ip": "2a01:cb00:f8b:9700::1", "dst_ip": "2620:52:0:2592::1a", "src_port": 0, "dst_port": 0 } ] Signed-off-by: Robin Jarry <[email protected]> Acked-by: Anatoly Burakov <[email protected]>
2023-06-01usertools/telemetry: fix unused parameterSamina Arshad
This bug fix ensures that the runtime socket path is generated correctly, based on the user-specified file_prefix value, resolving the issue that occurred in the previous implementation. Fixes: a15fc792cfb6 ("usertools/telemetry: add file prefix argument") Cc: [email protected] Signed-off-by: Samina Arshad <[email protected]> Acked-by: Ciara Power <[email protected]> Acked-by: Huisong Li <[email protected]>
2023-03-19usertools/devbind: add ML device classSrikanth Yalavarthi
Added new ML device class and support for cnxk ML device. Signed-off-by: Srikanth Yalavarthi <[email protected]> Acked-by: Jerin Jacob <[email protected]>
2023-02-06usertools/telemetry: fix Python styleStephen Hemminger
This fixes most of the flake8 style warnings on the telemetry script. Signed-off-by: Stephen Hemminger <[email protected]>
2023-02-06usertools/telemetry: add file prefix argumentHuisong Li
Currently, the file prefix for DPDK runtime directory is 'rte' which was fixed in the telemetry client script. The user had to modify the prefix each time to run this script if the file prefix of application isn't 'rte'. So this patch adds an optional argument for the file prefix, like, "./dpdk-telemetry-client.py -f rte_xxx sock_path" Signed-off-by: Huisong Li <[email protected]> Acked-by: Bruce Richardson <[email protected]>
2023-02-06usertools/telemetry: use argparse to get script argumentsHuisong Li
The telemetry client script uses argparse module to get input parameter. argparse uses an optional positional arguments for local socket path to keep backward compatibility. Signed-off-by: Huisong Li <[email protected]> Acked-by: Bruce Richardson <[email protected]>
2022-11-22usertools/hugepages: show usage if no action specifiedThomas Monjalon
Previously, the script was doing nothing if no argument was provided. If neither show, mount/unmount, clear/reserve are specified, it is assumed that the user does not know how to use the script. So the usage and an error message are printed. The exit code will be non-zero. The user will understand something is wrong, and can recall the script with the option -h to get more information. Signed-off-by: Thomas Monjalon <[email protected]> Acked-by: David Marchand <[email protected]>
2022-10-31usertools/telemetry: add JSON pretty printChengwen Feng
Currently, the dpdk-telemetry.py show JSON in raw format under interactive mode, which is not good for human reading. E.g. The command '/ethdev/xstats,0' will output: {"/ethdev/xstats": {"rx_good_packets": 0, "tx_good_packets": 0, "rx_good_bytes": 0, "tx_good_bytes": 0, "rx_missed_errors": 0, "rx_errors": 0, "tx_errors": 0, "rx_mbuf_allocation_errors": 0, "rx_q0_packets": 0,...}} This patch supports JSON pretty print by adding extra indent=2 parameter under interactive mode, so the same command will output: { "/ethdev/xstats": { "rx_good_packets": 0, "tx_good_packets": 0, "rx_good_bytes": 0, "tx_good_bytes": 0, "rx_missed_errors": 0, "rx_errors": 0, "rx_mbuf_allocation_errors": 0, "rx_q0_packets": 0, ... } } Note: the non-interactive mode is made machine-readable and remains the original way (it means don't use indent to pretty print). Signed-off-by: Chengwen Feng <[email protected]> Acked-by: David Marchand <[email protected]> Acked-by: Ciara Power <[email protected]> Tested-by: Bruce Richardson <[email protected]>
2022-10-11usertools/pmdinfo: rewrite simpler scriptRobin Jarry
dpdk-pmdinfo.py does not produce any parseable output. The -r/--raw flag merely prints multiple independent JSON lines which cannot be fed directly to any JSON parser. Moreover, the script complexity is rather high for such a simple task: extracting PMD_INFO_STRING from .rodata ELF sections. Rewrite it so that it can produce valid JSON. Remove the PCI database parsing for PCI-ID to Vendor-Device names conversion. This should be done by external scripts (if really needed). The script passes flake8, black, isort and pylint checks. I have tested this with a matrix of python/pyelftools versions: pyelftools 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 3.6 ok ok ok ok ok ok ok ok 3.7 ok ok ok ok ok ok ok ok Python 3.8 ok ok ok ok ok ok ok ok 3.9 ok ok ok ok ok *ok ok ok 3.10 fail fail fail fail ok ok ok ok * Also tested on FreeBSD All failures with python 3.10 are related to the same issue: File "elftools/construct/lib/container.py", line 5, in <module> from collections import MutableMapping ImportError: cannot import name 'MutableMapping' from 'collections' Python 3.10 support is only available since pyelftools 0.26. The script will only work with Python 3.6 and later. Update the minimal system requirements, docs and release notes. Signed-off-by: Robin Jarry <[email protected]> Tested-by: Ferruh Yigit <[email protected]> Tested-by: Olivier Matz <[email protected]> Acked-by: Bruce Richardson <[email protected]>
2022-06-27usertools: add options for hugetlbfs mount point ownerDmitry Kozlyuk
Per mount(8), the previous owner and mode of the mount point become invisible as long as this filesystem remains mounted. Because dpdk-hugepages.py must be run as root, the new owner would be root. This is undesirable if the hugepage directory is being set up by the administrator for an unprivileged user. HugeTLB filesystem has options to set the mount point owner. Add --user/-U and --group/-G options to apply this when mounting. The benefit of performing this in dpdk-hugepages.py is that the user does not need to care about this detail of mount command operation. Signed-off-by: Dmitry Kozlyuk <[email protected]> Acked-by: Bruce Richardson <[email protected]>
2022-06-27usertools: add option for hugetlbfs directoryDmitry Kozlyuk
dpdk-hugepages.py had /dev/hugepages hardcoded as the mount point. It may be desirable to setup hugepage directory at another path, for example, when using hugepages of multiple sizes in different directories or when granting different permissions to mount points. Add --directory/-d option to the script. Signed-off-by: Dmitry Kozlyuk <[email protected]> Acked-by: Bruce Richardson <[email protected]>
2022-06-01usertools/devbind: support virtio block deviceAndy Pei
Add virtio blk device support to devbind. Signed-off-by: Andy Pei <[email protected]> Acked-by: Chenbo Xia <[email protected]>
2022-02-09support systemd service convention for runtime directoryStephen Hemminger
Systemd.exec supports configuring the runtime directory of a service via RuntimeDirectory=. This creates the directory with the necessary permissions which actual service may not have if running in container. The change to DPDK is to look for the environment RUNTIME_DIRECTORY first and use that in preference to the fallback alternatives. Signed-off-by: Stephen Hemminger <[email protected]> Acked-by: Bruce Richardson <[email protected]> Reviewed-by: Morten Brørup <[email protected]>
2022-01-12drivers: remove octeontx2 driversJerin Jacob
As per the deprecation notice, In the view of enabling unified driver for octeontx2(cn9k)/octeontx3(cn10k), removing drivers/octeontx2 drivers and replace with drivers/cnxk/ which supports both octeontx2(cn9k) and octeontx3(cn10k) SoCs. This patch does the following - Replace drivers/common/octeontx2/ with drivers/common/cnxk/ - Replace drivers/mempool/octeontx2/ with drivers/mempool/cnxk/ - Replace drivers/net/octeontx2/ with drivers/net/cnxk/ - Replace drivers/event/octeontx2/ with drivers/event/cnxk/ - Replace drivers/crypto/octeontx2/ with drivers/crypto/cnxk/ - Rename config/arm/arm64_octeontx2_linux_gcc as config/arm/arm64_cn9k_linux_gcc - Update the documentation and MAINTAINERS to reflect the same. - Change the reference to OCTEONTX2 as OCTEON 9. Old release notes and the kernel related documentation is not accounted for this change. Signed-off-by: Jerin Jacob <[email protected]> Acked-by: Ferruh Yigit <[email protected]> Acked-by: Akhil Goyal <[email protected]> Acked-by: Ruifeng Wang <[email protected]>
2021-11-10usertools/devbind: update octeontx2 DMA deviceRadha Mohan Chintakuntla
The octeontx2_dma rawdev driver is removed in DPDK-21.11. The new driver for the same device uses the dmadev. So this patch updates the device naming and lists it under dma devices section. Signed-off-by: Radha Mohan Chintakuntla <[email protected]>
2021-11-07usertools/devbind: add Kunpeng DMAChengwen Feng
Add Kunpeng DMA device ID to dmadev category. Signed-off-by: Chengwen Feng <[email protected]>
2021-10-25usertools/devbind: conform to PEP8 recommended styleStephen Hemminger
This fixes most of the warnings from the Flake8 style checker. The ones remaining are long lines (we allow > 79 characters) and a line break warning. The line break style changed in later versions of PEP 8 and the tool is not updated. https://www.flake8rules.com/rules/W503.html Signed-off-by: Stephen Hemminger <[email protected]> Acked-by: Anatoly Burakov <[email protected]> Acked-by: Bruce Richardson <[email protected]> Tested-by: Bruce Richardson <[email protected]>
2021-10-25usertools/pmdinfo: fix plugin auto scanDavid Marchand
Migration to argparse was incomplete. $ dpdk-pmdinfo.py -p $(which dpdk-testpmd) Traceback (most recent call last): File "/usr/bin/dpdk-pmdinfo.py", line 626, in <module> main() File "/usr/bin/dpdk-pmdinfo.py", line 596, in main exit(scan_for_autoload_pmds(args[0])) TypeError: 'Namespace' object does not support indexing Fixes: 81255f27c65c ("usertools: replace optparse with argparse") Cc: [email protected] Signed-off-by: David Marchand <[email protected]> Reviewed-by: Robin Jarry <[email protected]>
2021-10-22usertools/devbind: move ioat device IDs to DMA classConor Walsh
Move Intel IOAT devices from Misc to DMA devices. Signed-off-by: Conor Walsh <[email protected]> Reviewed-by: Kevin Laatz <[email protected]> Reviewed-by: Bruce Richardson <[email protected]>
2021-10-22usertools/devbind: move idxd device ID to DMA classKevin Laatz
The dmadev library is the preferred abstraction for using IDXD devices and will replace the rawdev implementation in future. This patch moves the IDXD device ID to the dmadev class. Signed-off-by: Kevin Laatz <[email protected]> Reviewed-by: Conor Walsh <[email protected]> Acked-by: Bruce Richardson <[email protected]>
2021-10-22usertools/devbind: add DMA device classKevin Laatz
Add a new class for DMA devices. Devices listed under the DMA class are to be used with the dmadev library. Signed-off-by: Kevin Laatz <[email protected]> Reviewed-by: Conor Walsh <[email protected]> Reviewed-by: Bruce Richardson <[email protected]> Reviewed-by: Chengwen Feng <[email protected]>
2021-10-19usertools/telemetry: list file-prefixesConor Walsh
This patch adds the option --list (-l) to dpdk-telemetry.py which will print all of the available file-prefixes for DPDK processes that have telemetry enabled. The prefixes will also be printed if the user passes an incorrect prefix in the --file-prefix (-f) option. Signed-off-by: Conor Walsh <[email protected]> Acked-by: Ciara Power <[email protected]>
2021-10-19usertools/telemetry: fix instance option helpConor Walsh
The instance option help text was incorrect, this patch corrects it. Fixes: 11435aae2089 ("usertools/telemetry: connect to separate instances") Signed-off-by: Conor Walsh <[email protected]> Acked-by: Bruce Richardson <[email protected]>
2021-10-14usertools/telemetry: provide info on available socketsBruce Richardson
When a user runs the dpdk-telemetry script and fails to connect because the socket path does not exist, run a scan for possible sockets that could be connected to and inform the user of the command needed to connect to those. For example: $ ./dpdk-telemetry.py -i4 Connecting to /run/user/1000/dpdk/rte/dpdk_telemetry.v2:4 Error connecting to /run/user/1000/dpdk/rte/dpdk_telemetry.v2:4 Other DPDK telemetry sockets found: - dpdk_telemetry.v2 # Connect with './dpdk-telemetry.py' - dpdk_telemetry.v2:2 # Connect with './dpdk-telemetry.py -i 2' - dpdk_telemetry.v2:1 # Connect with './dpdk-telemetry.py -i 1' Signed-off-by: Bruce Richardson <[email protected]> Acked-by: Ciara Power <[email protected]> Reviewed-by: Conor Walsh <[email protected]>
2021-10-14usertools/telemetry: connect to separate instancesBruce Richardson
For processes run using "in-memory" mode sharing the same runtime dir, we add support for connecting to the separate instance sockets created using ":1", ":2" etc. via new "-i" or "--instance" argument. Add details on connecting to separate instances to the telemetry howto document. Signed-off-by: Bruce Richardson <[email protected]> Acked-by: Ciara Power <[email protected]> Tested-by: Conor Walsh <[email protected]>
2021-10-02net/cnxk: support inline security setup for cn10kNithin Dabilpuram
Add support for inline inbound and outbound IPSec for SA create, destroy and other NIX / CPT LF configurations. This patch also changes dpdk-devbind.py to list new inline device as misc device. Signed-off-by: Nithin Dabilpuram <[email protected]> Acked-by: Jerin Jacob <[email protected]>
2021-10-01usertools: silence prompts for telemetry input pipeBruce Richardson
When the input to the script is coming from a device which is not a TTY then we become less verbose and skip the prompts and helpful messages about what is happening. Signed-off-by: Bruce Richardson <[email protected]> Acked-by: Ciara Power <[email protected]>
2021-10-01usertools: fix handling EOF for telemetry input pipeBruce Richardson
To allow the script to take queries from input pipes e.g. "echo /ethdev/stats,0 | dpdk-telemetry.py", we need to handle the case of EOF correctly without crashing with an exception. Do this by using a try-except block around the input handling. Fixes: 6a2967c112a3 ("usertools: add new telemetry script") Cc: [email protected] Signed-off-by: Bruce Richardson <[email protected]> Acked-by: Ciara Power <[email protected]>
2021-10-01usertools: fix flake8 compliance of telemetry scriptBruce Richardson
Fix style errors reported by flake8. Fixes: 6a2967c112a3 ("usertools: add new telemetry script") Fixes: 2d9a697e41ca ("usertools: add file-prefix option for telemetry") Cc: [email protected] Signed-off-by: Bruce Richardson <[email protected]> Acked-by: Kevin Laatz <[email protected]> Acked-by: Ciara Power <[email protected]>
2021-07-05raw/cnxk_bphy: add baseband PHY skeleton driverTomasz Duszynski
Add baseband phy skeleton driver. Baseband phy is a hardware subsystem accelerating 5G/LTE related tasks. Note this driver isn't involved into any sort baseband protocol processing. Instead it just provides means for configuring hardware. Signed-off-by: Jakub Palider <[email protected]> Signed-off-by: Tomasz Duszynski <[email protected]> Reviewed-by: Jerin Jacob <[email protected]>
2021-07-05raw/cnxk_bphy: add BPHY CGX/RPM skeleton driverTomasz Duszynski
Add baseband PHY CGX/RPM skeleton driver which merely probes a matching device. CGX/RPM are Ethernet MACs hardwired to baseband subsystem. Signed-off-by: Tomasz Duszynski <[email protected]> Signed-off-by: Jakub Palider <[email protected]> Reviewed-by: Jerin Jacob <[email protected]>
2021-05-19usertools: add Intel DLB device bindingTimothy McDaniel
Add DLB to usertools/dpdk-devbind.py so that it shows up as an eventdev, and is identified as Intel DLB. Signed-off-by: Timothy McDaniel <[email protected]>
2021-04-21build: change indentation in infrastructure filesBruce Richardson
Switch from using tabs to 4 spaces for meson.build indentation, for the basic infrastructure and tooling files, as well as doc and kernel directories. Signed-off-by: Bruce Richardson <[email protected]>
2021-03-25usertools: show hugepages requested/set on failureThomas Monjalon
In case the number of requested hugepages cannot be set, a more detailed error message is printed. The new message does not mention "reserve" because setting can be reserving or clearing. The filename and numbers requested/set are printed to ease debugging. Signed-off-by: Thomas Monjalon <[email protected]>
2021-03-25usertools: check 0-division with hugepage sizeThomas Monjalon
The default page size can be None, and the page size from user request can be 0 kB if lower than 1024. In these cases, a division will fail. In order to avoid a Python exception, the page size is checked and an error message "Invalid page size" is printed. A similar error message is printed in set_hugepages() if the size is not supported, except at this stage the message can be completed with "Valid page sizes". Unfortunately the first check is too early to print such information. A third error message can be printed in a different place (get_memsize) in case of a format issue, e.g. a negative size. The function get_memsize() is also used for total requested size, so the error message "not a valid page size" was potentially wrong. This message is replaced with the more general "is not a valid size". Signed-off-by: Thomas Monjalon <[email protected]> Acked-by: Stephen Hemminger <[email protected]> Acked-by: Anatoly Burakov <[email protected]>
2021-03-25usertools: print process name when telemetry connectsBruce Richardson
When the dpdk-telemetry client connects to a DPDK instance, we can use the PID provided in the initial connection message to query from /proc the name of the process we are connected to, and display that to the user. We use the "cmdline" procfs entry for the query since that is available on both Linux and FreeBSD (assuming procfs is mounted on the BSD instance). Signed-off-by: Bruce Richardson <[email protected]> Acked-by: Anatoly Burakov <[email protected]> Acked-by: Kevin Laatz <[email protected]>
2021-03-25usertools: add file-prefix option for telemetryKevin Laatz
Currently the dpdk-telemetry.py script connects to all running DPDK apps consecutively. With the addition of this file-prefix argument, we can limit the amount of information returned providing improved consumability and precision to the user. Signed-off-by: Kevin Laatz <[email protected]> Reviewed-by: Bruce Richardson <[email protected]> Tested-by: Bruce Richardson <[email protected]> Acked-by: Anatoly Burakov <[email protected]>
2021-02-11usertools: fix binding built-in kernel driverYongxin Liu
A driver can be loaded as a dynamic module or a built-in module. In commit 681a67288655 ("usertools: check if module is loaded before binding"), the script only checks modules in /sys/module/. However, for built-in kernel driver, it only shows up in /sys/module/, if it has a version or at least one parameter. So add check for modules in /lib/modules/$(uname -r)/modules.builtin. Fixes: 681a67288655 ("usertools: check if module is loaded before binding") Cc: [email protected] Signed-off-by: Yongxin Liu <[email protected]> Reviewed-by: Anatoly Burakov <[email protected]>