From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=134.134.136.24; helo=mga09.intel.com; envelope-from=michael.d.kinney@intel.com; receiver=edk2-devel@lists.01.org Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 54C2F21A00AE6 for ; Wed, 12 Sep 2018 08:11:05 -0700 (PDT) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga003.jf.intel.com ([10.7.209.27]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 12 Sep 2018 08:11:05 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.53,365,1531810800"; d="scan'208";a="82917740" Received: from orsmsx103.amr.corp.intel.com ([10.22.225.130]) by orsmga003.jf.intel.com with ESMTP; 12 Sep 2018 08:10:59 -0700 Received: from orsmsx158.amr.corp.intel.com (10.22.240.20) by ORSMSX103.amr.corp.intel.com (10.22.225.130) with Microsoft SMTP Server (TLS) id 14.3.319.2; Wed, 12 Sep 2018 08:10:58 -0700 Received: from orsmsx113.amr.corp.intel.com ([169.254.9.72]) by ORSMSX158.amr.corp.intel.com ([169.254.10.59]) with mapi id 14.03.0319.002; Wed, 12 Sep 2018 08:10:58 -0700 From: "Kinney, Michael D" To: Ard Biesheuvel , "edk2-devel@lists.01.org" , "Kinney, Michael D" CC: "agraf@suse.de" , "Zimmer, Vincent" , "Richardson, Brian" , Andrew Fish , Laszlo Ersek , "Leif Lindholm" , "Zeng, Star" , "Dong, Eric" , "Ni, Ruiyu" Thread-Topic: [PATCH 0/4] MdeModulePkg: add support for dispatching foreign arch PE/COFF images Thread-Index: AQHUSpuyON64A63PaUSuwR7hF0LO1aTsvukw Date: Wed, 12 Sep 2018 15:10:57 +0000 Message-ID: References: <20180912132151.4258-1-ard.biesheuvel@linaro.org> In-Reply-To: <20180912132151.4258-1-ard.biesheuvel@linaro.org> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.0.400.15 dlp-reaction: no-action x-originating-ip: [10.22.254.138] MIME-Version: 1.0 Subject: Re: [PATCH 0/4] MdeModulePkg: add support for dispatching foreign arch PE/COFF images X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 12 Sep 2018 15:11:05 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Ard, I think there may be a lot of assumptions in this proposal that are not documented. =20 I do not see any description of how an image is=20 started or how calls between native code and emulated code are handled. Also, are multiple emulated CPUs supported? It looks like there can only be one instance of this new protocol. Can you please provide more detailed comments for the functions in the new protocol and document the assumptions and known limitation in the header? >>From one perspective, EBC is an emulated instruction set. Would it make sense to have EBC be one of the emulated=20 CPU types that can be plugged in? Thanks, Mike > -----Original Message----- > From: Ard Biesheuvel [mailto:ard.biesheuvel@linaro.org] > Sent: Wednesday, September 12, 2018 6:22 AM > To: edk2-devel@lists.01.org > Cc: agraf@suse.de; Ard Biesheuvel > ; Zimmer, Vincent > ; Richardson, Brian > ; Kinney, Michael D > ; Andrew Fish > ; Laszlo Ersek ; > Leif Lindholm ; Zeng, Star > ; Dong, Eric ; > Ni, Ruiyu > Subject: [PATCH 0/4] MdeModulePkg: add support for > dispatching foreign arch PE/COFF images >=20 > Add the basic plumbing to DXE core, the PCI bus driver > and the boot manager > to allow PE/COFF images to be dispatched that target an > architecture that is > not native for the platform, but which is supported by > an emulator. >=20 > One implementation of such an emulator can be found > here: > https://github.com/ardbiesheuvel/X86EmulatorPkg >=20 > Cc: Zimmer Vincent > Cc: Brian Richardson > Cc: Michael D Kinney > Cc: Andrew Fish > Cc: Laszlo Ersek > Cc: Leif Lindholm > Cc: Star Zeng > Cc: Eric Dong > Cc: Ruiyu Ni >=20 > Ard Biesheuvel (4): > MdeModulePkg: introduce PE/COFF image emulator > protocol > MdeModulePkg/DxeCore: invoke the emulator protocol for > foreign images > MdeModulePkg/PciBusDxe: invoke PE/COFF emulator for > foreign option > ROMs > MdeModulePkg/UefiBootManagerLib: allow foreign > Driver#### images >=20 > MdeModulePkg/Bus/Pci/PciBusDxe/PciBus.h | 1 + > MdeModulePkg/Bus/Pci/PciBusDxe/PciBusDxe.inf | 1 + > .../Bus/Pci/PciBusDxe/PciOptionRomSupport.c | 16 > +++++- > MdeModulePkg/Core/Dxe/DxeMain.h | 3 ++ > MdeModulePkg/Core/Dxe/DxeMain.inf | 1 + > MdeModulePkg/Core/Dxe/Image/Image.c | 39 > +++++++++++--- > .../Include/Protocol/PeCoffImageEmulator.h | 51 > +++++++++++++++++++ > .../Library/UefiBootManagerLib/BmLoadOption.c | 26 > +++++++++- > .../Library/UefiBootManagerLib/InternalBm.h | 1 + > .../UefiBootManagerLib/UefiBootManagerLib.inf | 1 + > MdeModulePkg/MdeModulePkg.dec | 4 ++ > 11 files changed, 136 insertions(+), 8 deletions(-) > create mode 100644 > MdeModulePkg/Include/Protocol/PeCoffImageEmulator.h >=20 > -- > 2.17.1