From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mx.groups.io with SMTP id smtpd.web11.13103.1609960060910180768 for ; Wed, 06 Jan 2021 11:07:41 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=Q/ztg8oE; spf=pass (domain: redhat.com, ip: 216.205.24.124, mailfrom: lersek@redhat.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1609960060; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=R2LWmOtRSmpBTodnwEt+F3yBHfzVGgvErcDHbYVk/EM=; b=Q/ztg8oE49dCjrquObA0UsaGXBSlGORJlc21BKlY2HdcisNYj45uZ12MPsBR4f8t5KskXU RM2F3ZlGpeVzSjor8hd/s4172ZYOFp+7EAYNOzNTlNYezk8TuExNlSbqqDoIPgnM9Bta6U uIOS58RBn3QhYRuW6ER6xiJJuKEosNc= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-63-I9Nn9784MByZVxzxl4qE9g-1; Wed, 06 Jan 2021 14:07:36 -0500 X-MC-Unique: I9Nn9784MByZVxzxl4qE9g-1 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 7C6ED107ACE3; Wed, 6 Jan 2021 19:07:35 +0000 (UTC) Received: from lacos-laptop-7.usersys.redhat.com (ovpn-113-198.ams2.redhat.com [10.36.113.198]) by smtp.corp.redhat.com (Postfix) with ESMTP id D8B4C62467; Wed, 6 Jan 2021 19:07:34 +0000 (UTC) Subject: Re: [edk2-devel] [PATCH v2 15/16] UefiCpuPkg: CpuIo2Smm: Support of CpuIo driver under StandaloneMm To: Kun Qin , devel@edk2.groups.io References: <93505c34-3161-26eb-5feb-f916988f5f1b@redhat.com> <10604.1609959736066754079@groups.io> From: "Laszlo Ersek" Message-ID: Date: Wed, 6 Jan 2021 20:07:33 +0100 MIME-Version: 1.0 In-Reply-To: <10604.1609959736066754079@groups.io> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=lersek@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit On 01/06/21 20:02, Kun Qin wrote: > Hi Laszlo, > > I did the patch mostly following the pattern of this commit: MdeModulePkg/FaultTolerantWriteDxe: factor out boot service accesses ยท tianocore/edk2@22cedf5 (github.com) ( https://github.com/tianocore/edk2/commit/22cedf5bbde616e0369e9f8649964f175a0cb95e ). The extra step I made was renaming the CpuIo2Smm.c to CpuIo2Common.c for semantic reason. > > The needed changes here are: > 1. Replacing gSmst with gMmst. Because SmmServicesTableLib does not exist for MM_STANDALONE type drivers, but MmServicesTableLib has library instances for both MM_STANDALONE and DXE_SMM_DRIVER as is. Both MmServicesTableLib and SmmServicesTableLib retrieve services table through the same protocol GUID, reference to substantially the same data structure. OK. But please perform this step stand-alone. There should be a patch that *only* moves from gSmst to gMmst. > 2. Abstract the driver entry point for Traditional MM and Standalone MM instances. Because these drivers have different entry point interface definitions. > > I will update the commit message to fix the typo. In addition, I can revert the file renaming change and break the above 2 changes into 2 patches, if that make the git history and review process cleaner. Yes, please. Thanks! Laszlo