From 98dd639c94f716858ae29958f484729b1d2fd387 Mon Sep 17 00:00:00 2001 From: Alan Cox Date: Wed, 24 Jul 2024 17:32:32 -0500 Subject: [PATCH] arm64 pmap: Eliminate an unnecessary conditional Eliminate an unnecessary test whether a pointer is non-NULL from pmap_bti_same(). Reviewed by: dougm --- sys/arm64/arm64/pmap.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sys/arm64/arm64/pmap.c b/sys/arm64/arm64/pmap.c index 2540b5eaf4b9..59de6ef37f09 100644 --- a/sys/arm64/arm64/pmap.c +++ b/sys/arm64/arm64/pmap.c @@ -9396,8 +9396,7 @@ pmap_bti_same(pmap_t pmap, vm_offset_t sva, vm_offset_t eva, pt_entry_t *pte) return (false); rs = next_rs; } - if (rs != NULL) - *pte |= ATTR_S1_GP; + *pte |= ATTR_S1_GP; return (true); }