From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by mx.groups.io with SMTP id smtpd.web10.80681.1682431828292590121 for ; Tue, 25 Apr 2023 07:10:28 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="unable to parse pub key" header.i=@intel.com header.s=intel header.b=dVrYU/FF; spf=pass (domain: intel.com, ip: 134.134.136.31, mailfrom: ray.ni@intel.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1682431828; x=1713967828; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=3BZXlOBD1v4wk+XeAqbbPnaVH5farjw8QIO2yAXdcNY=; b=dVrYU/FF4xWqSmlOkkI4qCSkMLMyC3shzQ2x7AqhnaRKgKU62Yvl6rXe 4cppxBbFNQgrkgcY/m80jCAS6kGjOBKh+jJ9J9QdTiaLMy01PXPfOr4ot D+gU686/zQQXrGoEetbwNmmojy9tHZoMlg3uIFNrO9VpI9mYc8z8WTmEO UC2N1Gy31gtILftPAzaUPdPv5QAlKI6fPpjhrFqh4kwlAilrZ/Gv9rXgI Laxtmyngpk3D0iDMdbVdkRHNFK0Q/jk5jtwpH2TMRg4T5ETPYDLdoD4J6 NE11pxeKMKZWJrYp8nN/IL+4QCauJi4dSosGEvBwwYczYWF8wuFCaFqxB w==; X-IronPort-AV: E=McAfee;i="6600,9927,10691"; a="409725899" X-IronPort-AV: E=Sophos;i="5.99,225,1677571200"; d="scan'208";a="409725899" Received: from orsmga004.jf.intel.com ([10.7.209.38]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Apr 2023 07:09:54 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10691"; a="817702466" X-IronPort-AV: E=Sophos;i="5.99,225,1677571200"; d="scan'208";a="817702466" Received: from orsmsx603.amr.corp.intel.com ([10.22.229.16]) by orsmga004.jf.intel.com with ESMTP; 25 Apr 2023 07:09:54 -0700 Received: from orsmsx610.amr.corp.intel.com (10.22.229.23) by ORSMSX603.amr.corp.intel.com (10.22.229.16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.23; Tue, 25 Apr 2023 07:09:54 -0700 Received: from orsedg603.ED.cps.intel.com (10.7.248.4) by orsmsx610.amr.corp.intel.com (10.22.229.23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.23 via Frontend Transport; Tue, 25 Apr 2023 07:09:54 -0700 Received: from NAM11-DM6-obe.outbound.protection.outlook.com (104.47.57.169) by edgegateway.intel.com (134.134.137.100) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.23; Tue, 25 Apr 2023 07:09:54 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=O8I1EIESNrgsznSBII7Wd4qlzmVYIoOjHmcEqgrmiA3WshuKkdKCHUbggoD9xe5V5BzChyPHwD4JQAytm3ZmchfLYo8EaS8Ny4Xm9bOBJF2RyPY3gF8/ageQ7Ecr3E9sE+SzvADN8+vO/pb4Jrh1qjZvGzLHiiB+mfsUq0/UEbt26ufzj7orAnDn4qbqmHVdMYEmc+AHI4lTdv5879VNIBmcUU5FjEJIpxeXzcwL6+9ufvbC+pasaDoJDVDymWPQwuuzR98cC8TjfP0DbM8HxwCwGaJMVFV0kV2Oa7EDRDnwwVK+8qDqLximyVD9Bp5iCClYkC7kn3HDijm5qvPsqg== 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=sUeZsF36bML5+MfK1uO466O+xWcD90vNCxGFwgV6Iqg=; b=D3okHVlh7QnCvKc0oBj97+qE8xg8WRTTxbB54O1b7l/TuOxB7WnqlQhrYVSnPreQ0ux4uv2yUZRapoh2pQ4xv4WsXjK6MSWSdI/h4u2/ffEIZhLLX5NLYT2SYwJuDXW7d5e6rpdsYP86yLW6CDjePcl7O0hpxdKLs/lDDReYO9jt74LushbgO6mJTxZmhKtxiK5ljl+beRBm6sACanuzZuZOxyf2SMHeEgaj8Y0mqsb82fZxAEZZUJQ6IKTfnlDZUFrpksp2VVYi0Uclvz19w+iO4w+eoN54ghCJpfnVFWIJUeeSkh+DzUba3pPc7RKMYQKogkf2JTLgMHjRSUsrCQ== 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 MN6PR11MB8244.namprd11.prod.outlook.com (2603:10b6:208:470::14) by MN0PR11MB6110.namprd11.prod.outlook.com (2603:10b6:208:3ce::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6319.34; Tue, 25 Apr 2023 14:09:47 +0000 Received: from MN6PR11MB8244.namprd11.prod.outlook.com ([fe80::892b:b8e6:bab7:635d]) by MN6PR11MB8244.namprd11.prod.outlook.com ([fe80::892b:b8e6:bab7:635d%5]) with mapi id 15.20.6319.033; Tue, 25 Apr 2023 14:09:47 +0000 From: "Ni, Ray" To: "devel@edk2.groups.io" , "Tan, Dun" CC: "Dong, Eric" , "Kumar, Rahul R" , Gerd Hoffmann , "Chen, Xiao X" Subject: Re: [edk2-devel] [Patch V2 1/2] UefiCpuPkg: Update code to support enable ProcTrace only on BSP Thread-Topic: [edk2-devel] [Patch V2 1/2] UefiCpuPkg: Update code to support enable ProcTrace only on BSP Thread-Index: AQHZd1UhrFELlxtBtkafgjlTq/gs+q88D84Q Date: Tue, 25 Apr 2023 14:09:47 +0000 Message-ID: References: <20230425090524.3027-1-dun.tan@intel.com> <20230425090524.3027-2-dun.tan@intel.com> In-Reply-To: <20230425090524.3027-2-dun.tan@intel.com> Accept-Language: en-US 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-traffictypediagnostic: MN6PR11MB8244:EE_|MN0PR11MB6110:EE_ x-ms-office365-filtering-correlation-id: c725f31c-b930-4266-2446-08db4596ba1c x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: uQtOfgiEL+kRZ4GkBR/Fx7/Qzuhme2EaCSByBzpPd9nsby5JpovN1AYxMwZpeEa1FjTLWtaKedw6e88Kgf61HR3F5kHZrWmxjea9IGlJ+XCLjfs8IC3eJN17rN8QRycTH+3iC16+j20M6FoeP2HyPoSrTKK6KdcG6XdP9VT9mu6jG83bJ704hyjsL5qORIOtn3EXpcjy9vy/rdn3pBROyNSrIxe8tqkZylHiz/BkLUdI9JO5QNslJTg/jbNSryA2pE2CH8Fdze7lZCTRPUuX2R5ec0ySSDwMDjJJFBxEMPKeqfbaeGer4/983XL2/DSz3n20QJbudZpmr5fpqWP+HUUdknEvxEDk0ZAEGqlgNm3vBrNNxvfYhVZuepJrphPogVFoSMdWN3ar/ett1GLh10D3xs0RpGnKN2JcfFtbQQCexGxxlTi8ThNXZ3/Ul0ls9n2wjwDnXtG7INhQ4kaBr40gYgyi4ZVq/6bL4+sR0kAVKtjlgMhFA+wHVIhYb3IKl+E8yxgxUJ0ydRj/GysgvVD3HSEkz8wwSXFx0SKtKGDL5JX9Yp89LhkG73Q/FlsE6ZUZT+sYus1Zg36v9IsjQOQH0q+rJnD2Yj5pAU8VUgI= x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MN6PR11MB8244.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230028)(39860400002)(366004)(396003)(376002)(346002)(136003)(451199021)(55016003)(9686003)(316002)(6506007)(26005)(186003)(4326008)(41300700001)(478600001)(110136005)(54906003)(6636002)(66556008)(107886003)(66476007)(66446008)(66946007)(7696005)(71200400001)(64756008)(76116006)(38070700005)(122000001)(82960400001)(38100700002)(86362001)(33656002)(8676002)(8936002)(2906002)(4744005)(52536014)(5660300002);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?aDgnpSPJvd6Z+nylyF7gJMh+ybkkURhvf5XE94aBoG+qHDJzZKtzYlnU5Yka?= =?us-ascii?Q?LRvg6wR4yvvFVp/F7t8RUXKMjXKIyHI3LvDEzBG0K1v4APzbtREjUh9VofWs?= =?us-ascii?Q?9DzFXJn6kBHFinq7UdWMyqvYoaOXOWw1Eko2lDNNcSNGcVuYpEYpZoLY3Hvf?= =?us-ascii?Q?u5aPLW4bLJzB05nFFImSj5JkjnR6+ZBI1Mpq6jxjvwI7V5QCbAeD9EvcD5LN?= =?us-ascii?Q?XAYpaC5msIndT0DF1uzQzoVCUX+zekbaaa/maiFm4UMkSnZqv8cyWMIdd5uZ?= =?us-ascii?Q?8KsAPMZErVKBMxc3FP1Mb1v16cbsU0vRSWjKx0SaB3g55AoTL7i7f026AWMa?= =?us-ascii?Q?woxLHlbbLyxpouvGuZ0MRvy1zWgrOhOAHrCdvRC9JIeCw+pRHrlo4ZY2QPqm?= =?us-ascii?Q?K3I48uarYr5ksc43f5yv2SedpaUC785R6nuhsrKoht7yhqJuH63EkA1wAkyj?= =?us-ascii?Q?uQJrbEfUOmFiRLhMLIIT5Tloo/8RsmO0AVa0PxTcxPD9nwtj1cGgT2e/K0hh?= =?us-ascii?Q?MI7TzKanvUz8PEejHuuDmrEKPQtsY3UtUe1znxIDfw3caVtxp5QS0zj/a5WV?= =?us-ascii?Q?cn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XROXmPEkPrYDD5Z8UaQxFzl6KvDI?= =?us-ascii?Q?9XGRjfhSeEy7hDW/lWxheLwHt/eyXK6WRBgCUGWIOl7EQpK7qPMfxy20wXtH?= =?us-ascii?Q?Mg3NK6ZwiPPhbcaEPvUEOoSbuSjvSzLPuBKthk1q?= MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: MN6PR11MB8244.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: c725f31c-b930-4266-2446-08db4596ba1c X-MS-Exchange-CrossTenant-originalarrivaltime: 25 Apr 2023 14:09:47.2772 (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: GhCK3g+ehoUwW6bNtzAUpX5gl5FmVYvS2pTZn/F4QFshHdt/0ItMxLPK6pZu0vr3grZ+KK0MK75DiZY2HoKqvw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN0PR11MB6110 Return-Path: ray.ni@intel.com X-OriginatorOrg: intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable > + if (ProcTraceData->EnableOnBspOnly) { 1. can you please add comments here to remind reader that this is also the first and only time ProcTraceInitialize() runs? Similar comments in the next chunk code. > + MemRegionBaseAddr =3D (UINTN)AllocateAlignedReservedPages (Pages, > Alignment); > + if (MemRegionBaseAddr =3D=3D 0) { > + // > + // Could not allocate for BSP even > + // > + DEBUG ((DEBUG_ERROR, "ProcTrace: Out of mem, failed to allocate > buffer for BSP\n")); > + return RETURN_OUT_OF_RESOURCES; > + }=20