From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0a-002e3701.pphosted.com (mx0a-002e3701.pphosted.com [148.163.147.86]) by mx.groups.io with SMTP id smtpd.web10.12675.1606839507636652495 for ; Tue, 01 Dec 2020 08:18:27 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@hpe.com header.s=pps0720 header.b=OzTK8ox6; spf=pass (domain: hpe.com, ip: 148.163.147.86, mailfrom: prvs=060493cc9a=daniel.schaefer@hpe.com) Received: from pps.filterd (m0150242.ppops.net [127.0.0.1]) by mx0a-002e3701.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 0B1G3FNb029807; Tue, 1 Dec 2020 16:18:14 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hpe.com; h=from : to : cc : subject : date : message-id : content-type : content-transfer-encoding : mime-version; s=pps0720; bh=MHTkAuPl/agmyd6NYSYXogiEDWRh3yIjj9sCLE26eME=; b=OzTK8ox6+ANJybAcWUaXv0ZUQithvVSEozi7/nEbXNrOcFW+omTMQtAh0Ae4w+8L8Zez 1PcAdlOfXh+jjkUo87qLrvDYijgJQlaql6PvB7c9a7ClCx61KV4u33kyR99ORZ5ud3rX 5e9w/A7rI9gPkYLSNLkxANVXDZEaRsGRs6WABUgdcdQ52befeJ7o/V+/OH2tSyl/qWXn WF8u61kaXQbUXl4LADO0m2Tta139deJTcLmUidnNbkfo+/5r3ss6s6bRg7fGzr3QZSP5 5UTlhsPTsTY18DT96+ryK8wpxDVjw+nNXF1S37eAchwGKJhee8T/KbpljTc3Y4o/2LBg pQ== Received: from g2t2352.austin.hpe.com (g2t2352.austin.hpe.com [15.233.44.25]) by mx0a-002e3701.pphosted.com with ESMTP id 3540mfku3f-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 01 Dec 2020 16:18:14 +0000 Received: from G9W8454.americas.hpqcorp.net (exchangepmrr1.us.hpecorp.net [16.216.161.4]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by g2t2352.austin.hpe.com (Postfix) with ESMTPS id E248962; Tue, 1 Dec 2020 16:18:11 +0000 (UTC) Received: from G4W9119.americas.hpqcorp.net (2002:10d2:14d6::10d2:14d6) by G9W8454.americas.hpqcorp.net (2002:10d8:a104::10d8:a104) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Tue, 1 Dec 2020 16:18:11 +0000 Received: from NAM04-BN3-obe.outbound.protection.outlook.com (15.241.52.11) by G4W9119.americas.hpqcorp.net (16.210.20.214) with Microsoft SMTP Server (TLS) id 15.0.1497.2 via Frontend Transport; Tue, 1 Dec 2020 16:18:11 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=MaOyEYKcs22V4pG/LsToi9gY3sRHhi7EASJQQ9rlxUpHK/GbCX26nbOAadNPiQAJ5fwZTsAwxzrCr8YR7FTbJCmCgnqM8kBOzO1crkYCZi9fKcaeuiCFUcHNejnToNEriElMRiyXCoh59oRdMioncTDzQeDxSZdwFBkSNtV9wC5lzjfGS7oebQJ37FxN+U/PDCQ1Xlwa+gCkEH6uFhLytsX4YCw2aydoF3TOK0ucgdBWH2FKv1mxPAh1qWeLj3f4HQT9Tr3+4APDBP0bR/C5H2f1OOy/C/azuTFZER7wV/+8zcPBD/DeE5449kyF+wIMU2dJOGzYHfxq4h5ZLGI9zQ== 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-SenderADCheck; bh=MHTkAuPl/agmyd6NYSYXogiEDWRh3yIjj9sCLE26eME=; b=DDd2+dLr1P2ULZsoW7RDL7FzKLGUCvfOsT6IbFp/IGwk7oHrFhrIMDXsxRhPb0EWI9YXUwjq9Kk0hoNqd/RC18v+uG9xNOaKovW0K1FuWqZQy52f3oDrqabBflK9ZuQB67Lxj/HJnTCNZxYDuUXXean2ytPAmwsqaOn4cyPeAxgiE8TxEgg6367KbHCL2//KlEdK/yhlVRGWz3CQ7bTPYVS+mumcAlexcXlIdmh12NR1zBJZ4RqyQd4K2QB57DtpVQ7f0j5lruZoMsb9uC96LJuxtMS2QbOaVrz+foh/tUWwuIJUSq5Lv4kT6gVldyTNZmgc0cQ1S1EGHCemApkCbg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=hpe.com; dmarc=pass action=none header.from=hpe.com; dkim=pass header.d=hpe.com; arc=none Authentication-Results: edk2.groups.io; dkim=none (message not signed) header.d=none;edk2.groups.io; dmarc=none action=none header.from=hpe.com; Received: from DF4PR8401MB0444.NAMPRD84.PROD.OUTLOOK.COM (2a01:111:e400:760d::23) by DF4PR8401MB1004.NAMPRD84.PROD.OUTLOOK.COM (2a01:111:e400:760f::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3632.17; Tue, 1 Dec 2020 16:18:10 +0000 Received: from DF4PR8401MB0444.NAMPRD84.PROD.OUTLOOK.COM ([fe80::691c:7962:6e56:c91f]) by DF4PR8401MB0444.NAMPRD84.PROD.OUTLOOK.COM ([fe80::691c:7962:6e56:c91f%8]) with mapi id 15.20.3611.025; Tue, 1 Dec 2020 16:18:10 +0000 From: "Daniel Schaefer" To: CC: Leif Lindholm , Heinrich Schuchardt , Abner Chang , Gilbert Chen , Eric Jin , G Edhaya Chandran , Barton Gao , Samer El-Haj-Mahmoud Subject: [edk2-test PATCH v1 0/2] Add RISCV64 support to SctPkg Date: Wed, 2 Dec 2020 00:17:50 +0800 Message-ID: <20201201161752.23734-1-daniel.schaefer@hpe.com> X-Mailer: git-send-email 2.28.0 X-Originating-IP: [123.193.51.23] X-ClientProxiedBy: HK2PR02CA0161.apcprd02.prod.outlook.com (2603:1096:201:1f::21) To DF4PR8401MB0444.NAMPRD84.PROD.OUTLOOK.COM (2a01:111:e400:760d::23) X-MS-Exchange-MessageSentRepresentingType: 1 Received: from x360-nix.hitronhub.home (123.193.51.23) by HK2PR02CA0161.apcprd02.prod.outlook.com (2603:1096:201:1f::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3611.20 via Frontend Transport; Tue, 1 Dec 2020 16:18:07 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 8da1f5d4-2c41-4f72-088a-08d89614b1d9 X-MS-TrafficTypeDiagnostic: DF4PR8401MB1004: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:9508; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: BF1OYkF+79G6Jo2yACv1m6h069JviAygXQrsSodvkMMrH5jaGN5dEnEs8naRKOmqypKhKgsiXGbK7NnKVGjN2hKNPQrmhnGgZlPKH7g8DAS0H9bLbEI0wsAn2fqr1IvIC1yjk3/XmhEW2kORZyOewlL592oLmvqcmKpfWaH/pO5Ii5cBbsYXLozLqJbkQKdjChruekblyiup74hd/FCSpWX72aRW4ru6R3bsjE0ypEyPKStn7DJTE0FekwjePYryMEoK14pFQC1Pf5BSZZ/8OebjAwMpAFzLeYSjtACUcscU53wDz3QpY8Nq++2L1eCyznMQqwtxLM7eS4hatRj4TKldJPPMLJQB2eBT8tPmznmYrIvxjWB2PSl+miyMSTbH9f779Z+7a9o2Z7TsL6YV5FylwRC1L47EFMdY/257CHsxOa1K7pg4OcNEQy35ygEEEAaYQPYy6lKncyWT+aWZKkc3wU3aw55LSptHzjGJAUc= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DF4PR8401MB0444.NAMPRD84.PROD.OUTLOOK.COM;PTR:;CAT:NONE;SFS:(136003)(366004)(346002)(39860400002)(376002)(396003)(2906002)(16526019)(1076003)(54906003)(6486002)(8676002)(478600001)(52116002)(4326008)(36756003)(966005)(83380400001)(186003)(8936002)(956004)(2616005)(66946007)(66476007)(316002)(66556008)(6512007)(44832011)(6506007)(5660300002)(6666004)(86362001)(26005)(19627235002)(6916009)(17423001)(156123004);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData: =?us-ascii?Q?gEF8tRr0QrhpLFy3cGofoxrUw8tLYYt/n2+m37DZvQQvi5eb+x6JDLjyx6xA?= =?us-ascii?Q?1y0RwB84sgjmZy7UVGphbvOP2VHrj+fhPdquo4tsKCpUs4hpCjXeQHaten8p?= =?us-ascii?Q?u+6Ly9TufrBGXrh2JugJFz7He6krDUpTRaN6qwX4oNjpGbTmDYDRYA44KAL1?= =?us-ascii?Q?8MuPCif7ofTIlOKrgMT39KN61Yeu3hHyIqaXJOiQmuBq8WNYsBC8x7fu3UR2?= =?us-ascii?Q?wSvoLdpOsZW54tUtrQAQVZ4H8fZGJx1hGmIwf4NPsLE7wT5U4ZMT2naPTMjv?= =?us-ascii?Q?ESornDvpVBpKVhmonJG5KAY73Wb4IxIlDJnWItVTPMYL+noc1lqUgHLWv6BB?= =?us-ascii?Q?JK9b3YrwtEO6XNrMe5Qw3Q2UIQLNv6gMn+FTW52fYZj+i1PioS6J+q4xreyo?= =?us-ascii?Q?LDmP2/i7/kyLi1VwCtdM9T1RJgimobHmOUjHFT588Ap9regcGJLWnQimzLnv?= =?us-ascii?Q?Bze13iiBKW/35isdYLpkFV4hRPIKioZR3hAmnxAEDCwMzpAhaNGVu35/OcHe?= =?us-ascii?Q?KQy9dD624MFmsmHMxKKE0b8/a+Xs3QJZNGTspfTjZlLIdPFCHu4RzZpf5Jqv?= =?us-ascii?Q?FnoKXPRkU3ndyC2inWxBynzUXwW5X9xB8WNCg2vXfIcV80LqA9J5X4UUwdfg?= =?us-ascii?Q?9s8Ls117XnCGZX8LWgHAGMh1v4h5CvYGpGxsR7XzbtxeO6vMbHDcjk2mtge7?= =?us-ascii?Q?9UjoH1XAEUex73rc/YoUA69driV8sq0r20MjxqYf9zw3nVerJK8aC0fDpbEu?= =?us-ascii?Q?mX3XN3I1+lRZYUjO0mpB5p6kBmT3/Da0EGlZ6srdK3pzQQJwgOd7SjueZ9vV?= =?us-ascii?Q?ydqaXLj2rq/h50BZmnZosv4a5KUmmXtlnUTTrHpWYN2VjMibllm+qclWCvQd?= =?us-ascii?Q?iPBJ4Hqf0lX4HpdNhnorCGKTD4QfC7ML5b2tfyABI6WfMjjArlrnpkNgQHDL?= =?us-ascii?Q?LAUVgd8G4mLSuriPEfy9u9fmE3DXn+Z+k46veiW6jCFhMRHc0UpmDjlCe6TI?= =?us-ascii?Q?CfTi?= X-MS-Exchange-CrossTenant-Network-Message-Id: 8da1f5d4-2c41-4f72-088a-08d89614b1d9 X-MS-Exchange-CrossTenant-AuthSource: DF4PR8401MB0444.NAMPRD84.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 01 Dec 2020 16:18:10.2387 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 105b2061-b669-4b31-92ac-24d304d195dc X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: OtiNkc5h4FhoBNhTtpTVKTTAWCAOBBWwqYWBf92iEMxFi9qz4BpGZDGpNg9raDfkUEeHRY1/FMfO6BL99NBiaA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DF4PR8401MB1004 X-OriginatorOrg: hpe.com X-Proofpoint-UnRewURL: 0 URL was un-rewritten MIME-Version: 1.0 X-HPE-SCL: -1 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.312,18.0.737 definitions=2020-12-01_07:2020-11-30,2020-12-01 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 bulkscore=0 spamscore=0 malwarescore=0 lowpriorityscore=0 clxscore=1011 phishscore=0 priorityscore=1501 suspectscore=1 mlxscore=0 adultscore=0 impostorscore=0 mlxlogscore=461 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2012010101 Content-Type: text/plain Content-Transfer-Encoding: 8bit REF:https://bugzilla.tianocore.org/show_bug.cgi?id=3042 With this patch series we can build the UEFI SCT for RISCV64. It was confirmed to be working on the U-Boot UEFI implementation by Heinrich. It hasn't been tested on EDK2 yet. Build requirements are the same as for the EDK2 RISCV64 port and detailed here: https://github.com/riscv/riscv-uefi-edk2-docs The second patch is a big one because it adds architecture specific files by copying them from the Aarch64 directory. Only a single file, an assembly file needed modifications. I'm not sure why the other ones are in an architecture specific directory. They're all C files and seem to be generic. We can probably unify them. Cc: Leif Lindholm Cc: Heinrich Schuchardt Cc: Abner Chang Cc: Gilbert Chen Cc: Eric Jin Cc: G Edhaya Chandran Cc: Barton Gao Cc: Samer El-Haj-Mahmoud Daniel Schaefer (2): SctPkg: Add RISCV64 support SctPkg: Enable RISCV64 support using AARCH64 sources uefi-sct/SctPkg/Application/InstallSct/InstallSctDef.h | 3 + uefi-sct/SctPkg/Library/SctLib/Riscv64/SctLibPlat.h | 32 +++ uefi-sct/SctPkg/Library/SctLib/Riscv64/initplat.c | 45 ++++ uefi-sct/SctPkg/Library/SctLib/SctLib.inf | 6 + uefi-sct/SctPkg/SCRT/SCRTApp/Riscv64/GoVirtual.S | 45 ++++ uefi-sct/SctPkg/SCRT/SCRTApp/Riscv64/VirtualMemory.c | 182 +++++++++++++ uefi-sct/SctPkg/SCRT/SCRTApp/SCRTApp.inf | 6 + uefi-sct/SctPkg/SCRT/SCRTDriver/Riscv64/Debug.c | 88 +++++++ uefi-sct/SctPkg/SCRT/SCRTDriver/Riscv64/Dump.c | 68 +++++ uefi-sct/SctPkg/SCRT/SCRTDriver/Riscv64/Io.c | 134 ++++++++++ uefi-sct/SctPkg/SCRT/SCRTDriver/Riscv64/Io.h | 48 ++++ uefi-sct/SctPkg/SCRT/SCRTDriver/SCRTDriver.inf | 7 + uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/DebugSupport/BlackBoxTest/DebugSupportBBTest.inf | 6 + uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/DebugSupport/BlackBoxTest/Riscv64/DebugSupportBBTestCacheFunction.c | 137 ++++++++++ uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/DebugSupport/BlackBoxTest/Riscv64/DebugSupportBBTestExceptionCallbackFunction.c | 276 ++++++++++++++++++++ uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/DebugSupport/BlackBoxTest/Riscv64/PlatformIsa.c | 30 +++ uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/Usb2Hc/BlackBoxTest/Usb2HcTest.inf | 4 + uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/UsbHc/BlackBoxTest/Riscv64/TimerInterrupt.c | 51 ++++ uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/UsbHc/BlackBoxTest/UsbHcTest.inf | 4 + uefi-sct/SctPkg/TestInfrastructure/SCT/Framework/ENTS/EasLib/EntsLib.inf | 5 + uefi-sct/SctPkg/TestInfrastructure/SCT/Framework/ENTS/EasLib/Riscv64/EntsLibPlat.h | 55 ++++ uefi-sct/SctPkg/TestInfrastructure/SCT/Framework/ENTS/EasLib/Riscv64/InitPlat.c | 55 ++++ uefi-sct/SctPkg/Tools/Source/GenBin/GNUmakefile | 3 + uefi-sct/SctPkg/UEFI/IHV_SCT.dsc | 14 +- uefi-sct/SctPkg/UEFI/Protocol/DebugSupport.h | 62 ++++- uefi-sct/SctPkg/UEFI/UEFI_SCT.dsc | 14 +- uefi-sct/SctPkg/build.sh | 10 +- 27 files changed, 1386 insertions(+), 4 deletions(-) create mode 100644 uefi-sct/SctPkg/Library/SctLib/Riscv64/SctLibPlat.h create mode 100644 uefi-sct/SctPkg/Library/SctLib/Riscv64/initplat.c create mode 100644 uefi-sct/SctPkg/SCRT/SCRTApp/Riscv64/GoVirtual.S create mode 100644 uefi-sct/SctPkg/SCRT/SCRTApp/Riscv64/VirtualMemory.c create mode 100644 uefi-sct/SctPkg/SCRT/SCRTDriver/Riscv64/Debug.c create mode 100644 uefi-sct/SctPkg/SCRT/SCRTDriver/Riscv64/Dump.c create mode 100644 uefi-sct/SctPkg/SCRT/SCRTDriver/Riscv64/Io.c create mode 100644 uefi-sct/SctPkg/SCRT/SCRTDriver/Riscv64/Io.h create mode 100644 uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/DebugSupport/BlackBoxTest/Riscv64/DebugSupportBBTestCacheFunction.c create mode 100644 uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/DebugSupport/BlackBoxTest/Riscv64/DebugSupportBBTestExceptionCallbackFunction.c create mode 100644 uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/DebugSupport/BlackBoxTest/Riscv64/PlatformIsa.c create mode 100644 uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/UsbHc/BlackBoxTest/Riscv64/TimerInterrupt.c create mode 100644 uefi-sct/SctPkg/TestInfrastructure/SCT/Framework/ENTS/EasLib/Riscv64/EntsLibPlat.h create mode 100644 uefi-sct/SctPkg/TestInfrastructure/SCT/Framework/ENTS/EasLib/Riscv64/InitPlat.c -- 2.28.0