The branch main has been updated by dougm: URL: https://cgit.FreeBSD.org/src/commit/?id=08f6f78f81e21b21dd002a9389436b0333cb3488
commit 08f6f78f81e21b21dd002a9389436b0333cb3488 Author: Doug Moore <[email protected]> AuthorDate: 2024-06-03 18:20:00 +0000 Commit: Doug Moore <[email protected]> CommitDate: 2024-06-03 18:22:22 +0000 libkern: don't use MPASS Using MPASS in libkern breaks buildworld. Replace MPASS with KASSERT in three places. --- sys/sys/libkern.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/sys/libkern.h b/sys/sys/libkern.h index 84d982c43a76..afdfe7346b28 100644 --- a/sys/sys/libkern.h +++ b/sys/sys/libkern.h @@ -190,7 +190,7 @@ static __inline __pure2 int ilog2_int(int n) { - MPASS(n != 0); + KASSERT(n != 0, ("ilog argument must be nonzero")); return (8 * sizeof(n) - 1 - __builtin_clz((u_int)n)); } @@ -198,7 +198,7 @@ static __inline __pure2 int ilog2_long(long n) { - MPASS(n != 0); + KASSERT(n != 0, ("ilog argument must be nonzero")); return (8 * sizeof(n) - 1 - __builtin_clzl((u_long)n)); } @@ -206,7 +206,7 @@ static __inline __pure2 int ilog2_long_long(long long n) { - MPASS(n != 0); + KASSERT(n != 0, ("ilog argument must be nonzero")); return (8 * sizeof(n) - 1 - __builtin_clzll((unsigned long long)n)); }
