Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 25 Jul 2024 06:47:39 GMT
From:      Alan Cox <alc@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: 98dd639c94f7 - main - arm64 pmap: Eliminate an unnecessary conditional
Message-ID:  <202407250647.46P6ldHN035274@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by alc:

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

commit 98dd639c94f716858ae29958f484729b1d2fd387
Author:     Alan Cox <alc@FreeBSD.org>
AuthorDate: 2024-07-24 22:32:32 +0000
Commit:     Alan Cox <alc@FreeBSD.org>
CommitDate: 2024-07-25 06:46:47 +0000

    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);
 }
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202407250647.46P6ldHN035274>