git: aebd6d5b1fc4 - stable/14 - arcmsr: Use device_set_descf()

From: Mark Johnston <markj_at_FreeBSD.org>
Date: Thu, 27 Jun 2024 15:30:54 UTC
The branch stable/14 has been updated by markj:

URL: https://cgit.FreeBSD.org/src/commit/?id=aebd6d5b1fc43826fe688d0ea1b6fd4cd11492b7

commit aebd6d5b1fc43826fe688d0ea1b6fd4cd11492b7
Author:     Mark Johnston <markj@FreeBSD.org>
AuthorDate: 2024-06-05 14:13:26 +0000
Commit:     Mark Johnston <markj@FreeBSD.org>
CommitDate: 2024-06-27 15:27:41 +0000

    arcmsr: Use device_set_descf()
    
    No functional change intended.
    
    MFC after:      1 week
    
    (cherry picked from commit 4f0ff49fee00dee624e13b2d305cf9dfee395b7d)
---
 sys/dev/arcmsr/arcmsr.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/sys/dev/arcmsr/arcmsr.c b/sys/dev/arcmsr/arcmsr.c
index ea37da30db93..6de4372a67ea 100644
--- a/sys/dev/arcmsr/arcmsr.c
+++ b/sys/dev/arcmsr/arcmsr.c
@@ -5238,7 +5238,6 @@ static int arcmsr_probe(device_t dev)
 {
 	u_int32_t id;
 	u_int16_t sub_device_id;
-	static char buf[256];
 	char x_type[]={"unknown"};
 	char *type;
 	int raid6 = 1;
@@ -5313,9 +5312,8 @@ static int arcmsr_probe(device_t dev)
 	}
 	if(type == x_type)
 		return(ENXIO);
-	sprintf(buf, "Areca %s Host Adapter RAID Controller %s\n%s\n",
-		type, raid6 ? "(RAID6 capable)" : "", ARCMSR_DRIVER_VERSION);
-	device_set_desc_copy(dev, buf);
+	device_set_descf(dev, "Areca %s Host Adapter RAID Controller %s\n%s\n",
+	    type, raid6 ? "(RAID6 capable)" : "", ARCMSR_DRIVER_VERSION);
 	return (BUS_PROBE_DEFAULT);
 }
 /*