git: f70fe58d0a8d - stable/13 - linuxkpi xarray: Correct expression in assertion.

From: John Baldwin <jhb_at_FreeBSD.org>
Date: Wed, 11 May 2022 00:30:07 UTC
The branch stable/13 has been updated by jhb:

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

commit f70fe58d0a8dff309ca477e72dbe07d95f900a35
Author:     John Baldwin <jhb@FreeBSD.org>
AuthorDate: 2022-02-11 21:59:27 +0000
Commit:     John Baldwin <jhb@FreeBSD.org>
CommitDate: 2022-05-11 00:07:41 +0000

    linuxkpi xarray: Correct expression in assertion.
    
    Reported by:    GCC -Wparantheses
    Reviewed by:    wulf, hselasky
    Differential Revision:  https://reviews.freebsd.org/D34197
    
    (cherry picked from commit b0c1600a8c42fc1b2c90714d5fefd3266385225a)
---
 sys/compat/linuxkpi/common/src/linux_xarray.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/sys/compat/linuxkpi/common/src/linux_xarray.c b/sys/compat/linuxkpi/common/src/linux_xarray.c
index c26a2af450e8..a41784103852 100644
--- a/sys/compat/linuxkpi/common/src/linux_xarray.c
+++ b/sys/compat/linuxkpi/common/src/linux_xarray.c
@@ -103,7 +103,7 @@ __xa_alloc(struct xarray *xa, uint32_t *pindex, void *ptr, uint32_t mask, gfp_t
 	XA_ASSERT_LOCKED(xa);
 
 	/* mask should allow to allocate at least one item */
-	MPASS(mask > (xa->flags & XA_FLAGS_ALLOC1) != 0 ? 1 : 0);
+	MPASS(mask > ((xa->flags & XA_FLAGS_ALLOC1) != 0 ? 1 : 0));
 
 	/* mask can be any power of two value minus one */
 	MPASS((mask & (mask + 1)) == 0);
@@ -160,7 +160,7 @@ __xa_alloc_cyclic(struct xarray *xa, uint32_t *pindex, void *ptr, uint32_t mask,
 	XA_ASSERT_LOCKED(xa);
 
 	/* mask should allow to allocate at least one item */
-	MPASS(mask > (xa->flags & XA_FLAGS_ALLOC1) != 0 ? 1 : 0);
+	MPASS(mask > ((xa->flags & XA_FLAGS_ALLOC1) != 0 ? 1 : 0));
 
 	/* mask can be any power of two value minus one */
 	MPASS((mask & (mask + 1)) == 0);