[PATCH] powerpc/boot: Use the compiler's stdbool.h

From: Thorsten Blum

Date: Mon Nov 16 2026 - 15:44:48 EST


Commit c762c69e106f ("powerpc/boot: Add support for XZ compression")
added custom boolean definitions to types.h and a local stdbool.h that
only includes types.h.

However, the boot wrapper already adds the compiler's header directory
to the include path. Remove the local header and the custom boolean
definitions so the existing include in types.h uses the compiler's
stdbool.h instead.

This changes bool from int to _Bool and its size from 4 bytes to 1 byte.

Signed-off-by: Thorsten Blum <blum@xxxxxxxxxx>
---
This patch applies on top of:
https://lore.kernel.org/r/20260828130622.576064-3-blum@xxxxxxxxxx/

arch/powerpc/boot/stdbool.h | 9 ---------
arch/powerpc/boot/types.h | 9 ---------
2 files changed, 18 deletions(-)
delete mode 100644 arch/powerpc/boot/stdbool.h

diff --git a/arch/powerpc/boot/stdbool.h b/arch/powerpc/boot/stdbool.h
deleted file mode 100644
index 2dfe247ede80..000000000000
--- a/arch/powerpc/boot/stdbool.h
+++ /dev/null
@@ -1,9 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0-or-later */
-/*
- * Copyright (C) IBM Corporation 2016.
- *
- * This file is only necessary because some of the pre-boot decompressors
- * expect stdbool.h to be available.
- */
-
-#include "types.h"
diff --git a/arch/powerpc/boot/types.h b/arch/powerpc/boot/types.h
index c5085c2632bf..08529138c524 100644
--- a/arch/powerpc/boot/types.h
+++ b/arch/powerpc/boot/types.h
@@ -37,13 +37,4 @@ typedef s64 int64_t;
(void) (&_x == &_y); \
_x > _y ? _x : _y; })

-typedef int bool;
-
-#ifndef true
-#define true 1
-#endif
-
-#ifndef false
-#define false 0
-#endif
#endif /* _TYPES_H_ */

base-commit: aebb7274476403040d582c61478df8f4a7bf9cd3
prerequisite-patch-id: 068c3f1381513a18034f0a88224c0bf37db8cfa3