From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by mx.groups.io with SMTP id smtpd.web11.1587.1586482987689765055 for ; Thu, 09 Apr 2020 18:43:07 -0700 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: intel.com, ip: 192.55.52.120, mailfrom: hao.a.wu@intel.com) IronPort-SDR: USMI1vHGh0e+XoP86S/uo53H1Oo5iGYfAl6repPFVxoUC6ZUNjYqkQ0s1kt8PwwnHqKqtnm3qc YZYJ1qV9awuA== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Apr 2020 18:43:07 -0700 IronPort-SDR: LwMORyXcfMgEtkZfFhbmLzyEJNvmiRyovEbsrzJyYgPnqLkoLD1tk/gwztjNXS7GAcefhWe7CH 6Pmm1umQu9YA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.72,364,1580803200"; d="scan'208";a="425734946" Received: from fmsmsx106.amr.corp.intel.com ([10.18.124.204]) by orsmga005.jf.intel.com with ESMTP; 09 Apr 2020 18:43:07 -0700 Received: from shsmsx105.ccr.corp.intel.com (10.239.4.158) by FMSMSX106.amr.corp.intel.com (10.18.124.204) with Microsoft SMTP Server (TLS) id 14.3.439.0; Thu, 9 Apr 2020 18:43:06 -0700 Received: from shsmsx104.ccr.corp.intel.com ([169.254.5.225]) by SHSMSX105.ccr.corp.intel.com ([169.254.11.213]) with mapi id 14.03.0439.000; Fri, 10 Apr 2020 09:43:04 +0800 From: "Wu, Hao A" To: "michael.kubacki@outlook.com" , "devel@edk2.groups.io" CC: "Zhang, Chao B" , "Bi, Dandan" , "Wang, Jian J" , "Gao, Liming" , "Kinney, Michael D" , "Ni, Ray" , Sean Brogan Subject: Re: [PATCH v1 0/7] Add linked list iteration macros to BaseLib.h Thread-Topic: [PATCH v1 0/7] Add linked list iteration macros to BaseLib.h Thread-Index: AQHWDqpXL2E1wolaBEy5eArE6Idzrqhxk9hA Date: Fri, 10 Apr 2020 01:43:04 +0000 Message-ID: References: In-Reply-To: Accept-Language: zh-CN, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Return-Path: hao.a.wu@intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable > -----Original Message----- > From: michael.kubacki@outlook.com [mailto:michael.kubacki@outlook.com] > Sent: Friday, April 10, 2020 4:05 AM > To: devel@edk2.groups.io > Cc: Zhang, Chao B; Bi, Dandan; Wu, Hao A; Wang, Jian J; Gao, Liming; Kinn= ey, > Michael D; Ni, Ray; Sean Brogan > Subject: [PATCH v1 0/7] Add linked list iteration macros to BaseLib.h >=20 > From: Michael Kubacki >=20 > REF:https://bugzilla.tianocore.org/show_bug.cgi?id=3D1959 >=20 > The macros EFI_LIST_FOR_EACH and EFI_LIST_FOR_EACH_SAFE have been > duplicated across several drivers such as: >=20 > * EhciPei > * EhciDxe > * HddPasswordDxe > * RamDiskDxe > * UfsPassThruDxe > * XhciDxe >=20 > These macros have proven useful and established a commonly used pattern > for linked list iteration. >=20 > This patch series consolidates the definitions to a single definition in > BaseLib.h so they are maintained alongside other pre-existing generic > linked list macros and functions. >=20 > Note: Another commonly used generic linked list macro is > EFI_LIST_CONTAINER. > I'm considering consolidating that to BaseLib.h as well but that is not > done in this patch series since it satisfies a separate use case than the > iteration macros and the change can be made independently. >=20 > On a separate note, shallow threading might not work on this patch series > due to changes made by the SMTP server. Please bear with me while I am > investigating if this can be changed. >=20 > Cc: Chao Zhang > Cc: Dandan Bi > Cc: Hao A Wu > Cc: Jian J Wang > Cc: Liming Gao > Cc: Michael D Kinney > Cc: Ray Ni > Cc: Sean Brogan > Signed-off-by: Michael Kubacki >=20 > Michael Kubacki (7): > MdePkg/BaseLib: Add linked list iteration macros > MdeModulePkg/EhciDxe: Use BaseLib linked list iteration macros > MdeModulePkg/EhciPei: Use BaseLib linked list iteration macros > MdeModulePkg/XhciDxe: Use BaseLib linked list iteration macros > MdeModulePkg/UfsPassThruDxe: Use BaseLib linked list iteration macros > MdeModulePkg/RamDiskDxe: Use BaseLib linked list iteration macros Hello Michael, I found that for EhciPei, it does not have explicit dependency on the BaseL= ib, could you help to add it? With this handled, for the MdeModulePkg changes (patch 2~6): Reviewed-by: Hao A Wu Best Regards, Hao Wu > SecurityPkg/HddPassword: Use BaseLib linked list iteration macros >=20 > MdeModulePkg/Bus/Pci/EhciDxe/EhciDebug.c | 3 ++- > MdeModulePkg/Bus/Pci/EhciDxe/EhciSched.c | 11 ++++---- > MdeModulePkg/Bus/Pci/EhciDxe/EhciUrb.c | 5 ++-- > MdeModulePkg/Bus/Pci/EhciPei/EhciSched.c | 3 ++- > MdeModulePkg/Bus/Pci/EhciPei/EhciUrb.c | 5 ++-- > MdeModulePkg/Bus/Pci/XhciDxe/XhciSched.c | 9 ++++--- > MdeModulePkg/Bus/Ufs/UfsPassThruDxe/UfsPassThru.c | 3 ++- > MdeModulePkg/Bus/Ufs/UfsPassThruDxe/UfsPassThruHci.c | 3 ++- > MdeModulePkg/Universal/Disk/RamDiskDxe/RamDiskDriver.c | 3 ++- > MdeModulePkg/Universal/Disk/RamDiskDxe/RamDiskImpl.c | 9 ++++--- > MdeModulePkg/Universal/Disk/RamDiskDxe/RamDiskProtocol.c | 5 ++-- > SecurityPkg/HddPassword/HddPasswordDxe.c | 13 +++++----- > MdeModulePkg/Bus/Pci/EhciDxe/Ehci.h | 15 +---------= - > MdeModulePkg/Bus/Pci/EhciPei/EhcPeim.h | 15 +---------= - > MdeModulePkg/Bus/Pci/XhciDxe/Xhci.h | 9 +------ > MdeModulePkg/Bus/Ufs/UfsPassThruDxe/UfsPassThru.h | 9 +------ > MdeModulePkg/Universal/Disk/RamDiskDxe/RamDiskImpl.h | 15 +--------- > - > MdePkg/Include/Library/BaseLib.h | 27 > ++++++++++++++++++++ > SecurityPkg/HddPassword/HddPasswordDxe.h | 7 +---- > 19 files changed, 75 insertions(+), 94 deletions(-) >=20 > -- > 2.16.3.windows.1