[RFC net-next 05/14] uapi: wireguard: use __*_A_MAX in enums

Asbjørn Sloth Tønnesen <[email protected]>
Newsgroups com.zx2c4.lists.wireguard,org.kernel.vger.linux-kernel,org.kernel.vger.netdev
Message-ID <[email protected]>
This patch renames enum members from __*_A_LAST to __*_A_MAX.

This is an incremental step towards adopting an UAPI header
generated by YNL.

This is a trivial patch with no behavioural changes intended.

Signed-off-by: Asbjørn Sloth Tønnesen <[email protected]>
---
 include/uapi/linux/wireguard.h | 15 +++++++++------
 1 file changed, 9 insertions(+), 6 deletions(-)

diff --git a/include/uapi/linux/wireguard.h b/include/uapi/linux/wireguard.h
index dee4401e0b5d..c2bb2463211a 100644
--- a/include/uapi/linux/wireguard.h
+++ b/include/uapi/linux/wireguard.h
@@ -32,9 +32,10 @@ enum wgdevice_attribute {
 	WGDEVICE_A_LISTEN_PORT,
 	WGDEVICE_A_FWMARK,
 	WGDEVICE_A_PEERS,
-	__WGDEVICE_A_LAST
+
+	__WGDEVICE_A_MAX
 };
-#define WGDEVICE_A_MAX (__WGDEVICE_A_LAST - 1)
+#define WGDEVICE_A_MAX (__WGDEVICE_A_MAX - 1)
 
 enum wgpeer_flag {
 	WGPEER_F_REMOVE_ME = 1U << 0,
@@ -55,9 +56,10 @@ enum wgpeer_attribute {
 	WGPEER_A_TX_BYTES,
 	WGPEER_A_ALLOWEDIPS,
 	WGPEER_A_PROTOCOL_VERSION,
-	__WGPEER_A_LAST
+
+	__WGPEER_A_MAX
 };
-#define WGPEER_A_MAX (__WGPEER_A_LAST - 1)
+#define WGPEER_A_MAX (__WGPEER_A_MAX - 1)
 
 enum wgallowedip_flag {
 	WGALLOWEDIP_F_REMOVE_ME = 1U << 0,
@@ -69,8 +71,9 @@ enum wgallowedip_attribute {
 	WGALLOWEDIP_A_IPADDR,
 	WGALLOWEDIP_A_CIDR_MASK,
 	WGALLOWEDIP_A_FLAGS,
-	__WGALLOWEDIP_A_LAST
+
+	__WGALLOWEDIP_A_MAX
 };
-#define WGALLOWEDIP_A_MAX (__WGALLOWEDIP_A_LAST - 1)
+#define WGALLOWEDIP_A_MAX (__WGALLOWEDIP_A_MAX - 1)
 
 #endif /* _WG_UAPI_WIREGUARD_H */
-- 
2.51.0
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.