git: 9f74e5edafdc - stable/14 - bge: Use device_set_descf()
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Thu, 27 Jun 2024 15:31:06 UTC
The branch stable/14 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=9f74e5edafdc91469ab72f4900e46e27cfe72f54 commit 9f74e5edafdc91469ab72f4900e46e27cfe72f54 Author: Mark Johnston <markj@FreeBSD.org> AuthorDate: 2024-06-05 19:23:26 +0000 Commit: Mark Johnston <markj@FreeBSD.org> CommitDate: 2024-06-27 15:27:41 +0000 bge: Use device_set_descf() No functional change intended. MFC after: 1 week (cherry picked from commit 50505c853c6cf1a4e8fac54d20c43f0f91ff0c67) --- sys/dev/bge/if_bge.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/sys/dev/bge/if_bge.c b/sys/dev/bge/if_bge.c index a646ed226d3c..3e43b8e31442 100644 --- a/sys/dev/bge/if_bge.c +++ b/sys/dev/bge/if_bge.c @@ -2699,7 +2699,6 @@ bge_chipid(device_t dev) static int bge_probe(device_t dev) { - char buf[96]; char model[64]; const struct bge_revision *br; const char *pname; @@ -2727,9 +2726,8 @@ bge_probe(device_t dev) br != NULL ? br->br_name : "NetXtreme/NetLink Ethernet Controller"); } - snprintf(buf, sizeof(buf), "%s, %sASIC rev. %#08x", + device_set_descf(dev, "%s, %sASIC rev. %#08x", model, br != NULL ? "" : "unknown ", id); - device_set_desc_copy(dev, buf); return (BUS_PROBE_DEFAULT); } t++;