Module Name:    src
Committed By:   christos
Date:           Tue Feb 25 22:11:37 UTC 2025

Modified Files:
        src/sbin/efi: devpath3.c devpath4.c showvar.c utils.c

Log Message:
fix the build


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sbin/efi/devpath3.c src/sbin/efi/devpath4.c
cvs rdiff -u -r1.1 -r1.2 src/sbin/efi/showvar.c src/sbin/efi/utils.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sbin/efi/devpath3.c
diff -u src/sbin/efi/devpath3.c:1.2 src/sbin/efi/devpath3.c:1.3
--- src/sbin/efi/devpath3.c:1.2	Mon Feb 24 10:42:05 2025
+++ src/sbin/efi/devpath3.c	Tue Feb 25 17:11:36 2025
@@ -1,4 +1,4 @@
-/* $NetBSD: devpath3.c,v 1.2 2025/02/24 15:42:05 martin Exp $ */
+/* $NetBSD: devpath3.c,v 1.3 2025/02/25 22:11:36 christos Exp $ */
 
 /*
  * Redistribution and use in source and binary forms, with or without
@@ -25,7 +25,7 @@
 
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: devpath3.c,v 1.2 2025/02/24 15:42:05 martin Exp $");
+__RCSID("$NetBSD: devpath3.c,v 1.3 2025/02/25 22:11:36 christos Exp $");
 #endif /* not lint */
 
 #include <arpa/inet.h>
@@ -60,25 +60,25 @@ GUID= d487ddb4-008b-11d9-afdc-001083ffca
 
 /* Used in sub-type 10 */
 #define EFI_PC_ANSI_GUID\
-  ((uuid_t){0xe0c14753,0xf9be,0x11d2,0x9a,0x0c,{0x00,0x90,0x27,0x3f,0xc1,0x4d}})
+  {0xe0c14753,0xf9be,0x11d2,0x9a,0x0c,{0x00,0x90,0x27,0x3f,0xc1,0x4d}}
 
 #define EFI_VT_100_GUID\
-  ((uuid_t){0xdfa66065,0xb419,0x11d3,0x9a,0x2d,{0x00,0x90,0x27,0x3f,0xc1,0x4d}})
+  {0xdfa66065,0xb419,0x11d3,0x9a,0x2d,{0x00,0x90,0x27,0x3f,0xc1,0x4d}}
 
 #define EFI_VT_100_PLUS_GUID\
-  ((uuid_t){0x7baec70b,0x57e0,0x4c76,0x8e,0x87,{0x2f,0x9e,0x28,0x08,0x83,0x43}})
+  {0x7baec70b,0x57e0,0x4c76,0x8e,0x87,{0x2f,0x9e,0x28,0x08,0x83,0x43}}
 
 #define EFI_VT_UTF8_GUID\
-  ((uuid_t){0xad15a0d6,0x8bec,0x4acf,0xa0,0x73,{0xd0,0x1d,0xe7,0x7e,0x2d,0x88}})
+  {0xad15a0d6,0x8bec,0x4acf,0xa0,0x73,{0xd0,0x1d,0xe7,0x7e,0x2d,0x88}}
 
 #define EFI_DEBUGPORT_PROTOCOL_GUID \
-  ((uuid_t){0xeba4e8d2,0x3858,0x41ec,0xa2,0x81,{0x26,0x47,0xba,0x96,0x60,0xd0}})
+  {0xeba4e8d2,0x3858,0x41ec,0xa2,0x81,{0x26,0x47,0xba,0x96,0x60,0xd0}}
 
 #define DEVICE_PATH_MESSAGING_UART_FLOW_CONTROL \
-  ((uuid_t){0x37499a9d,0x542f,0x4c89,0xa0,0x26,{0x35,0xda,0x14,0x20,0x94,0xe4}})
+  {0x37499a9d,0x542f,0x4c89,0xa0,0x26,{0x35,0xda,0x14,0x20,0x94,0xe4}}
 
 #define EFI_VENDOR_SAS\
-  ((uuid_t){0xd487ddb4,0x008b,0x11d9,0xaf,0xdc,{0x00,0x10,0x83,0xff,0xca,0x4d}})
+  {0xd487ddb4,0x008b,0x11d9,0xaf,0xdc,{0x00,0x10,0x83,0xff,0xca,0x4d}}
 
 /************************************************************************/
 
Index: src/sbin/efi/devpath4.c
diff -u src/sbin/efi/devpath4.c:1.2 src/sbin/efi/devpath4.c:1.3
--- src/sbin/efi/devpath4.c:1.2	Mon Feb 24 10:42:05 2025
+++ src/sbin/efi/devpath4.c	Tue Feb 25 17:11:36 2025
@@ -1,4 +1,4 @@
-/* $NetBSD: devpath4.c,v 1.2 2025/02/24 15:42:05 martin Exp $ */
+/* $NetBSD: devpath4.c,v 1.3 2025/02/25 22:11:36 christos Exp $ */
 
 /*
  * Redistribution and use in source and binary forms, with or without
@@ -25,7 +25,7 @@
 
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: devpath4.c,v 1.2 2025/02/24 15:42:05 martin Exp $");
+__RCSID("$NetBSD: devpath4.c,v 1.3 2025/02/25 22:11:36 christos Exp $");
 #endif /* not lint */
 
 #include <sys/uuid.h>
@@ -43,20 +43,16 @@ __RCSID("$NetBSD: devpath4.c,v 1.2 2025/
 #define easprintf	(size_t)easprintf
 
 #define EFI_VIRTUAL_DISK_GUID \
-	((uuid_t){0x77AB535A,0x45FC,0x624B,0x55,0x60,\
-	  {0xF7,0xB2,0x81,0xD1,0xF9,0x6E}})
+    {0x77AB535A,0x45FC,0x624B,0x55,0x60,{0xF7,0xB2,0x81,0xD1,0xF9,0x6E}}
 
 #define EFI_VIRTUAL_CD_GUID \
-	((uuid_t){0x3D5ABD30,0x4175,0x87CE,0x6D,0x64,\
-	  {0xD2,0xAD,0xE5,0x23,0xC4,0xBB}})
+    {0x3D5ABD30,0x4175,0x87CE,0x6D,0x64,{0xD2,0xAD,0xE5,0x23,0xC4,0xBB}}
 
 #define EFI_PERSISTENT_VIRTUAL_DISK_GUID \
-	((uuid_t){0x5CEA02C9,0x4D07,0x69D3,0x26,0x9F,\
-	  {0x44,0x96,0xFB,0xE0,0x96,0xF9}})
+    {0x5CEA02C9,0x4D07,0x69D3,0x26,0x9F,{0x44,0x96,0xFB,0xE0,0x96,0xF9}}
 
 #define EFI_PERSISTENT_VIRTUAL_CD_GUID \
-	((uuid_t){0x08018188,0x42CD,0xBB48,0x10,0x0F,\
-	  {0x53,0x87,0xD5,0x3D,0xED,0x3D }})
+    {0x08018188,0x42CD,0xBB48,0x10,0x0F,{0x53,0x87,0xD5,0x3D,0xED,0x3D}}
 
 /************************************************************************
  * Type 4 - Media Device Path

Index: src/sbin/efi/showvar.c
diff -u src/sbin/efi/showvar.c:1.1 src/sbin/efi/showvar.c:1.2
--- src/sbin/efi/showvar.c:1.1	Mon Feb 24 08:47:57 2025
+++ src/sbin/efi/showvar.c	Tue Feb 25 17:11:36 2025
@@ -1,4 +1,4 @@
-/* $NetBSD: showvar.c,v 1.1 2025/02/24 13:47:57 christos Exp $ */
+/* $NetBSD: showvar.c,v 1.2 2025/02/25 22:11:36 christos Exp $ */
 
 /*
  * Redistribution and use in source and binary forms, with or without
@@ -25,7 +25,7 @@
 
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: showvar.c,v 1.1 2025/02/24 13:47:57 christos Exp $");
+__RCSID("$NetBSD: showvar.c,v 1.2 2025/02/25 22:11:36 christos Exp $");
 #endif /* not lint */
 
 #include <sys/efiio.h>
@@ -110,8 +110,7 @@ show_filelist_data(efi_var_t *v, bool db
 }
 
 static int
-/*###113 [lint] warning parameter 'dbg' unused in function 'show_asciiz_data' [231]%%%*/
-show_asciiz_data(efi_var_t *v, bool dbg)
+show_asciiz_data(efi_var_t *v, bool dbg __unused)
 {
 	char *cp, *ep;
 
@@ -128,8 +127,7 @@ show_asciiz_data(efi_var_t *v, bool dbg)
 }
 
 static int
-/*###130 [lint] warning parameter 'dbg' unused in function 'show_array8_data' [231]%%%*/
-show_array8_data(efi_var_t *v, bool dbg)
+show_array8_data(efi_var_t *v, bool dbg __unused)
 {
 	size_t cnt, i;
 	uint8_t *array = v->ev.data;
@@ -150,8 +148,7 @@ show_array8_data(efi_var_t *v, bool dbg)
 }
 
 static int
-/*###151 [lint] warning parameter 'dbg' unused in function 'show_array16_data' [231]%%%*/
-show_array16_data(efi_var_t *v, bool dbg)
+show_array16_data(efi_var_t *v, bool dbg __unused)
 {
 	size_t cnt, i;
 	uint16_t *array = v->ev.data;
@@ -317,8 +314,7 @@ format_optional_data(char *od, size_t sz
 
 	for (i = 0; i < sz; i++) {
 		char c = od[i];
-/*###317 [lint] warning argument to 'function from <ctype.h>' must be cast to 'unsigned char', not to 'int' [342]%%%*/
-		bp[i] = isprint((int)c) ? c : '.';
+		bp[i] = isprint((unsigned char)c) ? c : '.';
 	}
 	bp[i] = '\0';
 	return bp;
@@ -408,8 +404,7 @@ show_boot_data(efi_var_t *v, int debug, 
 /************************************************************************/
 
 static int
-/*###407 [lint] warning parameter 'dbg' unused in function 'show_OsIndications_data' [231]%%%*/
-show_OsIndications_data(efi_var_t *e, bool dbg)
+show_OsIndications_data(efi_var_t *e, bool dbg __unused)
 {
 	uint64_t OsIndications;
 	char buf[256];
@@ -422,8 +417,7 @@ show_OsIndications_data(efi_var_t *e, bo
 }
 
 static int
-/*###420 [lint] warning parameter 'dbg' unused in function 'show_BootOptionSupport_data' [231]%%%*/
-show_BootOptionSupport_data(efi_var_t *e, bool dbg)
+show_BootOptionSupport_data(efi_var_t *e, bool dbg __unused)
 {
 	uint32_t boot_option_support;
 	char buf[256];
@@ -437,8 +431,7 @@ show_BootOptionSupport_data(efi_var_t *e
 }
 
 static int
-/*###434 [lint] warning parameter 'dbg' unused in function 'show_Timeout_data' [231]%%%*/
-show_Timeout_data(efi_var_t *e, bool dbg)
+show_Timeout_data(efi_var_t *e, bool dbg __unused)
 {
 	uint16_t *timeout = e->ev.data;
 
Index: src/sbin/efi/utils.c
diff -u src/sbin/efi/utils.c:1.1 src/sbin/efi/utils.c:1.2
--- src/sbin/efi/utils.c:1.1	Mon Feb 24 08:47:57 2025
+++ src/sbin/efi/utils.c	Tue Feb 25 17:11:36 2025
@@ -1,4 +1,4 @@
-/* $NetBSD: utils.c,v 1.1 2025/02/24 13:47:57 christos Exp $ */
+/* $NetBSD: utils.c,v 1.2 2025/02/25 22:11:36 christos Exp $ */
 
 /*
  * Redistribution and use in source and binary forms, with or without
@@ -25,7 +25,7 @@
 
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: utils.c,v 1.1 2025/02/24 13:47:57 christos Exp $");
+__RCSID("$NetBSD: utils.c,v 1.2 2025/02/25 22:11:36 christos Exp $");
 #endif /* not lint */
 
 #include <sys/uuid.h>
@@ -375,9 +375,7 @@ strtous(const char *str, char **endptr, 
 
 	switch (rstatus) {
 	case EINVAL:
-/*###378 [lint] warning constant in conditional context [161]%%%*/
 		assert(0);
-/*###379 [lint] warning 'break' statement not reached [193]%%%*/
 		break;
 	case ENOTSUP:
 		if (endptr != NULL)

Reply via email to