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 X-Spam-Level: X-Spam-Status: No, score=-1.1 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id F168BC2BA83 for ; Thu, 13 Feb 2020 17:13:13 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id BFB7F206DB for ; Thu, 13 Feb 2020 17:13:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1581613993; bh=l56qEB9k44eSpvcs/9db1OGeL5hy9h6oE3gaJUII1rg=; h=References:In-Reply-To:From:Date:Subject:To:Cc:List-ID:From; b=mSuaOHrDuxLSjHmK7s7Z1cyEnVPjidfp6MJat6BGsmUPPk57Bir+LKmwh4nCEC5y0 4B6/vEV0fIIyWWXSdvrMoQT1ZOsqR4TXuJleYKkvblhi7jrLP2Jui8ZPf+CKNQhi4M dBRXiLNI8cxcxd416K97SjgyKpZUaEIaBjyURLe0= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727781AbgBMRNN (ORCPT ); Thu, 13 Feb 2020 12:13:13 -0500 Received: from mail.kernel.org ([198.145.29.99]:33174 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727658AbgBMRNN (ORCPT ); Thu, 13 Feb 2020 12:13:13 -0500 Received: from mail-wr1-f47.google.com (mail-wr1-f47.google.com [209.85.221.47]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id B2D4D24670 for ; Thu, 13 Feb 2020 17:13:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1581613993; bh=l56qEB9k44eSpvcs/9db1OGeL5hy9h6oE3gaJUII1rg=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=PGJl0ZsOHuUXBA+DysErbQ8+43epyDksEZdXWC3xdLBYB67KYpuknKqxPNuw0/Q/+ 3bvVU8W+dp2xMpK7FOIvUzfcvYN0vPDNQXBcugYiII90YZMfmovxH4y/BS6JrxFHyI rffZ8wWqskztlbg7HA3bphJ44g1ADaEAiyZFUjeA= Received: by mail-wr1-f47.google.com with SMTP id u6so7679482wrt.0 for ; Thu, 13 Feb 2020 09:13:12 -0800 (PST) X-Gm-Message-State: APjAAAWiSVgDcFZCbgxrG4G4BMluVPA5k98WmCJg1KZUyJVtpXbWPm3n 1Zk736vklnC0PV8CX+qZyH/VhVotBLLBio7AN2OIsw== X-Google-Smtp-Source: APXvYqwfGp+HHdQIFAu23pxn/wIxIFeKFu5EuoFB2R6CPKb8dbBhH47KafSTgYtv8BXGr/P3P1dm1egDcwSvkEKvWZ8= X-Received: by 2002:a5d:65cf:: with SMTP id e15mr22245562wrw.126.1581613991021; Thu, 13 Feb 2020 09:13:11 -0800 (PST) MIME-Version: 1.0 References: <20200213145928.7047-1-ardb@kernel.org> <20200213145928.7047-3-ardb@kernel.org> <20200213165902.GA1400002@rani.riverdale.lan> In-Reply-To: <20200213165902.GA1400002@rani.riverdale.lan> From: Ard Biesheuvel Date: Thu, 13 Feb 2020 17:13:00 +0000 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [RFC PATCH 2/3] efi/x86: add true mixed mode entry point into .compat section To: Arvind Sankar Cc: linux-efi , linux-arm-kernel , Laszlo Ersek , Leif Lindholm , Peter Jones , Matthew Garrett , Alexander Graf , Daniel Kiper , Hans de Goede , Michael Brown , Ingo Molnar Content-Type: text/plain; charset="UTF-8" Sender: linux-efi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-efi@vger.kernel.org On Thu, 13 Feb 2020 at 17:59, Arvind Sankar wrote: > > On Thu, Feb 13, 2020 at 03:59:27PM +0100, Ard Biesheuvel wrote: > > Currently, mixed mode is closely tied to the EFI handover protocol > > and relies on intimate knowledge of the bootparams structure, setup > > header etc, all of which are rather byzantine and entirely specific > > to x86. > > > > Even though no other EFI supported architectures are currently known > > that could support something like mixed mode, it makes sense to > > abstract a bit from this, and make it part of a generic Linux on EFI > > boot protocol. > > > > To that end, add a .compat section to the mixed mode binary, and populate > > it with the PE machine type and entry point address, allowing firmware > > implementations to match it to their native machine type, and invoke > > non-native binaries using a secondary entry point. > > This patch refers to efi32_pe_entry which is only defined in the next > one. Indeed. So the .compat section will be emitted with a bogus entry point when applying this patch but not the next one, so perhaps I should simply reorder them . 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 X-Spam-Level: X-Spam-Status: No, score=-1.0 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4AFCFC2BA83 for ; Thu, 13 Feb 2020 17:13:23 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 175C6206DB for ; Thu, 13 Feb 2020 17:13:23 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="BpQyyvQG"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="PGJl0ZsO" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 175C6206DB Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:To:Subject:Message-ID:Date:From: In-Reply-To:References:MIME-Version:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=jw5GXUCsfpQtxSXRJXc1C3C/1wiLn7n1Sa8HvIc5aLk=; b=BpQyyvQGsR93mS s0jmROZ7MjqZxBwCCJnlQHBAIJvd70ZJnmJa9fRzTuA1x9XXyavu0aiPR8ojmi/Iwx4ZtytysrAeh oUN8CX6HrKyuiso2WR6ccCaKVBSOtLap6DaAF5x+LtJ67gocWCvyHnPm+qCtAOVlHSw14LuJfQxdl btd9+Ji5YFS25FLGoUg4AQ9KsQK5wtcrJ0swhjHGgPlXGG9MDnyEMTaPZ41yo3M6r5rUl8Yp6y0t1 snkfhe7TYfhwp331dZIP7N7Lw3rGx5i2URf1RixhXvuzxKhru3Nswm6tjnfqBdP+TVrbGqi6dxlnq /8DLa6liumoT30sr0VVQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1j2I3A-0000Cw-8Z; Thu, 13 Feb 2020 17:13:16 +0000 Received: from mail.kernel.org ([198.145.29.99]) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1j2I37-0000CU-CX for linux-arm-kernel@lists.infradead.org; Thu, 13 Feb 2020 17:13:14 +0000 Received: from mail-wr1-f47.google.com (mail-wr1-f47.google.com [209.85.221.47]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id B44CF24671 for ; Thu, 13 Feb 2020 17:13:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1581613993; bh=l56qEB9k44eSpvcs/9db1OGeL5hy9h6oE3gaJUII1rg=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=PGJl0ZsOHuUXBA+DysErbQ8+43epyDksEZdXWC3xdLBYB67KYpuknKqxPNuw0/Q/+ 3bvVU8W+dp2xMpK7FOIvUzfcvYN0vPDNQXBcugYiII90YZMfmovxH4y/BS6JrxFHyI rffZ8wWqskztlbg7HA3bphJ44g1ADaEAiyZFUjeA= Received: by mail-wr1-f47.google.com with SMTP id y17so7641098wrh.5 for ; Thu, 13 Feb 2020 09:13:12 -0800 (PST) X-Gm-Message-State: APjAAAVxs6XWFmiAoQLwqDukXpr1MYg/EmMGeG6botAMgZQznqCVSbbN r4d7x0/FNqKEjEnAWhEU/INnSQEVjPqVHOvaeXgJmg== X-Google-Smtp-Source: APXvYqwfGp+HHdQIFAu23pxn/wIxIFeKFu5EuoFB2R6CPKb8dbBhH47KafSTgYtv8BXGr/P3P1dm1egDcwSvkEKvWZ8= X-Received: by 2002:a5d:65cf:: with SMTP id e15mr22245562wrw.126.1581613991021; Thu, 13 Feb 2020 09:13:11 -0800 (PST) MIME-Version: 1.0 References: <20200213145928.7047-1-ardb@kernel.org> <20200213145928.7047-3-ardb@kernel.org> <20200213165902.GA1400002@rani.riverdale.lan> In-Reply-To: <20200213165902.GA1400002@rani.riverdale.lan> From: Ard Biesheuvel Date: Thu, 13 Feb 2020 17:13:00 +0000 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [RFC PATCH 2/3] efi/x86: add true mixed mode entry point into .compat section To: Arvind Sankar X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200213_091313_450653_AD0CF47A X-CRM114-Status: GOOD ( 16.76 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-efi , Alexander Graf , Daniel Kiper , Matthew Garrett , Michael Brown , Hans de Goede , Peter Jones , Leif Lindholm , Laszlo Ersek , Ingo Molnar , linux-arm-kernel Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, 13 Feb 2020 at 17:59, Arvind Sankar wrote: > > On Thu, Feb 13, 2020 at 03:59:27PM +0100, Ard Biesheuvel wrote: > > Currently, mixed mode is closely tied to the EFI handover protocol > > and relies on intimate knowledge of the bootparams structure, setup > > header etc, all of which are rather byzantine and entirely specific > > to x86. > > > > Even though no other EFI supported architectures are currently known > > that could support something like mixed mode, it makes sense to > > abstract a bit from this, and make it part of a generic Linux on EFI > > boot protocol. > > > > To that end, add a .compat section to the mixed mode binary, and populate > > it with the PE machine type and entry point address, allowing firmware > > implementations to match it to their native machine type, and invoke > > non-native binaries using a secondary entry point. > > This patch refers to efi32_pe_entry which is only defined in the next > one. Indeed. So the .compat section will be emitted with a bogus entry point when applying this patch but not the next one, so perhaps I should simply reorder them . _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel