From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=192.55.52.151; helo=mga17.intel.com; envelope-from=jiewen.yao@intel.com; receiver=edk2-devel@lists.01.org Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) (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 8D8462194EB70 for ; Tue, 5 Mar 2019 07:51:24 -0800 (PST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga107.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 05 Mar 2019 07:51:24 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.58,444,1544515200"; d="scan'208";a="162281029" Received: from fmsmsx107.amr.corp.intel.com ([10.18.124.205]) by orsmga001.jf.intel.com with ESMTP; 05 Mar 2019 07:51:23 -0800 Received: from fmsmsx111.amr.corp.intel.com (10.18.116.5) by fmsmsx107.amr.corp.intel.com (10.18.124.205) with Microsoft SMTP Server (TLS) id 14.3.408.0; Tue, 5 Mar 2019 07:51:23 -0800 Received: from shsmsx104.ccr.corp.intel.com (10.239.4.70) by fmsmsx111.amr.corp.intel.com (10.18.116.5) with Microsoft SMTP Server (TLS) id 14.3.408.0; Tue, 5 Mar 2019 07:51:22 -0800 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.163]) by SHSMSX104.ccr.corp.intel.com ([169.254.5.74]) with mapi id 14.03.0415.000; Tue, 5 Mar 2019 23:51:20 +0800 From: "Yao, Jiewen" To: Ard Biesheuvel , "edk2-devel@lists.01.org" Thread-Topic: [PATCH 08/10] StandaloneMmPkg/Core: drop support for dispatching FVs into MM Thread-Index: AQHU01gCxCIevRFIwk6M3uWkYIYmkqX9L87w Date: Tue, 5 Mar 2019 15:51:19 +0000 Message-ID: <74D8A39837DF1E4DA445A8C0B3885C503F54D14E@shsmsx102.ccr.corp.intel.com> References: <20190305133248.4828-1-ard.biesheuvel@linaro.org> <20190305133248.4828-9-ard.biesheuvel@linaro.org> In-Reply-To: <20190305133248.4828-9-ard.biesheuvel@linaro.org> Accept-Language: zh-CN, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiNGY5M2VkZDQtNGQzOC00ZThiLWIwYzItYmJkZDM5MDU3NTlhIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiYVh5eEpsRlJkdkFFSXNtVG9uWnR4T0RuOFpsc0dIeFwvSXpPVWZORVY1emc2Q0hiWUJSTkJWVFwvYnlhXC9IOTFReiJ9 x-ctpclassification: CTP_NT dlp-product: dlpe-windows dlp-version: 11.0.400.15 dlp-reaction: no-action x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [PATCH 08/10] StandaloneMmPkg/Core: drop support for dispatching FVs into MM 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: Tue, 05 Mar 2019 15:51:24 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: jiewen.yao@intel.com > -----Original Message----- > From: Ard Biesheuvel [mailto:ard.biesheuvel@linaro.org] > Sent: Tuesday, March 5, 2019 5:33 AM > To: edk2-devel@lists.01.org > Cc: Ard Biesheuvel ; Achin Gupta > ; Supreeth Venkatesh > ; Yao, Jiewen ; > Leif Lindholm ; Jagadeesh Ujja > > Subject: [PATCH 08/10] StandaloneMmPkg/Core: drop support for > dispatching FVs into MM >=20 > Remove the support that permits calls into the MM context to dispatch > firmware volumes that are not part of the initial standalone MM firmware > volume. >=20 > Contributed-under: TianoCore Contribution Agreement 1.1 > Signed-off-by: Ard Biesheuvel > --- > StandaloneMmPkg/Core/StandaloneMmCore.h | 22 ---------- > StandaloneMmPkg/Core/Dispatcher.c | 46 -------------------- > StandaloneMmPkg/Core/StandaloneMmCore.c | 1 - > 3 files changed, 69 deletions(-) >=20 > diff --git a/StandaloneMmPkg/Core/StandaloneMmCore.h > b/StandaloneMmPkg/Core/StandaloneMmCore.h > index 0d20bcaa6be5..74338dc9da0d 100644 > --- a/StandaloneMmPkg/Core/StandaloneMmCore.h > +++ b/StandaloneMmPkg/Core/StandaloneMmCore.h > @@ -635,28 +635,6 @@ MmDriverDispatchHandler ( >=20 > @return Status Code >=20 > -**/ > -EFI_STATUS > -EFIAPI > -MmFvDispatchHandler ( > - IN EFI_HANDLE DispatchHandle, > - IN CONST VOID *Context, OPTIONAL > - IN OUT VOID *CommBuffer, OPTIONAL > - IN OUT UINTN *CommBufferSize OPTIONAL > - ); > - > -/** > - This function is the main entry point for an MM handler dispatch > - or communicate-based callback. > - > - @param DispatchHandle The unique handle assigned to this handler > by MmiHandlerRegister(). > - @param Context Points to an optional handler context > which was specified when the handler was registered. > - @param CommBuffer A pointer to a collection of data in > memory that will > - be conveyed from a non-MM environment > into an MM environment. > - @param CommBufferSize The size of the CommBuffer. > - > - @return Status Code > - > **/ > EFI_STATUS > EFIAPI > diff --git a/StandaloneMmPkg/Core/Dispatcher.c > b/StandaloneMmPkg/Core/Dispatcher.c > index bede4832cfb7..4b2f38f700a0 100644 > --- a/StandaloneMmPkg/Core/Dispatcher.c > +++ b/StandaloneMmPkg/Core/Dispatcher.c > @@ -883,52 +883,6 @@ MmAddToDriverList ( > return EFI_SUCCESS; > } >=20 > -/** > - This function is the main entry point for an MM handler dispatch > - or communicate-based callback. > - > - @param DispatchHandle The unique handle assigned to this handler > by SmiHandlerRegister(). > - @param Context Points to an optional handler context > which was specified when the handler was registered. > - @param CommBuffer A pointer to a collection of data in > memory that will > - be conveyed from a non-MM environment > into an MM environment. > - @param CommBufferSize The size of the CommBuffer. > - > - @return Status Code > - > -**/ > -EFI_STATUS > -EFIAPI > -MmFvDispatchHandler ( > - IN EFI_HANDLE DispatchHandle, > - IN CONST VOID *Context, OPTIONAL > - IN OUT VOID *CommBuffer, OPTIONAL > - IN OUT UINTN *CommBufferSize OPTIONAL > - ) > -{ > - EFI_STATUS Status; > - EFI_MM_COMMUNICATE_FV_DISPATCH_DATA > *CommunicationFvDispatchData; > - EFI_FIRMWARE_VOLUME_HEADER *FwVolHeader; > - > - DEBUG ((DEBUG_INFO, "MmFvDispatchHandler\n")); > - > - CommunicationFvDispatchData =3D CommBuffer; > - > - DEBUG ((DEBUG_INFO, " Dispatch - 0x%016lx - 0x%016lx\n", > CommunicationFvDispatchData->Address, > - CommunicationFvDispatchData->Size)); > - > - FwVolHeader =3D (EFI_FIRMWARE_VOLUME_HEADER > *)(UINTN)CommunicationFvDispatchData->Address; > - > - MmCoreFfsFindMmDriver (FwVolHeader); > - > - // > - // Execute the MM Dispatcher on any newly discovered FVs and > previously > - // discovered MM drivers that have been discovered but not dispatched. > - // > - Status =3D MmDispatcher (); > - > - return Status; > -} > - > /** > Traverse the discovered list for any drivers that were discovered but = not > loaded > because the dependency experessions evaluated to false. > diff --git a/StandaloneMmPkg/Core/StandaloneMmCore.c > b/StandaloneMmPkg/Core/StandaloneMmCore.c > index ec53b8d8bec4..766cdb5c848c 100644 > --- a/StandaloneMmPkg/Core/StandaloneMmCore.c > +++ b/StandaloneMmPkg/Core/StandaloneMmCore.c > @@ -99,7 +99,6 @@ BOOLEAN mInLegacyBoot =3D FALSE; > // Table of MMI Handlers that are registered by the MM Core when it is > initialized > // > MM_CORE_MMI_HANDLERS mMmCoreMmiHandlers[] =3D { > - { MmFvDispatchHandler, &gMmFvDispatchGuid, > NULL, TRUE }, > { MmReadyToLockHandler, &gEfiDxeMmReadyToLockProtocolGuid, > NULL, TRUE }, > { MmEndOfDxeHandler, &gEfiEndOfDxeEventGroupGuid, > NULL, FALSE }, > { MmLegacyBootHandler, &gEfiEventLegacyBootGuid, > NULL, FALSE }, > -- > 2.20.1