git: 794e20f8071e - stable/14 - tools/sdiodevs2h.awk: adjust defined named for vendor and device IDs

From: Bjoern A. Zeeb <bz_at_FreeBSD.org>
Date: Wed, 09 Oct 2024 23:13:44 UTC
The branch stable/14 has been updated by bz:

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

commit 794e20f8071e434ac4f72033264ab493bf1ea94e
Author:     Bjoern A. Zeeb <bz@FreeBSD.org>
AuthorDate: 2024-08-27 18:35:49 +0000
Commit:     Bjoern A. Zeeb <bz@FreeBSD.org>
CommitDate: 2024-10-09 19:18:28 +0000

    tools/sdiodevs2h.awk: adjust defined named for vendor and device IDs
    
    Generate defined names which match the ones in the Linux drivers (a lot more);
    given we are likely to have drivers only based on those one way or another
    there is absolutely no reason to fight over differently generated names
    for device and vendor IDs.
    
    Sponsored by:   The FreeBSD Foundation
    Reviewed by:    imp
    Differential Revision: https://reviews.freebsd.org/D46300
    
    (cherry picked from commit 51cb6f5244575e1abc008598e90eb35452ffbcac)
---
 sys/tools/sdiodevs2h.awk | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/sys/tools/sdiodevs2h.awk b/sys/tools/sdiodevs2h.awk
index 818bdef58762..596d09531ab1 100644
--- a/sys/tools/sdiodevs2h.awk
+++ b/sys/tools/sdiodevs2h.awk
@@ -55,7 +55,7 @@ function vendor(hfile)
 	vendors[nvendors, 1] = $2;		# name
 	vendors[nvendors, 2] = $3;		# id
 	if (hfile)
-		printf("#define\tSDIO_VENDOR_%s\t%s\t", vendors[nvendors, 1],
+		printf("#define\tSDIO_VENDOR_ID_%s\t%s\t", vendors[nvendors, 1],
 		    vendors[nvendors, 2]) > hfile
 	i = 3; f = 4;
 
@@ -105,7 +105,7 @@ function product(hfile)
 	products[nproducts, 2] = $3;		# product id
 	products[nproducts, 3] = $4;		# id
 	if (hfile)
-		printf("#define\tSDIO_PRODUCT_%s_%s\t%s\t", \
+		printf("#define\tSDIO_DEVICE_ID_%s_%s\t%s\t", \
 		  products[nproducts, 1], products[nproducts, 2], \
 		  products[nproducts, 3]) > hfile
 
@@ -155,7 +155,7 @@ function dump_dfile(dfile)
 	printf("const struct sdio_knowndev sdio_knowndevs[] = {\n") > dfile
 	for (i = 1; i <= nproducts; i++) {
 		printf("\t{\n") > dfile
-		printf("\t    SDIO_VENDOR_%s, SDIO_PRODUCT_%s_%s,\n",
+		printf("\t    SDIO_VENDOR_ID_%s, SDIO_DEVICE_ID_%s_%s,\n",
 		    products[i, 1], products[i, 1], products[i, 2]) > dfile
 		printf("\t    ") > dfile
 		printf("0") > dfile
@@ -189,7 +189,7 @@ function dump_dfile(dfile)
 	}
 	for (i = 1; i <= nvendors; i++) {
 		printf("\t{\n") > dfile
-		printf("\t    SDIO_VENDOR_%s, 0,\n", vendors[i, 1]) > dfile
+		printf("\t    SDIO_VENDOR_ID_%s, 0,\n", vendors[i, 1]) > dfile
 		printf("\t    SDIO_KNOWNDEV_NOPROD,\n") > dfile
 		printf("\t    \"") > dfile
 		j = 3;