Module Name:    src
Committed By:   yamaguchi
Date:           Fri Apr  5 06:05:37 UTC 2024

Modified Files:
        src/sys/net/lagg: if_lagg.c

Log Message:
lagg(4): added __predict_true


To generate a diff of this commit:
cvs rdiff -u -r1.67 -r1.68 src/sys/net/lagg/if_lagg.c

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

Modified files:

Index: src/sys/net/lagg/if_lagg.c
diff -u src/sys/net/lagg/if_lagg.c:1.67 src/sys/net/lagg/if_lagg.c:1.68
--- src/sys/net/lagg/if_lagg.c:1.67	Thu Apr  4 09:19:42 2024
+++ src/sys/net/lagg/if_lagg.c	Fri Apr  5 06:05:37 2024
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_lagg.c,v 1.67 2024/04/04 09:19:42 yamaguchi Exp $	*/
+/*	$NetBSD: if_lagg.c,v 1.68 2024/04/05 06:05:37 yamaguchi Exp $	*/
 
 /*
  * Copyright (c) 2005, 2006 Reyk Floeter <r...@openbsd.org>
@@ -20,7 +20,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_lagg.c,v 1.67 2024/04/04 09:19:42 yamaguchi Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_lagg.c,v 1.68 2024/04/05 06:05:37 yamaguchi Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_inet.h"
@@ -3010,7 +3010,7 @@ lagg_chg_sadl(struct ifnet *ifp, const u
 	}
 
 	/* Activate the next Link-Level address */
-	if (ifa_next != ifp->if_dl) {
+	if (__predict_true(ifa_next != ifp->if_dl)) {
 		/* save the current address */
 		ifa_cur = ifp->if_dl;
 		if (ifa_cur != NULL)

Reply via email to