diff options
author | Vratko Polak <vrpolak@cisco.com> | 2023-12-14 17:11:38 +0100 |
---|---|---|
committer | Beno�t Ganne <bganne@cisco.com> | 2023-12-15 08:44:10 +0000 |
commit | 04d262d1eba969538950da7183cfa77ff3d70dff (patch) | |
tree | 093b6db0909074f5731c2e67c5060a9738c3b8d4 /src/plugins/rdma/format.c | |
parent | 6d14c0cc5af3185563c4c7a00fe297cb1301ea03 (diff) |
rdma: add rdma_create_v4 that handles flags properly
The _v3 was not handling endianness on flags (e.g. mode).
Marking _v3 as deprecated, but keeping it
as there might be users who learned to preprocess their flag values.
+ Also, format PCI product_name as a vector, not a string.
Type: fix
Change-Id: I50c4b44f3570f02518dbd9a43239c1a37612d24a
Signed-off-by: Vratko Polak <vrpolak@cisco.com>
Diffstat (limited to 'src/plugins/rdma/format.c')
-rw-r--r-- | src/plugins/rdma/format.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/rdma/format.c b/src/plugins/rdma/format.c index 78187e9cf17..a999460bd55 100644 --- a/src/plugins/rdma/format.c +++ b/src/plugins/rdma/format.c @@ -122,8 +122,8 @@ format_rdma_device (u8 * s, va_list * args) format_vlib_pci_addr, &rd->pci->addr); if ((d = vlib_pci_get_device_info (vm, &rd->pci->addr, 0))) { - s = format (s, "%Uproduct name: %s\n", format_white_space, indent, - d->product_name ? (char *) d->product_name : ""); + s = format (s, "%Uproduct name: %v\n", format_white_space, indent, + d->product_name); s = format (s, "%Upart number: %U\n", format_white_space, indent, format_vlib_pci_vpd, d->vpd_r, "PN"); s = format (s, "%Urevision: %U\n", format_white_space, indent, |