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.web12.19212.1598535856920233553 for ; Thu, 27 Aug 2020 06:44:17 -0700 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: hpe.com, ip: 148.163.147.86, mailfrom: prvs=0508919f39=daniel.schaefer@hpe.com) Received: from pps.filterd (m0134421.ppops.net [127.0.0.1]) by mx0b-002e3701.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 07RDfhrb026559; Thu, 27 Aug 2020 13:44:16 GMT Received: from g2t2352.austin.hpe.com (g2t2352.austin.hpe.com [15.233.44.25]) by mx0b-002e3701.pphosted.com with ESMTP id 336auy19xn-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 27 Aug 2020 13:44:15 +0000 Received: from G9W8456.americas.hpqcorp.net (g9w8456.houston.hp.com [16.216.161.95]) (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 039C0A1; Thu, 27 Aug 2020 13:44:14 +0000 (UTC) Received: from G1W8107.americas.hpqcorp.net (2002:10c1:483b::10c1:483b) by G9W8456.americas.hpqcorp.net (2002:10d8:a15f::10d8:a15f) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Thu, 27 Aug 2020 13:44:14 +0000 Received: from NAM10-BN7-obe.outbound.protection.outlook.com (15.241.52.11) by G1W8107.americas.hpqcorp.net (16.193.72.59) with Microsoft SMTP Server (TLS) id 15.0.1497.2 via Frontend Transport; Thu, 27 Aug 2020 13:44:14 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=YccMK3yiHWI6sy77hbEq1Ky4xKC40/oUoDqZlFHEskI283PxItIxnbOH5GFU2+ePNV/r3r24jnYzHT/JtVpHAoMzkB+B9H/wtSCohPs1Nr3YmoDWUUbfCw85b+d0SK/hshZEPKvMoruS+J7l54dgmoh54NblnLcQUaXuR7IoRwYQmty6+BM8FPYFk5YjDwVw9fNPKg5MO5FNpRlku9TL0abIxNi6GFipKhsifVtSUHWNrwA9SgjqLL3tqWVo0bNCKt134y+93qGpwP+bGP/JWb2k+yG1N98sy013Hz8Yu/P+DnzJYMbYaxXedvPXLYkgCqlT0eWLDpZ/9gbAFShXvg== 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=vagazLUA07xBEJnTOqirtvySV+JcByprmg7w8uJWHjs=; b=RREx78LoZjjigleMIiG0r15e/fPulIGO8SCkHEI1DEKcClNCHO7mTp2ujila+GSkzr/ljKoOb49YjqmTvqcpZkXbb0eXLza8h+rN/hvp6fPucJE5VlobqVc6/+OBGDbmjwcliF/6TR3jOmHdeN4f7FBIgdn2zZ4SDi4JrWhU1efOaGkS1DH4GIDrpJKL4ZRMabh4/i4lV1Gu3l3PVnNLDrRk7wACKQS7UHuCZLUy2nm6qM9FsR6hx7tdo2hPBVFLp4LkBf0jGJyx+9xUqybjw6BCbdB1HoZeMFRaWj4n7D/9jg9qCGXhCYHF8caI7SMK3/2au5SUp2vVvSZ+9IA1PA== 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: intel.com; dkim=none (message not signed) header.d=none;intel.com; dmarc=none action=none header.from=hpe.com; Received: from DF4PR8401MB0444.NAMPRD84.PROD.OUTLOOK.COM (2a01:111:e400:760d::23) by DF4PR8401MB0859.NAMPRD84.PROD.OUTLOOK.COM (2a01:111:e400:760e::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3305.24; Thu, 27 Aug 2020 13:44:13 +0000 Received: from DF4PR8401MB0444.NAMPRD84.PROD.OUTLOOK.COM ([fe80::4cbe:3dd0:cae4:b093]) by DF4PR8401MB0444.NAMPRD84.PROD.OUTLOOK.COM ([fe80::4cbe:3dd0:cae4:b093%3]) with mapi id 15.20.3326.021; Thu, 27 Aug 2020 13:44:13 +0000 Subject: Re: [edk2-plaforms PATCH 3/3] Platform/U5SeriesPkg: Revise Readme.md To: Abner Chang , References: <20200827120305.26095-1-abner.chang@hpe.com> <20200827120305.26095-4-abner.chang@hpe.com> From: "Daniel Schaefer" CC: "leif@nuviainc.com" , Michael D Kinney Message-ID: Date: Thu, 27 Aug 2020 15:43:53 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 In-Reply-To: <20200827120305.26095-4-abner.chang@hpe.com> X-ClientProxiedBy: HK2PR03CA0048.apcprd03.prod.outlook.com (2603:1096:202:17::18) To DF4PR8401MB0444.NAMPRD84.PROD.OUTLOOK.COM (2a01:111:e400:760d::23) X-MS-Exchange-MessageSentRepresentingType: 1 Received: from 255.255.255.255 (255.255.255.255) by HK2PR03CA0048.apcprd03.prod.outlook.com (2603:1096:202:17::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3348.5 via Frontend Transport; Thu, 27 Aug 2020 13:44:11 +0000 X-Originating-IP: [111.184.28.85] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 1f11997f-73c0-4849-06ab-08d84a8f486d X-MS-TrafficTypeDiagnostic: DF4PR8401MB0859: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:4502; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: W1acOH7Efv2JWy6xU3rymTf3f16hUleWC4cYsD97sfei40pYvH5qNVFFqLZ2Hk6ZbQ9jvDGnlGt6VHY6JrgilaU3av/yBbllbiklYiSBUQYrpFgeM1fNp1SFlaggF/aHLVuRhygGEeHEfKqAK3yv5FoCQUo+fbVyWLBYO+TeYMsx7hHCloyogvsPm4QqL5IqXQ+9LmWmkIPPKRUVmWwqnGKQzanv0Zc5CBb+t2kSDkl4vfBllmyd7Zh1TRSJ8bDdOsifOMHogMOIjyXVpDvYOGe0dex8LHT9eSCwLYFcwFKdKt84ElvxyE5rsoDCsGsWdn19bsxAkdlxGASnsYny5IBqF8AqsRDUgXADt4i32fNXpMlTTbeRbbsJnkfr+pypZY6nJaItOS3Jk6AhSmkUSmZ8Cw+T/RwCoBzPU3yvTNXTLXObXmj17RyIPlRhSMXqyPSuzU+QRDsoMSeRWg97cw== 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:(396003)(366004)(136003)(376002)(39860400002)(346002)(66946007)(16576012)(52116002)(26005)(5660300002)(6666004)(66476007)(66556008)(19627235002)(83380400001)(36756003)(53546011)(2906002)(316002)(6486002)(54906003)(30864003)(8936002)(86362001)(966005)(2616005)(31696002)(478600001)(4326008)(186003)(956004)(44832011)(31686004)(8676002)(43740500002);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData: zDhCcKwICTdBh9IpJC5JiJge392TCFKgXqp3lAtS3A0o08lKPzqW4UeS+T/toKdM6rBXBQp9Dok1Kf/53JYCmZ2qg8EPGzPge19/OOGxJlmA6S/vMhWA1h4c57IMPeelHuNkFWA/X/IXpwDGdkW85saI8USmaLRiVpSh4KO1WIhSei6cMj91tYV8gxyzMSj6F+bdEF39oGQPhGpANIJC0aeU4waszfjPxjzEm2VLqzqWkYyMkUuIAsEMWCBBs+wCdkvOCkBtxkwX6NuLE/sdwj1/hSsCEImwkZ95HuCjqYXpWtf5s+BVKld/5swYgTRUQsgglyQohlwWpY3zhA9ESYTRfX6eMmSu9/LLqTbSq+HDM0iBPNKeM8PGtA1Xppybdkf7MgSsi6lM1dzNZdGtiyOZni4p7Ww/UgpttQ7XIfuxt/WXVxtrm2C3ImiwaSsa/1Lr0cXYCMPUkKHjjH9tGohFdzVD0kzarb1VbICplia9k09ZR+dPHqJuuYyv9jZk5ocInbTMlEd4sNpo6tajLSwjAmaGrgMOXe/Q+eq4Hfbrw/KzMDodZIla0i5l10FNNQ8UK/OrIQH13UlTb+sOd8vCL/q4O/qce7YRz1MuwHcurfyYC6dE4HISU5h0T/o2f1llysom5YZjDi+XCVyb7g== X-MS-Exchange-CrossTenant-Network-Message-Id: 1f11997f-73c0-4849-06ab-08d84a8f486d X-MS-Exchange-CrossTenant-AuthSource: DF4PR8401MB0444.NAMPRD84.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 27 Aug 2020 13:44:13.0947 (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: mkV40Gf7K2R5txEs6Q0DrSd3jrP7msDRjGlZG6rHBuB+ia/Lm9QbFzlrfHLPPUb/VHznYlrCiz3QAMkMzWl5zQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DF4PR8401MB0859 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.235,18.0.687 definitions=2020-08-27_07:2020-08-27,2020-08-27 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 bulkscore=0 impostorscore=0 clxscore=1015 mlxscore=0 lowpriorityscore=0 mlxlogscore=999 priorityscore=1501 phishscore=0 malwarescore=0 adultscore=0 spamscore=0 suspectscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2006250000 definitions=main-2008270103 X-MIME-Autoconverted: from 8bit to quoted-printable by mx0b-002e3701.pphosted.com id 07RDfhrb026559 Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: quoted-printable Oops, you didn't send this to Leif and Mike? On 8/27/20 2:03 PM, Abner Chang wrote: > Update RISC-V U5SeriesPkg Readme.md to align with the latest implementa= tion. >=20 > Signed-off-by: Abner Chang > Co-authored-by: Daniel Schaefer >=20 > Cc: Daniel Schaefer > --- > Platform/SiFive/U5SeriesPkg/Readme.md | 112 +++++++++++++------------= - > 1 file changed, 58 insertions(+), 54 deletions(-) >=20 > diff --git a/Platform/SiFive/U5SeriesPkg/Readme.md b/Platform/SiFive/U5= SeriesPkg/Readme.md > index 4d293e54f6..4d404efec4 100644 > --- a/Platform/SiFive/U5SeriesPkg/Readme.md > +++ b/Platform/SiFive/U5SeriesPkg/Readme.md > @@ -1,61 +1,59 @@ > -=EF=BB=BF# Introduction > -U5SeriesPkg provides the common EFI library and driver modules for SiF= ive > -U5 series core platforms. Currently the supported platforms are Freedo= m > -U500 VC707 platform and Freedom U540 HiFive Unleashed platform. > - > -Both platforms are built with below common packages, > -- **U5SeriesPkg**, edk2 platform branch > - (Currently is in edk2-platforms/devel-riscvplatforms branch) > -- **RiscVPlatformPkg**, edk2 master branch > - (Currently is in edk2-staging/RISC-V-V2 branch) > -- **RiscVPkg**, edk2 master branch > - (Currently is in edk2-staging/RISC-V-V2 branch) > +# Introduction of SiFive U5 Series Platforms > +U5SeriesPkg provides the common EDK2 libraries and drivers for SiFive = U5 series platforms. Currently the supported > +platforms are Freedom U500 VC707 platform and Freedom U540 HiFive Unle= ashed platform. > + > +Both platforms are built with below common edk2 packages under edk2-pl= atforms repository, > +- [**U5SeriesPkg**](https://github.com/tianocore/edk2-platforms/tree/m= aster/Platform/SiFive/U5SeriesPkg) > +- [**RiscVPlatformPkg**](https://github.com/tianocore/edk2-platforms/t= ree/master/Platform/RISC-V/PlatformPkg) > +- [**RiscVProcessorPkg**](https://github.com/tianocore/edk2-platforms/= tree/master/Silicon/RISC-V/ProcessorPkg) > =20 > ## U500 Platform > -This is a sample RISC-V EDK2 platform package used agaist SiFive Freed= om U500 I don't think we need to say "RISC-V EDK2" so often. > +This is a sample RISC-V EDK2 platform package used against to SiFive F= reedom U500 - RISC-V EDK2 > VC707 FPGA Dev Kit, please refer to "SiFive Freedom U500 VC707 FPGA G= etting > Started Guide" on https://www.sifive.com/documentation. > +The binary built from Platform/SiFive/U5SeriesPkg/FreedomU500VC707Boar= d can run on U500 VC707 FPGA board. > +``` > +build -a RISCV64 -t GCC5 -p Platform/SiFive/U5SeriesPkg/FreedomU500VC7= 07Board/U500.dsc > +``` > =20 > ## U540 Platform > -This is a sample RISC-V EDK2 platform package used against SiFive Free= dom U540 - RISC-V EDK2 > -HiFive Unleashed development board, please refer to "SiFive Freedom U5= 40-C000 > -Manual" on https://www.sifive.com. > -The binary built from Platform/SiFive/U5SeriesPkg/FreedomU540HiFiveUnl= eashedBoard/ > -can run on main stream [QEMU](https://git.qemu.org/?p=3Dqemu.git;a=3Ds= ummary) > -using qemu-system-riscv64 under riscv64-softmmu. Launch the binary wit= h > +This is a sample RISC-V EDK2 platform package used for the SiFive Free= dom U540 HiFive Unleashed development board, please refer to "SiFive Free= dom U540-C000 Manual" on https://www.sifive.com. - RISC-V EDK2 > +The binary built from Platform/SiFive/U5SeriesPkg/FreedomU540HiFiveUnl= eashedBoard/ can run on both hardware and > +[QEMU](https://git.qemu.org/?p=3Dqemu.git;a=3Dsummary). It is confirme= d that version 5.0 of QEMU can boot the firmware. I think here we should also say: can boot with this firmware to EFI shell= and Linux userspace. > +``` > +build -a RISCV64 -t GCC5 -p Platform/SiFive/U5SeriesPkg/FreedomU540HiF= iveUnleashedBoard/U540.dsc > +``` > +For running U540 edk2 binary on QEMU, use qemu-system-riscv64 under ri= scv64-softmmu to launch the binary with > +below parameters, > =20 > ``` > --cpu sifive-u54 -machine sifive_u > +qemu-system-riscv64 -cpu sifive-u54 -machine sifive_u -bios U540.fd -m= 2048 -nographic -smp cpus=3D5,maxcpus=3D5 > ``` > =20 > -## Download the sources > +## Download the Source Code > ``` > -git clone https://github.com/tianocore/edk2-staging.git > -# Checkout RISC-V-V2 branch > +git clone https://github.com/tianocore/edk2.git > git clone https://github.com/tianocore/edk2-platforms.git Please add --recurse-submodules here to also clone opensbi. > -# Checkout devel-riscvplatforms branch > -git clone https://github.com/tianocore/edk2-non-osi.git > ``` > - > -## Platform Owners > -Chang, Abner > -Chen, Gilbert > +Refer to [Readme.md](https://github.com/tianocore/edk2-platforms/blob/= master/Platform/RISC-V/PlatformPkg/Readme.md) for building RISC-V platfor= ms. > =20 > ## Platform Status > -Currently the binary built from U500Pkg can boot SiFive Freedom U500 V= C707 > +**FreedomU500VC707Board** > +Currently the binary built from U500 edk2 package can boot SiFive Free= dom U500 VC707 > FPGA to EFI shell with console in/out enabled. > =20 > -## Linux Build Instructions > -You can build the RISC-V platform using below script, > -`build -a RISCV64 -t GCC5 -p Platform/SiFive/U5SeriesPkg/FreedomU500V= C707Board/U500.dsc` > +**FreedomU540HiFiveUnleashedBoard** > +Currently the binary built from U540 edk2 package can boot SiFive Free= dom U540 HiFive Unleashed > +to EFI shell with console in/out enabled and Linux kernel. Please refe= r to https://github.com/riscv/riscv-uefi-edk2-docs for booting to Linux k= ernel. > =20 > ## Supported Operating Systems > -Only support to boot to EFI Shell so far. > +Please refer to https://github.com/riscv/riscv-uefi-edk2-docs. > =20 > ## Known Issues and Limitations > Only RISC-V RV64 is verified on this platform. > =20 > ## Related Materials > +- [RISC-V UEFI Documents](https://github.com/riscv/riscv-uefi-edk2-doc= s) > - [RISC-V OpenSbi](https://github.com/riscv/opensbi) > - [SiFive U500 VC707 FPGA Getting Started Guide](https://sifive.cdn.p= rismic.io/sifive%2Fc248fabc-5e44-4412-b1c3-6bb6aac73a2c_sifive-u500-vc707= -gettingstarted-v0.2.pdf) > - [SiFive Freedom U540-C000 Manual](https://sifive.cdn.prismic.io/sif= ive%2F834354f0-08e6-423c-bf1f-0cb58ef14061_fu540-c000-v1.0.pdf) > @@ -63,48 +61,54 @@ Only RISC-V RV64 is verified on this platform. > =20 > ## U5SeriesPkg Libraries and Drivers > ### PeiCoreInfoHobLib > -This is the library to create RISC-V core characteristics for building= up > -RISC-V related SMBIOS records to support the unified boot loader and O= S image. > +This is the library to create RISC-V core characteristics for building= up RISC-V related SMBIOS records to support > +the single boot loader image or OS image on the RISC-V variants Hey! That's not what we discussed ;) What about: a single boot loader and OS image for all RISC-V platforms by discovering= RISC-V hart configurations dynamically. > This library leverage the silicon libraries provided in Silicon/SiFiv= e. > =20 > ### RiscVPlatformTimerLib > -This is common U5 series platform timer library which has the > -platform-specific timer implementation. > +This is common U5 series platform timer library which has the platform= -specific timer implementation. > + > +### SerialLib > +This is common U5 series platform serial port library. > =20 > ### TimerDxe > -This is U5 series platform timer DXE driver whcih has the platform-spe= cific > -timer implementation. > +This is common U5 series platform timer DXE driver which has the platf= orm-specific timer implementation. > =20 > ## U500 Platform Libraries and Drivers > ### RiscVOpensbiPlatformLib > -In order to reduce the dependencies with RISC-V OpenSBI project > -(https://github.com/riscv/opensbi) and fewer burdens to EDK2 build pro= cess, the > -implementation of RISC-V EDK2 platform is leveraging platform source c= ode from > +In order to reduce the dependencies with RISC-V OpenSBI project (https= ://github.com/riscv/opensbi) and fewer > +burdens to EDK2 build process, the implementation of RISC-V EDK2 platf= orm is leveraging platform source code from > OpenSBI code tree. The "platform.c" under OpenSbiPlatformLib is clone= d from > -RISC-V OpenSBI code tree (in EDK2 RiscVPkg) and built based on EDK2 bu= ild > -environment. > +[RISC-V OpenSBI code tree](Silicon/RISC-V/ProcessorPkg/Library/RiscVOp= ensbiLib/opensbi) and built based on edk2 > +build environment. > =20 > ### PlatformPei > -This is the platform-implementation specific library which is executed= in early > -PEI phase for U500 platform initialization. > +This is the platform-implementation specific library which is executed= in early PEI phase for U500 platform > +initialization. > =20 > ## U540 Platform Libraries and Drivers > ### RiscVOpensbiPlatformLib > -In order to reduce the dependencies with RISC-V OpenSBI project > -(https://github.com/riscv/opensbi) and fewer burdens to EDK2 build pro= cess, the > -implementation of RISC-V EDK2 platform is leveraging platform source c= ode from > +In order to reduce the dependencies with RISC-V OpenSBI project (https= ://github.com/riscv/opensbi) and fewer > +burdens to EDK2 build process, Hm, we are depending on OpenSBI. You can say to avoid duplicating code we= use it. But we're switching to S-Mode very soon to avoid calling many internal Op= enSBI functions and instead calling the standardized SBI interface. > the implementation of RISC-V EDK2 platform is leveraging platform sourc= e code from > OpenSBI code tree. The "platform.c" under OpenSbiPlatformLib is clone= d from > -RISC-V OpenSBI code tree (in EDK2 RiscVPkg) and built based on EDK2 bu= ild > -environment. > +[RISC-V OpenSBI code tree](Silicon/RISC-V/ProcessorPkg/Library/RiscVOp= ensbiLib/opensbi) and built based on edk2 > +build environment. > =20 > ### PlatformPei > -This is the platform-implementation specific library which is executed= in early > -PEI phase for U540 platform initialization. > +This is the platform-implementation specific library which is executed= in early PEI phase for U540 platform > +initialization. > =20 > ## U5SeriesPkg Platform PCD settings > =20 > | **PCD name** |**Usage**| > |----------------|----------| > +|PcdU5PlatformSystemClock| U5 series platform system clock| > |PcdNumberofU5Cores| Number of U5 core enabled on U5 series platform| > |PcdE5MCSupported| Indicates whether the Monitor Core (E5) is support= ed on U5 series platform| > |PcdU5UartBase|Platform serial port base address| > + > + > +## Platform Owners > +Chang, Abner > +Chen, Gilbert > +Schaefer, Daniel > \ No newline at end of file >=20