From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 19D24C433EF for ; Tue, 12 Oct 2021 09:45:24 +0000 (UTC) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 7601F60295 for ; Tue, 12 Oct 2021 09:45:23 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 7601F60295 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=arm.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 8F44B83436; Tue, 12 Oct 2021 11:45:20 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=fail (p=none dis=none) header.from=arm.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Received: by phobos.denx.de (Postfix, from userid 109) id 8B2C483476; Tue, 12 Oct 2021 11:45:18 +0200 (CEST) Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by phobos.denx.de (Postfix) with ESMTP id DC95D83305 for ; Tue, 12 Oct 2021 11:45:14 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=vincent.stehle@arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 0539C101E; Tue, 12 Oct 2021 02:45:14 -0700 (PDT) Received: from debian (unknown [10.57.46.108]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 2642A3F694; Tue, 12 Oct 2021 02:45:11 -0700 (PDT) Date: Tue, 12 Oct 2021 11:45:07 +0200 From: Vincent =?utf-8?Q?Stehl=C3=A9?= To: Ilias Apalodimas Cc: xypron.glpk@gmx.de, ardb@kernel.org, Alexander Graf , u-boot@lists.denx.de Subject: Re: [PATCH] efi_loader: Fix loaded image alignment Message-ID: References: <20211011121023.110372-1-ilias.apalodimas@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20211011121023.110372-1-ilias.apalodimas@linaro.org> X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean On Mon, Oct 11, 2021 at 03:10:23PM +0300, Ilias Apalodimas wrote: > We are ignoring the alignment communicated via the PE/COFF header. > Starting 5.10 the Linux kernel will loudly complain about it. For more > details look at [1] (in linux kernel). > > So add a function that can allocate aligned EFI memory and use it for our > relocated loaded image. Hi Ilias, Thank you for this fix. I verified that Linux v5.14.3 EFI stub complains about not being aligned to 64k without this fix and is happy with it, on the following systems: - qemu with U-Boot latest (after v2021.10) - Pine64 ROCKPro64 with U-Boot "near" v2021.07[1] - Lenovo Leez P710 with U-Boot v2021.07[2] - Compulab IOT-GATE-iMX8 with U-Boot "near" v2021.10-rc3[3] Feel free to add (or not): Tested-by: Vincent Stehlé Best regards, Vincent Stehlé System Architect - Arm [1]: https://gitlab.arm.com/systemready/firmware-build/rk3399-manifest/-/blob/rockpro64-21.09/README.md [2]: https://gitlab.arm.com/systemready/firmware-build/rk3399-manifest/-/blob/leez-21.08/README.md [3]: https://git.linaro.org/people/paul.liu/systemready/build-scripts.git/tree/docs/iotgateimx8_building_running.md