From patchwork Sat Jan 10 20:28:38 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1452 Return-Path: X-Original-To: u-boot-concept@u-boot.org Delivered-To: u-boot-concept@u-boot.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1768076991; bh=WUKplOR4Ao5Oshhx/7Jd0OlB0IazMc8e68nHqAh9x+I=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=BoaOsX7dDjDLu/iODhGFhstUWgHz35y+DNpaQ7jkCmKOu8skV7hws+NYBGaOuDd8x jx7zb2d/oml8yxZGYZRDlljoHHPt0uThL46oXf9gXrAHJPreSJ/Da1N24Q8TovLQ7Q qhE9cjH95FdfTKJXZuqwOrfmBRYi5c58NGDuHf09oMQpUNAKIkwoTI16pEyiEPk15a EjBFWqnJUZNku9n6rDLqTRuohd2OLyS297gBIhz28TbtR3EotV0fueTV+wUdavma3g +28t5pVsssy4f0lee5cXKdP5VE56ihfZVcQarn8fqejtWZW4z1bjpqf028VcXqqQjT 3Tl5ZdJcW3Emg== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 03B7769291 for ; Sat, 10 Jan 2026 13:29:51 -0700 (MST) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10024) with ESMTP id 5i9TcOQXbpcT for ; Sat, 10 Jan 2026 13:29:50 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1768076990; bh=WUKplOR4Ao5Oshhx/7Jd0OlB0IazMc8e68nHqAh9x+I=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=Nk855ToNFKbxW1RMYFqERp/KLAGz9M5pOMH9k18FbO2wC/DHTcbHtyAjWSZbN2eaa g+sEHOvdpFWi5n7gXt+m2qmsEFsAxhlWxi6HBQamVtPiq3ueGdbd1V9xjt/2IIZeC5 g2N4n92bVxm524OSkME6m3iLfBLxSQ/819rW4XdrySMsOnBkiir80/Hc3HQVNlNGwU Ci9na5bIRmDalufd0Ig3rFGF1XnEf/RG9K6q00JQigqJORSEPT38eVoVO/MKIz0FT8 SN7MRSoN9dunvcVFT45M30E3z+viu6cQCvPylqrPjcURlC6TgiizJbZoqVX4SgtmoJ vm+vZ3osRRgeQ== Received: from mail.u-boot.org (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id E348F69281 for ; Sat, 10 Jan 2026 13:29:50 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1768076988; bh=8pOqCJK5mBONuhlSyhQkPgZZnUT9dLJVLyRVo2+VC7c=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=AtTiUWD19IJ9rdBabL45Rz/ytYAYailW08FJ8ZcqwAUlqI3XjUGiphYulRvsaoZAd PcOPhOUJV1n4UoTMRrsPEPUH8ZlJoB5VXOthbkNczn8INyKJDBTzm2WhFYBEE6H9Vd P8VvnoBBXcLN8RLJZucqTcY+mrps6HoA+sZLL86ChMPPxyqKGlMnaRhvHcydo7f8XI t6Glnx1T778arqUBpyKDPcsQHjc00Swwhkl7hFtlXG7saWKmS7PTrnzk7ROwqMDkWL VERg4wILhA7JrWvBztKwCkQcQs1PuJl4LXaGOAVnMvYSpXJZ+WZ0vT+cVX+5d4o00d +PjMLm7c3/f/g== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id DF2E869186; Sat, 10 Jan 2026 13:29:48 -0700 (MST) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10026) with ESMTP id fV2y1yQpA38M; Sat, 10 Jan 2026 13:29:48 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1768076984; bh=vCHtCFJBjhZHg49apV6IgEce9NcseyGNaPrqiF6+vEI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ZagjuLdStHUa1UKIj4zkAu7zsfykim535y62MOJmlgfsGDJtLvhc3IggFI3PVk0QN y6Ouo6BBvg854afAx6ikLAUGazSR4xC3xtylUMGNsQdNtMZOFTF9Nk5jekqZ0JK9O6 hQ/4BmZRZFTAQOOkl7fWvbRhM6JNzFDyM0Wl0mj0HDZkPLi72Bz2fAf+LAR7B6BAN1 hwS9zdEoOaHOOS4PBnCnIKeeA723qTr+fmlxejMH5sAgMXP66ti52UGe1FvOnCgKrc SgfnyCuErMTqnCxvm++RJGGSYX3SrACIqgh/9OaMy1o6fb0ByaHA24gurTu7KvDDut 03QIBkuv3RSKg== Received: from u-boot.org (unknown [73.34.74.121]) by mail.u-boot.org (Postfix) with ESMTPSA id 70D756927E; Sat, 10 Jan 2026 13:29:44 -0700 (MST) From: Simon Glass To: U-Boot Concept Date: Sat, 10 Jan 2026 13:28:38 -0700 Message-ID: <20260110202906.187370-7-sjg@u-boot.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20260110202906.187370-1-sjg@u-boot.org> References: <20260110202906.187370-1-sjg@u-boot.org> MIME-Version: 1.0 Message-ID-Hash: LFXV2L4QPF2NYRJBEZRD7LRIVF6NRCLR X-Message-ID-Hash: LFXV2L4QPF2NYRJBEZRD7LRIVF6NRCLR X-MailFrom: sjg@u-boot.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Heinrich Schuchardt , Simon Glass , "Claude Opus 4 . 5" X-Mailman-Version: 3.3.10 Precedence: list Subject: [Concept] [PATCH 06/26] boot: pxe: Make pxe_prepare() static and document it List-Id: Discussion and patches related to U-Boot Concept Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: Simon Glass This function is only used within pxe_utils.c so make it static. Add documentation while we are here. Co-developed-by: Claude Opus 4.5 Signed-off-by: Simon Glass --- boot/pxe_utils.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/boot/pxe_utils.c b/boot/pxe_utils.c index 9444effbb6a..b55d736beb8 100644 --- a/boot/pxe_utils.c +++ b/boot/pxe_utils.c @@ -1282,8 +1282,18 @@ void pxe_destroy_ctx(struct pxe_context *ctx) free(ctx->bootdir); } -struct pxe_menu *pxe_prepare(struct pxe_context *ctx, ulong pxefile_addr_r, - bool prompt) +/** + * pxe_prepare() - Prepare a PXE menu by parsing and processing includes + * + * Parses the PXE config file and processes any include directives. + * + * @ctx: PXE context + * @pxefile_addr_r: Address where config file is loaded + * @prompt: true to force the menu prompt + * Return: Parsed menu on success, NULL on error + */ +static struct pxe_menu *pxe_prepare(struct pxe_context *ctx, + ulong pxefile_addr_r, bool prompt) { struct pxe_menu *cfg; int ret;