From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by mx.groups.io with SMTP id smtpd.web12.5654.1652233700436532243 for ; Tue, 10 May 2022 18:48:23 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="unable to parse pub key" header.i=@intel.com header.s=intel header.b=ZfYAhzFF; spf=pass (domain: intel.com, ip: 134.134.136.24, mailfrom: zhiguang.liu@intel.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1652233700; x=1683769700; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=1PHvUVD3zBDVz8vA+zDwCR597Bv3xCjMwNnLy5TjH9g=; b=ZfYAhzFFJNljcGwiLFQ6f+001WPX0AhRvOd3W63NWHRsJKGzARHcPpKL 4xDTW/1yIYDbJAHJsAXuG/e+ADOwpBY2vXaiJmLNpY4KRQ4zSvzQTTPVG xgMMDcoqR20z0c3C1a3+xe19R9YSzOyEzzLfq3WyKZ5zNuUwssQ4ziHkQ e11WHpH0CX5wIFKqXpOehqJGduzgV0Dhv/N1+NZWD7PAZJhtDrgHuUs9R aces5hOSC31dbgfVW96hRISNyeRmni6pHK/rZuTICrRwELSJ0D2xPOC3b ziehmyRVmPMSZ9w1r1CQPwumWZ1tH6HzNnDuLijovAxR+zxX3Ihciz+6o Q==; X-IronPort-AV: E=McAfee;i="6400,9594,10343"; a="269219932" X-IronPort-AV: E=Sophos;i="5.91,215,1647327600"; d="scan'208";a="269219932" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 10 May 2022 18:48:19 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.91,215,1647327600"; d="scan'208";a="565934290" Received: from orsmsx606.amr.corp.intel.com ([10.22.229.19]) by orsmga007.jf.intel.com with ESMTP; 10 May 2022 18:48:19 -0700 Received: from orsmsx601.amr.corp.intel.com (10.22.229.14) by ORSMSX606.amr.corp.intel.com (10.22.229.19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27; Tue, 10 May 2022 18:48:19 -0700 Received: from ORSEDG601.ED.cps.intel.com (10.7.248.6) by orsmsx601.amr.corp.intel.com (10.22.229.14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27 via Frontend Transport; Tue, 10 May 2022 18:48:19 -0700 Received: from NAM10-BN7-obe.outbound.protection.outlook.com (104.47.70.106) by edgegateway.intel.com (134.134.137.102) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2308.27; Tue, 10 May 2022 18:48:19 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=f/t6ZRQrwjjwLL6lkHmSLgjXmnJ9J4inTCxiDmTikfCCpRIypJkos5tfBnHQGFBxwlL4DpyGLsJgLh7IubRZvFiB0K7d25/wqVM537MeF34QYczvAeUP72RJ0d9Se7Jy+YKMTnmMdghotn+athhX4rWGyA/Xg9K2Rhye/vFafN6KzcYvjNfnFtTWU2uRqhx24lJ4i1LMEQES6057XENpYhj1Bkoa6BgKDguSgIkw6NKBMpfxstgnbLtbbbb+Cpwg+FPNiPnmLVUfvsOzvipkRv6p+1n9fnenOXoYZJqLosHcTRQZ8eaBLnSZui4EE54IZYw9CHZtnx+kjOMeFUJcwQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=W97cVjvbrxq8HikCa19u+rHc3jgEaICPi4bnx9d968M=; b=hNtVUY3BsshGmLaaGuV6iXacHYrcXf+NqpaHuRTM1iMvMeyT1SK6ZjIg+LXwvQ7DGrB43YqXeGMcDyDMTZNDeYIQ+xTyMW9BptMiQtycDKGQh5hW0H5wIuyF09wpalmlwi7MI49LnbEeDVc7bfDjlQbZRG/KpPuIUgsIvtMOiPiWkRfZUSvcum/T3DRyNza9LiorPWT3DiRKisRrIpm1jXZflyO5XDeH/HDBTP+P0RbPh/Dvh9ZauQj1tblRcomIsXmj5tFRBcnUDPCP9v/ysXUfnDAGNLwxVCUFSyMNZGWy1NwCiDU5/ymY7Orq5UW+8Ca7s/urvSlq4uVa8RTfYg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Received: from PH0PR11MB5048.namprd11.prod.outlook.com (2603:10b6:510:3d::14) by DM6PR11MB3833.namprd11.prod.outlook.com (2603:10b6:5:144::26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5227.23; Wed, 11 May 2022 01:48:16 +0000 Received: from PH0PR11MB5048.namprd11.prod.outlook.com ([fe80::2523:8a4e:dc56:f08d]) by PH0PR11MB5048.namprd11.prod.outlook.com ([fe80::2523:8a4e:dc56:f08d%9]) with mapi id 15.20.5227.023; Wed, 11 May 2022 01:48:16 +0000 From: "Zhiguang Liu" To: "Ni, Ray" , "devel@edk2.groups.io" CC: "Dong, Guo" , Maurice Ma , "You, Benjamin" , "Rhodes, Sean" Subject: Re: [PATCH 1/3] UefiPayloadPkg: Simplify code logic Thread-Topic: [PATCH 1/3] UefiPayloadPkg: Simplify code logic Thread-Index: AQHYZEESeoJZKrySGUGwuRyuLFwI4K0Y3E3Q Date: Wed, 11 May 2022 01:48:16 +0000 Message-ID: References: <2ce68964b1dc683b505e765cdf96b262f66f051c.1652166437.git.zhiguang.liu@intel.com> In-Reply-To: Accept-Language: en-US, zh-CN X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 0f584ed0-842b-47f2-9f7c-08da32f05160 x-ms-traffictypediagnostic: DM6PR11MB3833:EE_ x-ld-processed: 46c98d88-e344-4ed4-8496-4ed7712e255d,ExtAddr x-microsoft-antispam-prvs: x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: L8NZnlhX+3oChVntaHOzyQw9+Ek1ScA/zW265pX8T6JIXh8IEV7RC9MeLlmsspfn5OT9cQ/UFaDATovHpQWOPJK6ogCMrKszngdvqCnBLqMHFU5lDmm8TWzvs8JibhY5Zu7GgmfOUaoJ4Y79O/xaFrPLSglH6O+3reETe+lU8ELhF3BmopRxiHdcHtA1H9JUsBZTsTxdUOoJhj8iRx3ECrcgxQQOJVc8fJT31tyorLuKnwY5KAJjp+msn+4rzOfi6cUrF1e3gMFy38bZ9hpLiFqmS+YRy7ftvzk5buuNwtKn7+XsCr8ieCue24T8lSZdAV5NFgJKl159ge8k9nAppnxU6B8lxrfZ7CNd+SV3Sg8O+RcZu9Uipd+y+0SDwYB4az9+brwe6sw83ZOmO2jnsFeCU6FbjOLnLusVDoYirIUF2NoQFCxcMR2mluidgzY+Pvn1VLl72XUBQjhX0VygH4FbXZUge3/TW8L72WGmEZiY40SyPUqI7v27HJkefw5zk8crd1ighsRBRMTbbsGJMhBkDk+xRWx/IzO2vRMAzcvVEZYYH6hdx1oMtjBWSUYp6LchwwSoqXJI9yb+CTnw5/FwoLCV56cCtEP1TJQ0iq84wCVpbIN1+ctPkK9Z7ZVRZSbLwHbO2lvwJaBUhNYc7IJ7QvQwdapJVoEN+D1Jih/orwwryXa4LEj/7NfR6Y4tIEmoi9RLcSB9FoxR/evWhQ== x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:PH0PR11MB5048.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230001)(366004)(9686003)(55016003)(26005)(8936002)(186003)(5660300002)(76116006)(66476007)(4326008)(82960400001)(66946007)(64756008)(66446008)(4744005)(66556008)(8676002)(33656002)(52536014)(54906003)(2906002)(316002)(110136005)(122000001)(38070700005)(38100700002)(7696005)(508600001)(6506007)(71200400001)(53546011)(86362001)(83380400001);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?RGgb+7Hw496y2aNTxlvX2Lip3LBriYN4T5h9c+yHIwgO75Pqmg+5gvMWMICr?= =?us-ascii?Q?Jd8br4n/UFM/ps56oTaw8G/kXu+ZTpz16oOjqU4ngXg5CocbUq/nhT/0HVux?= =?us-ascii?Q?7PrCN/fzs+kQpdbhdxzEYGkj04FLFQ5q5KaZQrbQ3C9Saq1fgungwHsekDt5?= =?us-ascii?Q?0pe87ks7xKyRY9k1prOo1E2ExviNvkNNfXdDCu49qt/63fw9K/GiMrur68Yz?= =?us-ascii?Q?MqvQjJ4aamfXWNyvqGN5ZT8oBDw8hoYBGcZWekCuZTOcQyVciMZrVvema0tD?= =?us-ascii?Q?S6sy8BtYda2A7WCPqJN4vKAtUe3YU9XqyxoujP0SetWHBVP7b/CamAr9sIA6?= =?us-ascii?Q?j0FuZCVW2p6Z3waxMg7WY1zADUO1MaqAReLITt6CWXVTG3tyfwHcpO6QRo2c?= =?us-ascii?Q?IfxP1DVTddNdyCkOW2YZQZpJVCPogRYgGfdtMrMr5kzTtCNW3vkHztt8e1a3?= =?us-ascii?Q?PmX5aQEoca0EUtRzSkmbWGs+/gGoXs77Nyy00qEwXy4wC46XwurD7dDnWmWu?= =?us-ascii?Q?h9c+pu/pyCF+lQ7EJ6RA2ARfpqCXQ33K2hw6MDxQHnBH12fRe0S6+ZHJEF5H?= =?us-ascii?Q?6s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Am?= =?us-ascii?Q?LIz8i+KQZjf2E4ULYfwKKZ/xMW+cjnoc46j56+oOwJSfMhekeE7s6aMnZX45?= =?us-ascii?Q?Ewhxf4H/yzaTTOVEnR4FpmFqjUoD4Uj0VtqAd+EJGqzndGyXgwY18RoiBy3p?= =?us-ascii?Q?ls15XotbS4/fnhOojnfYUcxgW4E5cxvrdkKzXg+ruqflUFI3xjDq0rUNNejU?= =?us-ascii?Q?ioR8ubSRLIxyhsjmaHR1eo459CTePioN2d4YqVxpd28a+SSkCsixPTmErp8n?= =?us-ascii?Q?VHGytnfjOA=3D=3D?= MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: PH0PR11MB5048.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 0f584ed0-842b-47f2-9f7c-08da32f05160 X-MS-Exchange-CrossTenant-originalarrivaltime: 11 May 2022 01:48:16.4860 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: 9Kmnnkyg0LUno1L7BYcw1/sOu0ivuhL2NE0jt2dluZsOLOAxcKfscizkuGw7lzZRBpn0owpRcHCeN7cxMup9Hg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR11MB3833 Return-Path: zhiguang.liu@intel.com X-OriginatorOrg: intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hi Ray, The function DetectAndPreparePlatformPciDevicePath is the second parameter = of VisitAllInstancesOfProtocol. It follows the below type: typedef EFI_STATUS (EFIAPI *PROTOCOL_INSTANCE_CALLBACK)( IN EFI_HANDLE Handle, IN VOID *Instance, IN VOID *Context ); The same function pointer type is also defined in OvmfPkg. I didn't change the function pointer type to avoid same type having differe= nt definition in edk2 repo. Do I need to consider that? What's your suggestion? Thanks Zhiguang -----Original Message----- From: Ni, Ray =20 Sent: Tuesday, May 10, 2022 3:39 PM To: Liu, Zhiguang ; devel@edk2.groups.io Cc: Dong, Guo ; Maurice Ma ; You,= Benjamin ; Rhodes, Sean Subject: RE: [PATCH 1/3] UefiPayloadPkg: Simplify code logic >=20 > +DetectAndPreparePlatformPciDevicePath ( >=20 > IN EFI_HANDLE Handle, >=20 > IN VOID *Instance, >=20 > IN VOID *Context Is "Context" needed? Can you please remove it?