From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by mx.groups.io with SMTP id smtpd.web10.55024.1672713098952112882 for ; Mon, 02 Jan 2023 18:31:39 -0800 Authentication-Results: mx.groups.io; dkim=fail reason="unable to parse pub key" header.i=@intel.com header.s=intel header.b=VsjsOyEI; spf=pass (domain: intel.com, ip: 134.134.136.126, mailfrom: gua.guo@intel.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1672713098; x=1704249098; h=from:to:cc:subject:date:message-id:references: in-reply-to:mime-version; bh=hi78ZVUhfTLN9e6sjnQ9WEJhJUZ4exK7iCgoXaeUMEk=; b=VsjsOyEITCvtmD8vxufjw9LqTDZsYNrx9IP5KE3O/C7C9d8jiflDTqgu MY7NldciJse9YKYZvIQslwTi1TPUwJ+rT75Fij7/mO1/OiIjKFH7we8At ttkeXpt2AkjANdcJwOCYDyhtEzE5lyuwY3PFpsqnJJ6/0+VpRrL8IBv7z D4YFrYmmv1Fh/nOYMcmwfyFXkCHovwrGxS86QjkqJ7kkN8n45FAhA+HUm 5u0jrRBTAihm1tQ6IuX69v8ECVIg4WvSCjhV3aQLSzz10hoUNqCOX0jbe UwOG0Ft8r1iG1KW6z11MfgKv5G+PtNxo/5Lr+OYDbIQpZayankAjZ72k0 Q==; X-IronPort-AV: E=McAfee;i="6500,9779,10578"; a="305074301" X-IronPort-AV: E=Sophos;i="5.96,295,1665471600"; d="scan'208,217";a="305074301" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Jan 2023 18:31:38 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10578"; a="983428202" X-IronPort-AV: E=Sophos;i="5.96,295,1665471600"; d="scan'208,217";a="983428202" Received: from orsmsx603.amr.corp.intel.com ([10.22.229.16]) by fmsmga005.fm.intel.com with ESMTP; 02 Jan 2023 18:31:37 -0800 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.16; Mon, 2 Jan 2023 18:31:37 -0800 Received: from orsmsx601.amr.corp.intel.com (10.22.229.14) 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.16; Mon, 2 Jan 2023 18:31:36 -0800 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.2507.16 via Frontend Transport; Mon, 2 Jan 2023 18:31:36 -0800 Received: from NAM04-BN8-obe.outbound.protection.outlook.com (104.47.74.47) 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.2507.16; Mon, 2 Jan 2023 18:31:36 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=IaGpgA6fTRbjoMtqNJt0McTfnBZ15vrf9tP+TsQi7rq2hi973MSGmUu9WIdj+mDW1Eoq3ZcQwtuzBgQRigN1jhAXKJZP6muz15vx8IMvTT4evs5qDxGIcIK4JgJidIeaHiDAyHJTlUkJ5z8VZ0muj31eW0SeccT7GL0aVSHGz++sV5mvvlhJqUBX9e90m1DdWGG4dOD97zjeeeI7qxPYl26UTcyYx32p79BUoZpovPW0ntHSwvL0E0B+jywP1j7kqY5mr1KpX4yGftb3/QuSxS6B03AxWw876qWhV8NI3C6YQEV3mSae3yBuOVzRCvaNhlrMJ9e9OL9IZy94q9ywrQ== 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=xOCbnRHzCz4P59ZPaenUjwufMLFXstSLXKX5MYF4Bqw=; b=Jw1M6pCLwBZccOBjGRG9I3y1k31lEyd2Ql/NomN/FlquFDU3aWQuR6nvkr+D91cwxFq83bQs8cu5/RpdP1eRKnVZ3rlMMz21wUKzVI/txxQUL2KN83Pa49uCWR6lOQZkJs+gLMoxbjsqUUctShMyBmhM3Dt0acVf4cVezV3fIJkhdQ0xLyXcS5a0tDCmSJYUObDwtLtFpiFhjBY+zk8vyZm0NZf+ZvWocAZqFja3m5w72vnByCAbvy9WiHnBWyi2w1XfUoe82xfpRdbEWZ0ktAunyfp20yj8ccYHQBTVVOm5cgaF7pZELP21/O0q51LtEKwFTQ82ffEkaNhRZi8zbQ== 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 BL1PR11MB5478.namprd11.prod.outlook.com (2603:10b6:208:31d::12) by SA1PR11MB7129.namprd11.prod.outlook.com (2603:10b6:806:29d::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5944.19; Tue, 3 Jan 2023 02:31:33 +0000 Received: from BL1PR11MB5478.namprd11.prod.outlook.com ([fe80::eb2d:a316:8bcd:3fb6]) by BL1PR11MB5478.namprd11.prod.outlook.com ([fe80::eb2d:a316:8bcd:3fb6%9]) with mapi id 15.20.5944.019; Tue, 3 Jan 2023 02:31:33 +0000 From: "Guo, Gua" To: "Hsu, VictorX" , "Kinney, Michael D" , "Gao, Liming" , "devel@edk2.groups.io" , "Chan, Laura" , "Prakashan, Krishnadas Veliyathuparambil" , "K N, Karthik" CC: "Lu, James" , "Chen, Arthur G" , "Chiu, Chasel" , "Zimmer, Vincent" Subject: Re: Edk2 support MIPI SyS-T TraceHub Debug Library [TraceHubDebugLibSysT] Thread-Topic: Edk2 support MIPI SyS-T TraceHub Debug Library [TraceHubDebugLibSysT] Thread-Index: Adj/DG92N3a/MEygSlmVUL50vBrmkQGJexEAA78T73ACusgIwA== Date: Tue, 3 Jan 2023 02:31:33 +0000 Message-ID: References: In-Reply-To: Accept-Language: en-US X-Mentions: laura.chan@intel.com,krishnadas.veliyathuparambil.prakashan@intel.com,karthik.k.n@intel.com 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: BL1PR11MB5478:EE_|SA1PR11MB7129:EE_ x-ms-office365-filtering-correlation-id: 4a9b0fce-43a9-4b11-f14a-08daed32a142 x-ld-processed: 46c98d88-e344-4ed4-8496-4ed7712e255d,ExtAddr x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: uUxAAJKXCe2Bc1YciBkOnzR/3sS0Xi926RtkdPk4zfXHzKxsN6ZklpUMJk/SnJTdvdbcQv6J6Emu4gjAD0KWGK9708NhoAUZRP0ycJTvJG7lfewDDjk625+OOwf7gH1xPy3ZFZKaDu4juqEm1pRZrhfqUzVwl7I0hM9H9t5S87QndXkNPzXIBvrCNFrBrzqqWGv2HzPZg8fifg3ygw70u5KyUz85TpXe7vMYNpHUs5JmGax5yZP2KbClP1wSgiJ+9XbV/zL5mN5kB2UlPEmdvSDowzAS+T3o7FrJ1cNCmYMcGwC+vO4Q0q49oOJzG/nO3+gGjTyZ9LX6Og4PxFLHiWCppsQc1axXurerrpWA6yhZhOQkMRYQSh7kZAZK0PAgPixzk2nGdE6BBInggoPLKSjwZpvOp/pt0YSEMK6lRW9eZqneCxmp3adArwSGMV5C95gWIGGqegTmyuPWng1W+ewnfj1Cjy1RlusNi8Ayv6VQaA3yKUYHHqw6oHiOnLPlXSYN1/2dKqWScTpxH1gKFFeQGkI+/IexzI/teMPJwP/tLQB7qe/TCSCL5a4nbRVxu4pih1cbC6kZaPgilBaw2ATyTtn3GYz+QfEHFG85hRTM18F1bY3qBWdPFsSXmh9EqO/wIz890ACcymUPYSyeIlof8QMxW9QeoiHwqM3gycEoD7Ul8gxo14Cbn7G3k4yVcgU8J5h6vlOehOEAhXrW11rZb1aahupz9cCwu8pmQYE24/t/sjnYh7m97z83emszq1WEiD5l+/bMGH9Y+sos/jRBKQ/pIIPJGTVsdlQUY0QjBenIFOigG9ArSXVmND3aKuZhLtKsjXX85y389teb5A== x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:BL1PR11MB5478.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230022)(376002)(136003)(346002)(39860400002)(396003)(366004)(451199015)(26005)(186003)(9686003)(83380400001)(86362001)(55016003)(33656002)(38070700005)(921005)(38100700002)(122000001)(166002)(82960400001)(316002)(54906003)(52536014)(6636002)(4326008)(66946007)(41300700001)(8936002)(5660300002)(8676002)(76116006)(2906002)(66556008)(107886003)(66446008)(110136005)(84970400001)(66476007)(64756008)(478600001)(6506007)(71200400001)(7696005)(53546011)(966005)(22166006)(213903007);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?qEwFC2ueou37XPwGnN/J9vyFdSpMrrdoKgdnVL87jltNBwFwhPePK2hdn6eZ?= =?us-ascii?Q?eIMBfNj2KJgNWML5GxR/xAmawKZFjgBRQObjMB+0FgtsMLpgnSuHefdXjUBK?= =?us-ascii?Q?Sq98WZj9Zp19yabPEr/gBY5Zd6LcJootzT2vsauKvgJf/PTNA+UI5P2c2wNE?= =?us-ascii?Q?1V3GpvPrs8D9Al7xP95aFFWiCLDAKJ1FFlkfcW1FKujJdBqZk0QWpJWS3seZ?= =?us-ascii?Q?L4xJK+UsnPsX9M1yMMgX6mcEpRvX1fRp6WjlVpMVph8SCXEqe3kghoDxbfM8?= =?us-ascii?Q?lu4ZbfAJHJKCGAjHTvnULCkkUXh5z/ny3JzvTszeeZPWLdgimAL7enLH+Y3u?= =?us-ascii?Q?lTN9QzxTBcSlZK2vllrugX2VdLrmBUQdf68MNmFcnzTA1ZUxlrrhHQsOTk7V?= =?us-ascii?Q?tWRbC/5kinGOj3OU15Bgvj8ZFJ7a9PsoSpiCHJ3/lb7t5i/PJNwcUrtFC1M+?= =?us-ascii?Q?il1LGhsDvKanEusb32y+0EjNvrHo1Z1tRSiebNwYpOQXzoUFX8TtG/rLF6PU?= =?us-ascii?Q?dbXAGiubLpDetzQDkcv80Xb4ANYpB5SsNPEDhyCGfEXE+Tb6uZ2hFHyCPYEo?= =?us-ascii?Q?v3JAFNpZhOAqBNrRQQhG2tX8X6Awtv3mxuTV4HMDuzlwpf/rK1fZ2c6t1ngn?= =?us-ascii?Q?Zi42n/VaX44zt6P/V/LPBrr15P8o0AlaZNOcH4kIZGB5Wv/rZdNKDa67VWHd?= =?us-ascii?Q?2k2BxHtDF+OfWa9XpZwwLEVMXwuS/W6wAKXmcUdB5YKevMhhIGCSfzggwEti?= =?us-ascii?Q?ULHntihvpXl2vp3PcEns3lyraf2u7CrtQyIdXNhLDZDH33qsCr7+2DirxBvC?= =?us-ascii?Q?gcJ2FLcpPMXm9e0BtK9Xo/1bB6kDCTRscf7cRZ6a5HCVFd+rLGpgRhug34o2?= =?us-ascii?Q?if/Nf1+Zq/LfJ47ovZDdOwekzqgvnErLCmtx1iqDKF8cl0ovN8vuigVqYbdo?= =?us-ascii?Q?8IfAkGWcGJIpPZwpKD/Vg14im6EMQbNmeSlY3sNqapN39egds6idWKgrdQMS?= =?us-ascii?Q?P1lVigYP6+csCyFOvb4zADXXn31dDsxt8Feav/ZdQi1xGvRnmCLGcL0G9zFk?= =?us-ascii?Q?L9msL95kzk2w9c/xdiarKSmV3yyU3g1J1AH3HOd+StvLCQZwcPU4QFsipSaY?= =?us-ascii?Q?ZGQhjSodfIKkNJO1qbwd/2Bm7ytxRHepwssp6onGLRUr961SliYaPPSKNl6d?= =?us-ascii?Q?klNTKTm3thVVFdyCrjjaKEGcDJvGLcK+6b0FknvIwITXHAtdXAveOwonfg8f?= =?us-ascii?Q?mhFHgrPOukBE7iUns/xNF8R5lm2enV8mvhe21Dp5a//n4bTIyx/sgTfFTCKV?= =?us-ascii?Q?peEKuQbRQcC40qY8ZvswyyYgLqrMbd7RDrYnnHDik/Y6bSq9JJznmbVFZMUR?= =?us-ascii?Q?muY4rk/OEP1Qm2te5Ci4FFGajLtRWc2Tk/uMfkVDD0oV8FCsToKUIhOkdNef?= =?us-ascii?Q?lvssepRT3VsQg0k8ROiHWUToJINhBepeiJxgwNvQCVwTiDEizqls0Bd6p8oN?= =?us-ascii?Q?ArK2G3IUHy1CUALiQCldHKbSZBZA6uTdJPITAbi3LhiRFE4CEd7btqQXnfti?= =?us-ascii?Q?ev4ouaeRWZ2s8MNUk1I=3D?= MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: BL1PR11MB5478.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 4a9b0fce-43a9-4b11-f14a-08daed32a142 X-MS-Exchange-CrossTenant-originalarrivaltime: 03 Jan 2023 02:31:33.5388 (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: 96nl0QnTlT4BLnl6xvpLSEa8Q30A9PN6G3/rDdMCq/QmIhokbLzEorHV251sj3oHfwuTNtAB6DYvSSP4EOLbLA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SA1PR11MB7129 Return-Path: gua.guo@intel.com X-OriginatorOrg: intel.com Content-Language: en-US Content-Type: multipart/alternative; boundary="_000_BL1PR11MB5478680CA7FA65D7EE13760CEFF49BL1PR11MB5478namp_" --_000_BL1PR11MB5478680CA7FA65D7EE13760CEFF49BL1PR11MB5478namp_ Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable @Chan, Laura, @Prakashan, Krishnadas Veliyathu= parambil and @K N,= Karthik In parallel, please also help to review PR: https://github.com/tianocore/ed= k2/pull/3793 from TraceHubDebugLib owner viewpoint. TraceHubDebugLib.h API Change Origin firmware.boot.uefi.iafw.intel/TraceHubDebugLib.h at main * intel-restricted= /firmware.boot.uefi.iafw.intel * GitHub * TraceHubWriteCataLog64_0 (SeverityType, Id, ) * TraceHubWriteCataLog64_1 (SeverityType, Id, Param1, Param2) * TraceHubWriteCataLog64_2 (SeverityType, Id, Param1, Param2) * TraceHubWriteCataLog64_3 (SeverityType, Id, Param1, Param2, Param3) * TraceHubWriteCataLog64_4 (SeverityType, Id, Param1, Param2, Param3, P= aram4) * TraceHubWriteCataLog64_5 (SeverityType, Id, Param1, Param2, Param3, P= aram4, Param5) * TraceHubWriteCataLog64_6 (SeverityType, Id, Param1, Param2, Param3, P= aram4, Param5, Param6) Modify edk2_EXP/TraceHubDebugLib.h at th_leverageMIPI_v2 * hsuc1x/edk2_EXP * GitHu= b * TraceHubWriteCataLog64 (SeverityType, Id, 0) * TraceHubWriteCataLog64 (SeverityType, Id, 1, Param1) * TraceHubWriteCataLog64 (SeverityType, Id, 2, Param1, Param2) * TraceHubWriteCataLog64 (SeverityType, Id, 3, Param1, Param2, Param3) * TraceHubWriteCataLog64 (SeverityType, Id, 4, Param1, Param2, Param3, = Param4) * TraceHubWriteCataLog64 (SeverityType, Id, 5, Param1, Param2, Param3, = Param4, Param5) * TraceHubWriteCataLog64 (SeverityType, Id, 6, Param1, Param2, Param3, = Param4, Param5, Param6) Thanks, Gua From: Hsu, VictorX Sent: Wednesday, December 28, 2022 5:51 PM To: Guo, Gua ; Kinney, Michael D ; Gao, Liming ; devel@edk2.groups.io Cc: Chan, Laura ; Prakashan, Krishnadas Veliyathupara= mbil ; K N, Karthik ; Lu, James ; Chen, Arthur G ; Chiu, Chasel ; Zimmer, Vincent Subject: RE: Edk2 support MIPI SyS-T TraceHub Debug Library [TraceHubDebugL= ibSysT] Hi @Kinney, Michael D Please review https://github.com/tianocore/edk2/pull/3793 for below questio= ns. 1. Need to add TraceHub PCD into edk2/MdeModulePkg.uni at master * tiano= core/edk2 * GitHub Answer: Done 1. What about the license ? Answer: It's BSD license, based on public-mipi-sys-t/LICENSE at master * MI= PI-Alliance/public-mipi-sys-t (github.com) 1. Is PcdTraceHubDebugAddress MMIO address ? If yes, why we use UINT32 Answer: Done 1. For TraceHubWriteCataLog64_[0-6] try to use below macro to implement = it. #define VA_START va_start #define VA_ARG va_arg #define VA_END va_end #define VA_LIST va_list Answer: Done 1. Is have SMM or MM version ? Answer: Done, renamed to DxeSmmTraceHubDebugLibSyst.inf. 1. Whether have any chance to use .gitsubmodule to leverage https://gith= ub.com/MIPI-Alliance/public-mipi-sys-t. Answer:. https://github.com/tianocore/edk2/pull/3793 thanks From: Guo, Gua > Sent: Thursday, December 1, 2022 11:29 AM To: Kinney, Michael D >; Gao, Liming >; devel@edk2.groups.io Cc: Chan, Laura >; Prakas= han, Krishnadas Veliyathuparambil >; K N, Ka= rthik >; Lu, James >; Chen, Arthur G >; Chiu, Chasel >; Zimmer, Vincent >; Hsu, VictorX > Subject: RE: Edk2 support MIPI SyS-T TraceHub Debug Library [TraceHubDebugL= ibSysT] @Kinney, Michael D As we offline sync, there are below opens like below. Have any open, please= also share for us. 1. Need to add TraceHub PCD into edk2/MdeModulePkg.uni at master * tiano= core/edk2 * GitHub Answer: Will update it in next patch 1. What about the license ? Answer: It's BSD license, based on public-mipi-sys-t/LICENSE at master * MI= PI-Alliance/public-mipi-sys-t (github.com) 1. Is PcdTraceHubDebugAddress MMIO address ? If yes, why we use UINT32 Answer: It's MMIO address, we can change it to UINT64, it make sense to let= the PCH more generic. Will update it in next patch. 1. For TraceHubWriteCataLog64_[0-6] try to use below macro to implement = it. #define VA_START va_start #define VA_ARG va_arg #define VA_END va_end #define VA_LIST va_list Answer: Will update it in next patch 1. Is have SMM or MM version ? Answer: MdeModulePkg/Library/TraceHubDebugLibSysT/DxeTraceHubDebugLibSyst.i= nf can take care for SMM case. We can rename it like below to make it more = clearly. MdeModulePkg/Library/TraceHubDebugLibSysT/DxeSmmTraceHubDebugLibSyst.inf 1. Whether have any chance to use .gitsubmodule to leverage https://gith= ub.com/MIPI-Alliance/public-mipi-sys-t. Answer: Will draft another PR and try to use gitsubmodule to check whether = exist any predicament. Thanks Gua From: Guo, Gua Sent: Wednesday, November 23, 2022 3:29 PM To: Kinney, Michael D >; gaoliming >; devel@edk2.groups.io Cc: Chan, Laura >; Prakas= han, Krishnadas Veliyathuparambil >; K N, Ka= rthik >; Lu, James >; Chen, Arthur G >; Chiu, Chasel >; Zimmer, Vincent >; Hsu, VictorX > Subject: Edk2 support MIPI SyS-T TraceHub Debug Library [TraceHubDebugLibSy= sT] @Kinney, Michael D and @gaoliming We want to add TraceHubDebug library support on Edk2. It's new added librar= y on Edk2, so it doesn't have any backward and forward issue. May I know have any process we may need to follow up. Have any comment or c= oncern please also share for me. Reviewers/Maintainers: @Prakashan, Krishnadas Veliyathuparambil, @Chan, Laura, @K N, Karthik. USF UPL spec update: https://github.com/UniversalScalableFirmware/documenta= tion/pull/52 (Done) Edk2 Bugzilla: https://bugzilla.tianocore.org/show_bug.cgi?id=3D4144 (On-Go= ing) Edk2 PR: https://github.com/tianocore/edk2/pull/3613 (On-Going) Background: * Problem: In the UPL (Universal Payload) binary which contains only = the Edk2 drivers, Tracehub debug message are missing during the execution o= f early DXE Core modules (before ReportStatusCode is ready). * Solution: Add TraceHub lib on Edk2, to be consumed by the UPL. About TraceHubDebugLibSysT: * Library is consumed by the DebugLib and StatusCodeHandler to send the= PostCodes, ProgressCodes and DEBUG messages to the TraceHub/NPK in MIPI Sy= S-T format. * The MIPI SyS-T APIs in this library are taken from the OpenSource imp= lementation: https://github.com/MIPI-Alliance/public-mipi-sys-t. * Library changes done for upstreaming: MipiSystLib is rewritten to co= mply EDK2 coding standards and changed ways to pass trace address/verbosity= with HOB directly instead of calling into TraceHubHookLib to get these inf= o. * Proposal With UPL: consume HOB gUniversalPayloadTraceHubDebugInfoGuid= to print TraceHub Debug message in DXE Core Thanks, Gua --_000_BL1PR11MB5478680CA7FA65D7EE13760CEFF49BL1PR11MB5478namp_ Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable

@Chan, Laura, @Prakashan, Krishnadas Veliyathuparambil and @K N, Karthik

&nbs= p;

In parall= el, please also help to review PR: https://gith= ub.com/tianocore/edk2/pull/3793 from TraceHubDebugLib owner viewpoint.<= span style=3D"mso-fareast-language:ZH-TW">

&nbs= p;

TraceHubD= ebugLib.h API Change

Origin

firmware.boot.uefi.iafw.intel/TraceHubDebugLib.h at main &m= iddot; intel-restricted/firmware.boot.uefi.iafw.intel · GitHub<= /span>

  • TraceHubWriteCataLog64_0 (= SeverityType, Id, )
  • TraceHubWriteCataLog64_1 (SeverityType, Id, Param1, Param2)=
  • Tra= ceHubWriteCataLog64_2 (SeverityType, Id, Param1, Param2)<= /li>
  • TraceHubWriteCataLog64= _3 (SeverityType, Id, Param1, Param2, Param3)
  • <= span style=3D"mso-fareast-language:ZH-TW">TraceHubWriteCataLog64_4 (Severit= yType, Id, Param1, Param2, Param3, Param4)<= o:p>
  • Trac= eHubWriteCataLog64_5 (SeverityType, Id, Param1, Param2, Param3, Param4, Par= am5)
  • TraceHubWriteCataLog64_6 (SeverityType, Id, Param1, Param2, Param3, Param4= , Param5, Param6)

&nbs= p;

&nbs= p;

Modify

edk2_EXP= /TraceHubDebugLib.h at th_leverageMIPI_v2 · hsuc1x/edk2_EXP ·= GitHub

  • TraceHubWriteCataLog64 (Se= verityType, Id, 0)
  • TraceHubWriteCataLog64 (SeverityType, Id, 1, Param1)
  • TraceHubWri= teCataLog64 (SeverityType, Id, 2, Param1, Param2)
  • TraceHubWriteCataLog64 (Sever= ityType, Id, 3, Param1, Param2, Param3)
  • TraceHubWriteCataLog64 (SeverityType, I= d, 4, Param1, Param2, Param3, Param4)
  • TraceHubWriteCataLog64 (SeverityType, Id,= 5, Param1, Param2, Param3, Param4, Param5)
  • TraceHubWriteCataLog64 (SeverityTyp= e, Id, 6, Param1, Param2, Param3, Param4, Param5, Param6)=

&nbs= p;

Thanks,

Gua<= /o:p>

&nbs= p;

From: Hsu, VictorX <victorx.hsu@intel.com&= gt;
Sent: Wednesday, December 28, 2022 5:51 PM
To: Guo, Gua <gua.guo@intel.com>; Kinney, Michael D <michae= l.d.kinney@intel.com>; Gao, Liming <gaoliming@byosoft.com.cn>; dev= el@edk2.groups.io
Cc: Chan, Laura <laura.chan@intel.com>; Prakashan, Krishnadas = Veliyathuparambil <krishnadas.veliyathuparambil.prakashan@intel.com>;= K N, Karthik <karthik.k.n@intel.com>; Lu, James <james.lu@intel.c= om>; Chen, Arthur G <arthur.g.chen@intel.com>; Chiu, Chasel <chasel.chiu@intel.com>; Zimmer, Vincent <vincent.zimmer@i= ntel.com>
Subject: RE: Edk2 support MIPI SyS-T TraceHub Debug Library [TraceHu= bDebugLibSysT]

 

Hi @Kinney, Michael D

 

Please review https://github.com/tianocore/edk2/pull/3793 for below questions.

 

  1. Need to add TraceHub PCD into edk2/MdeModulePkg.uni at master · tianocore/edk2 · GitHub=

Answer: Done

  1. What about the license ?

Answer: It’s BSD license, based on public-mipi-sys-t/LICENSE at master · MIPI-Alliance/public-mipi-sys-= t (github.com)

  1. Is PcdTraceHubDebugAddress MMIO address ? If yes, why we use UINT32

Answer: Done

  1. For TraceHubWriteCataLog64_[0-6] try to use below macro to implement it.=

#define VA_START va_start

#define VA_ARG   va_arg<= /p>

#define VA_END   va_end<= /p>

#define VA_LIST  va_list

Answer: Done

  1. Is have SMM or MM version ?

Answer: Done, r= enamed to DxeSmmTraceHubDebugLibSyst.inf.

  1. Whether have any chance to use .gitsubmodule to leverage https://gith= ub.com/MIPI-Alliance/public-mipi-sys-t.

Answer:. https://github.com/tianocore/edk2/pull/3793

 

thanks

 

From: Guo, Gua <gua.guo@intel.com>
Sent: Thursday, December 1, 2022 11:29 AM
To: Kinney, Michael D <michael.d.kinney@intel.com>; Gao, Liming <gaoliming@byosoft.com.cn>; devel@edk2.groups.io
Cc: Chan, Laura <laura.ch= an@intel.com>; Prakashan, Krishnadas Veliyathuparambil <krishnadas.vel= iyathuparambil.prakashan@intel.com>; K N, Karthik <karthik.k.n@intel.com>= ; Lu, James <james.lu@intel.com>; Chen, Arthur G <arthur= .g.chen@intel.com>; Chiu, Chasel <chasel.chiu@intel.com>; Zimmer, Vincent <vincent.zi= mmer@intel.com>; Hsu, VictorX <victorx.hsu@intel.com>
Subject: RE: Edk2 support MIPI SyS-T TraceHub Debug Library [TraceHu= bDebugLibSysT]

 

@Kinney, Michael D

 

As we offline sync, there are below opens like below= . Have any open, please also share for us.

 

  1. Need to add TraceHub PCD into edk2/MdeModulePkg.uni at master · tianocore/edk2 · GitHub=

Answer: Will update it in next patch

  1. What about the license ?

Answer: It’s BSD license, based on public-mipi-sys-t/LICENSE at master · MIPI-Alliance/public-mipi-sys-= t (github.com)

  1. Is PcdTraceHubDebugAddress MMIO address ? If yes, why we use UINT32

Answer: It’s MMIO address, we can chang= e it to UINT64, it make sense to let the PCH more generic. Will update it i= n next patch.

  1. For TraceHubWriteCataLog64_[0-6] try to use below macro to implement it.=

#define VA_START va_start

#define VA_ARG   va_arg<= /p>

#define VA_END   va_end<= /p>

#define VA_LIST  va_list

Answer: Will update it in next patch

  1. Is have SMM or MM version ?

Answer: MdeModulePkg/Library/TraceHubDebugLib= SysT/DxeTraceHubDebugLibSyst.inf can take care for SMM case. We can rename = it like below to make it more clearly.

MdeModulePkg/Library/TraceHubDebugLibSysT/Dxe= SmmTraceHubDebugLibSyst.inf

  1. Whether have any chance to use .gitsubmodule to leverage https://gith= ub.com/MIPI-Alliance/public-mipi-sys-t.

Answer: Will draft another PR and try to use = gitsubmodule to check whether exist any predicament.

 

Thanks

Gua

 

From: Guo, Gua
Sent: Wednesday, November 23, 2022 3:29 PM
To: Kinney, Michael D <michael.d.kinney@intel.com>; gaoliming <gaoliming@byosoft.com.cn>; devel@edk2.groups.io
Cc: Chan, Laura <laura.ch= an@intel.com>; Prakashan, Krishnadas Veliyathuparambil <krishnadas.vel= iyathuparambil.prakashan@intel.com>; K N, Karthik <karthik.k.n@intel.com>= ; Lu, James <james.lu@intel.com>; Chen, Arthur G <arthur= .g.chen@intel.com>; Chiu, Chasel <chasel.chiu@intel.com>; Zimmer, Vincent <vincent.zi= mmer@intel.com>; Hsu, VictorX <victorx.hsu@intel.com>
Subject: Edk2 support MIPI SyS-T TraceHub Debug Library [TraceHubDeb= ugLibSysT]

 

@Kinney, Michael D and @gaoliming

We want to add TraceHubDebug library support on Edk2. It’s new added = library on Edk2, so it doesn’t have any backward and forward issue.

May I know have any process we may need to follo= w up. Have any comment or concern please also share for me.<= /p>

 

Reviewers/Maintainers: @Prakashan, Krishnadas Veliyathuparambil, @Chan, Laura, @K N, Karthik.

 

USF UPL spec update: https://github.c= om/UniversalScalableFirmware/documentation/pull/52 (Done)

Edk2 Bugzilla: https://bugzilla.tianocore.org/show= _bug.cgi?id=3D4144 (On-Going)

Edk2 PR: https://github.com/tianocore/edk2/pull/3613= (On-Going)

 

Background:

  •   Proble= m: In the UPL (Universal Payload) binary which contains only the Edk2 d= rivers, Tracehub debug message are missing during the execution of early DX= E Core modules (before ReportStatusCode is ready).
  •   Solution: Add TraceHub lib on Edk2, to be consumed by the UPL.

 

About TraceHubDebugLibSysT:

  • Library is consumed by the DebugLib and StatusCodeHandler to send the= PostCodes, ProgressCodes and DEBUG messages to the TraceHub/NPK in MIPI Sy= S-T format.
  • The MIPI SyS-T APIs in this library are ta= ken from the OpenSource implementation: https://gith= ub.com/MIPI-Alliance/public-mipi-sys-t.
  • Library ch= anges done for upstreaming:  MipiSystLib is rewritten to comply EDK2 c= oding standards and changed ways to pass trace address/verbosity with HOB d= irectly instead of calling into TraceHubHookLib to get these info.
  • Proposal With= UPL: consume HOB gUniversalPayloadTraceHubDebugInfoGuid to print TraceHub = Debug message in DXE Core

 

Thanks,

Gua

--_000_BL1PR11MB5478680CA7FA65D7EE13760CEFF49BL1PR11MB5478namp_--