diff --git a/sys/dev/mvs/mvs.c b/sys/dev/mvs/mvs.c index a98a5925958..253fdc09647 100644 --- a/sys/dev/mvs/mvs.c +++ b/sys/dev/mvs/mvs.c @@ -105,7 +105,7 @@ static int mvs_ch_probe(device_t dev) { - device_set_desc_copy(dev, "Marvell SATA channel"); + device_set_desc(dev, "Marvell SATA channel"); return (BUS_PROBE_DEFAULT); } diff --git a/sys/dev/mvs/mvs_pci.c b/sys/dev/mvs/mvs_pci.c index be9351403a0..1dfd43ae6b1 100644 --- a/sys/dev/mvs/mvs_pci.c +++ b/sys/dev/mvs/mvs_pci.c @@ -77,7 +77,6 @@ static struct { static int mvs_probe(device_t dev) { - char buf[64]; int i; uint32_t devid = pci_get_devid(dev); uint8_t revid = pci_get_revid(dev); @@ -85,9 +84,8 @@ mvs_probe(device_t dev) for (i = 0; mvs_ids[i].id != 0; i++) { if (mvs_ids[i].id == devid && mvs_ids[i].rev <= revid) { - snprintf(buf, sizeof(buf), "%s SATA controller", + device_set_descf(dev, "%s SATA controller", mvs_ids[i].name); - device_set_desc_copy(dev, buf); return (BUS_PROBE_DEFAULT); } } diff --git a/sys/dev/mvs/mvs_soc.c b/sys/dev/mvs/mvs_soc.c index 696b65d5435..00a868140a0 100644 --- a/sys/dev/mvs/mvs_soc.c +++ b/sys/dev/mvs/mvs_soc.c @@ -74,7 +74,6 @@ static struct { static int mvs_probe(device_t dev) { - char buf[64]; int i; uint32_t devid, revid; @@ -88,9 +87,8 @@ mvs_probe(device_t dev) for (i = 0; mvs_ids[i].id != 0; i++) { if (mvs_ids[i].id == devid && mvs_ids[i].rev <= revid) { - snprintf(buf, sizeof(buf), "%s SATA controller", + device_set_descf(dev, "%s SATA controller", mvs_ids[i].name); - device_set_desc_copy(dev, buf); return (BUS_PROBE_DEFAULT); } }