aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/netmap
diff options
context:
space:
mode:
authorMark Johnston <markj@FreeBSD.org>2024-06-05 14:17:14 +0000
committerMark Johnston <markj@FreeBSD.org>2024-06-16 20:37:26 +0000
commit44d36c9731c172977ad8a95a09c0d6fbddcc9b2f (patch)
tree6ae343048ef6da176568e5cfe7435d4aeede8ad7 /sys/dev/netmap
parent48ef9cff9c2934d8a13eb8624c02050cd8f00595 (diff)
Diffstat (limited to 'sys/dev/netmap')
-rw-r--r--sys/dev/netmap/netmap_freebsd.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/sys/dev/netmap/netmap_freebsd.c b/sys/dev/netmap/netmap_freebsd.c
index a4a0124471c0..cf3578ddc7fe 100644
--- a/sys/dev/netmap/netmap_freebsd.c
+++ b/sys/dev/netmap/netmap_freebsd.c
@@ -864,16 +864,12 @@ nm_os_pt_memdev_iounmap(struct ptnetmap_memdev *ptn_dev)
static int
ptn_memdev_probe(device_t dev)
{
- char desc[256];
-
if (pci_get_vendor(dev) != PTNETMAP_PCI_VENDOR_ID)
return (ENXIO);
if (pci_get_device(dev) != PTNETMAP_PCI_DEVICE_ID)
return (ENXIO);
- snprintf(desc, sizeof(desc), "%s PCI adapter",
- PTNETMAP_MEMDEV_NAME);
- device_set_desc_copy(dev, desc);
+ device_set_descf(dev, "%s PCI adapter", PTNETMAP_MEMDEV_NAME);
return (BUS_PROBE_DEFAULT);
}