Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 27 Jun 2024 15:30:57 GMT
From:      Mark Johnston <markj@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: b8ddd59d9d16 - stable/14 - amdsmn: Use device_set_descf()
Message-ID:  <202406271530.45RFUvBi078496@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch stable/14 has been updated by markj:

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

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

    amdsmn: Use device_set_descf()
    
    No functional change intended.
    
    MFC after:      1 week
    
    (cherry picked from commit 48ef9cff9c2934d8a13eb8624c02050cd8f00595)
---
 sys/dev/amdsmn/amdsmn.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/sys/dev/amdsmn/amdsmn.c b/sys/dev/amdsmn/amdsmn.c
index 36e3c5a5cae7..5af8d9aca7bd 100644
--- a/sys/dev/amdsmn/amdsmn.c
+++ b/sys/dev/amdsmn/amdsmn.c
@@ -186,7 +186,6 @@ static int
 amdsmn_probe(device_t dev)
 {
 	uint32_t family;
-	char buf[64];
 
 	if (resource_disabled("amdsmn", 0))
 		return (ENXIO);
@@ -203,9 +202,8 @@ amdsmn_probe(device_t dev)
 	default:
 		return (ENXIO);
 	}
-	snprintf(buf, sizeof(buf), "AMD Family %xh System Management Network",
+	device_set_descf(dev, "AMD Family %xh System Management Network",
 	    family);
-	device_set_desc_copy(dev, buf);
 
 	return (BUS_PROBE_GENERIC);
 }



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202406271530.45RFUvBi078496>