git: 9d70108a74ef - main - stand: Use bool for stage_offset_set

From: Warner Losh <imp_at_FreeBSD.org>
Date: Sun, 21 Aug 2022 15:49:10 UTC
The branch main has been updated by imp:

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

commit 9d70108a74efe327ed9d1f68bc1e9e271810d94c
Author:     Warner Losh <imp@FreeBSD.org>
AuthorDate: 2022-08-21 15:45:44 +0000
Commit:     Warner Losh <imp@FreeBSD.org>
CommitDate: 2022-08-21 15:48:02 +0000

    stand: Use bool for stage_offset_set
    
    stage_offset_set is a boolean, convert it to a bool.
    
    Sponsored by:           Netflix
---
 stand/efi/loader/copy.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/stand/efi/loader/copy.c b/stand/efi/loader/copy.c
index 78159dfff4e3..5892a790550b 100644
--- a/stand/efi/loader/copy.c
+++ b/stand/efi/loader/copy.c
@@ -200,7 +200,7 @@ out:
 static u_long staging_slop = EFI_STAGING_SLOP;
 
 EFI_PHYSICAL_ADDRESS	staging, staging_end, staging_base;
-int			stage_offset_set = 0;
+bool			stage_offset_set = false;
 ssize_t			stage_offset;
 
 static void
@@ -208,7 +208,7 @@ efi_copy_free(void)
 {
 	BS->FreePages(staging_base, (staging_end - staging_base) /
 	    EFI_PAGE_SIZE);
-	stage_offset_set = 0;
+	stage_offset_set = false;
 	stage_offset = 0;
 }
 
@@ -478,7 +478,7 @@ efi_copyin(const void *src, vm_offset_t dest, const size_t len)
 
 	if (!stage_offset_set) {
 		stage_offset = (vm_offset_t)staging - dest;
-		stage_offset_set = 1;
+		stage_offset_set = true;
 	}
 
 	/* XXX: Callers do not check for failure. */
@@ -509,7 +509,7 @@ efi_readin(readin_handle_t fd, vm_offset_t dest, const size_t len)
 
 	if (!stage_offset_set) {
 		stage_offset = (vm_offset_t)staging - dest;
-		stage_offset_set = 1;
+		stage_offset_set = true;
 	}
 
 	if (!efi_check_space(dest + stage_offset + len)) {