mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Thorsten Blum <blum@kernel.org>
To: Madhavan Srinivasan <maddy@linux.ibm.com>,
	Michael Ellerman <mpe@ellerman.id.au>,
	Nicholas Piggin <npiggin@gmail.com>,
	"Christophe Leroy (CS GROUP)" <chleroy@kernel.org>,
	"Ritesh Harjani (IBM)" <ritesh.list@gmail.com>,
	Shrikanth Hegde <sshegde@linux.ibm.com>
Cc: Thorsten Blum <blum@kernel.org>,
	linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org
Subject: [PATCH] powerpc/boot: Use the compiler's stdbool.h
Date: Mon, 16 Nov 2026 21:44:29 +0100	[thread overview]
Message-ID: <20261116204433.420205-2-blum@kernel.org> (raw)

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@kernel.org>
---
This patch applies on top of:
https://lore.kernel.org/r/20260828130622.576064-3-blum@kernel.org/

 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

                 reply	other threads:[~2026-11-16 20:44 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261116204433.420205-2-blum@kernel.org \
    --to=blum@kernel.org \
    --cc=chleroy@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=maddy@linux.ibm.com \
    --cc=mpe@ellerman.id.au \
    --cc=npiggin@gmail.com \
    --cc=ritesh.list@gmail.com \
    --cc=sshegde@linux.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®