Skip to content
This repository was archived by the owner on Dec 1, 2022. It is now read-only.

Commit 704caf0

Browse files
Test DevTest Dev
Test Dev
authored and
Test Dev
committed
CEP Release v3.41
1 parent cd12a2b commit 704caf0

File tree

195 files changed

+1877
-2450
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

195 files changed

+1877
-2450
lines changed

.DS_Store

-6 KB
Binary file not shown.

README.md

+14-12
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
<img src="./doc/cep_logo.jpg" width="721" height="300">
99
</p>
1010
<p align="center">
11-
<img src="./doc/version3.4.jpg" width="98" height="60">
11+
<img src="./doc/version3.41.jpg" width="98" height="60">
1212
</p>
1313
<p align="center">
1414
Copyright 2021 Massachusetts Institute of Technology
@@ -17,11 +17,9 @@
1717
<img src="./doc/related_logos.jpg" width="450" height="71">
1818
</p>
1919

20-
The Common Evaluation Platform (CEP) is intended as a surrogate System on a Chip (SoC) that provides users an open-source evaluation platform for the evaluation of custom tools and techniques. An extensive verification environment is provided to ensure the underlying functionality is maintained even after modification.
20+
The Common Evaluation Platform (CEP) is an Open Source Hardware (OSH) System on a Chip (SoC). It has been developed to support the test and evluation of custom tools and techniques. An extensive verification environment is provided to ensure the underlying functionality is maintained even after modification.
2121

22-
The Logic Locking Key Interface (LLKI) has been provided as a representative means of distributing key / configuration material to LLKI-enabled cores.
23-
24-
For CEP v3.1+, the full LLKI has been added. This includes the Surrogate Root of Trust (SRoT) and mock Technique Specific Shims (TSS) for all accelerator cores.
22+
The Lincoln Laboratory Key Interface (LLKI) has been provided as a representative means of distributing key / configuration material to LLKI-enabled cores.
2523

2624
### Please check the [Release Notes](./RELEASE_NOTES.md) to understand what has changed and a list of known issues.
2725

@@ -206,7 +204,7 @@ See ./cosim/drivers/diag/cepMacroMix.cc for example code.
206204
207205
As one might be aware: the endianess usage is not consistent thru out the design, expesially where Chisel wrappers are used to connect to various HW cores. For some cores, little endian is used for loading keys/plain text but big-endian is used to produce cipher text as output. This creates confusion and inconsistent as one might try to understand/follow SW driver for these cores. Also, please note, RISCV is little endian.
208206
209-
As of release CEP v2.4 and later, unless otherwise specify, big endian is used thru out the design to match key/plain/ciphertext network order.
207+
Unless otherwise specified, big endian is used thru out the design to match key/plain/ciphertext network order.
210208
211209
This makes it consistent and easier to debug when key/plain text are printed to match against registers.
212210
@@ -311,11 +309,15 @@ make install append
311309

312310
If subsequent changes are made to the source code in <CEP_ROOT>/cosim/drivers/linux, simply copy the changes over to the Linux build by running `make install`.
313311

314-
Next, one needs to build linux. First, change to the `<CEP ROOT>/software/freedom-u-sdk` directory. Ensure that the linux variant of the RISC-V toolset is used by executing `unset RISCV`
315312

316-
For Ubuntu 18.04 LTS, the default PERL installation may cause a conflict with the build process. You may need to execute `unset PERL_MM_OPT` if set.
313+
Next, one needs to build linux. First, change to the `<CEP ROOT>/software/freedom-u-sdk` directory.
314+
315+
A few cautionary notes:
316+
- Ensure that the linux variant of the RISC-V toolset is used by executing `unset RISCV`
317+
- For Ubuntu 18.04 LTS, the default PERL installation may cause a conflict with the build process. You may need to execute `unset PERL_MM_OPT` if set.
318+
- If you patched the LIBRARY_PATH environment variable to allow for compilation of the Xilinx simulation libraries, this may cause the linux build to fail
317319

318-
Begin the build by running `make -jN BOARD=vc707devkit_nopci all` where N is the numbers of cores you can dedicate to the build. Ensure that you have NOT sourced the Xilinx Vivado environment setup script before running this step.
320+
Begin the build by running `make -jN BOARD=vc707devkit_nopci all` where N is the numbers of cores you can dedicate to the build.
319321

320322
Following the linux build, which can take 30 - 60 minutes, you will have a binary which you can load onto an SD card.
321323

@@ -342,7 +344,7 @@ You should see the following logo/text appear:
342344
./+++++++++++oo+++: +oo++o++++o+o+oo+oo.- `s+++s`-
343345
.--:---:-:-::-::` -::::::::::::::::::. :::::.
344346
345-
Common Evaluation Platform v3.40
347+
Common Evaluation Platform v3.41
346348
Copyright 2021 Massachusetts Institute of Technology
347349
348350
Built upon the SiFive Freedom U500 Platform using
@@ -365,7 +367,7 @@ At the command prompt, you can run the CEP diagnostics by commanding `cep_diag`.
365367
A partial output should be similar to:
366368

367369
```sh
368-
*** CEP SW=0x3.40 HW VERSION = v3.40 was built on Aug 5 2021 08:36:41 ***
370+
*** CEP SW=0x3.41 HW VERSION = v3.41 was built on Aug 5 2021 08:36:41 ***
369371
CEP FPGA Physical: cepReg/ddr3/other/sys -> Virtual=0x700000000, 0x800000000, 0x600000000, 0xc00000000
370372
ScratchPad=0x2000400000
371373
gSkipInit=0/0
@@ -428,7 +430,7 @@ The following cores have been integrated into the "standard" CEP build:
428430
- Infinite Impulse Response
429431
- GPS code generator
430432

431-
Beginning with the v2.4 release, the following "generated" cores have been added to the repository, but are currently not integrated into the CEP build.
433+
The following "generated" cores have been added to the repository, but are currently not integrated into the CEP build.
432434
- A(EE)ES-WB : Advanced Egregiously Extended Encryption Standard - Whitebox Edition [./hdl_cores/aeees/README.md](./hdl_cores/aeees/README.md).
433435
- (RI)IIR : Randomly Indeterminate Infinite Impulse Response [./hdl_cores/auto-fir/README.md](./hdl_cores/auto-fir/README.md).
434436
- SHA(AA) : Secure Hash Algorithm Arbitrarily Augment [./hdl_cores/shaaa/README.md](./hdl_cores/shaaa/README.md).

RELEASE_NOTES.md

+7
Original file line numberDiff line numberDiff line change
@@ -144,4 +144,11 @@ v3.4 - (6 August 2021)
144144
* Scratchpad RAM changed to blackbox implementation to facilitate ASIC development
145145
* OpenSSL replaced by Cryptopp for crypto-related tests (cosim + linux)
146146

147+
v3.41 - (10 September 2021)
148+
* CEP Configuration nows includes 4xGPS and 4xSHA-256 cores
149+
* Integrated configurable co-simulation environment (provide a co-sim that can more easily adapt to CEP architecture changes)
150+
* Known Issues:
151+
- Some idft test vectors fail under QuestaSim (xcellium regression ran successfully)
152+
- Multithreaded test (#23) non-functional under linux
153+
147154
#### Return to the root CEP [README](./README.md)

cosim/.DS_Store

0 Bytes
Binary file not shown.

cosim/.gitignore

+5-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
.Xil/
22
xil_lib/
3+
.xil_lib/
34
.cxl.ip/
45
.cxl*
56
*.log*
@@ -8,6 +9,7 @@ xil_lib/
89
*.bin
910
**/*.o
1011
**/*.obj
12+
**/*.bobj
1113
**/*.hex
1214
**/*.a
1315
**/*.KEY
@@ -16,6 +18,7 @@ modelsim.ini*
1618
**/c_dispatch
1719
**/testHistory.txt
1820
vsim.do
21+
.c_children.mk
1922
**/transcript
2023
**/*.wlf
2124
**/*.dump
@@ -25,4 +28,5 @@ dvt/behav_models/ddr3.v
2528
include/cep_adrMap.h
2629
include/v2c_cmds.h
2730
lib/dll/libvpp.so
28-
31+
lib/libvpp.so
32+
lib/.buildLibs

cosim/README.md

+18-6
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
# README for CEP co-simulation environment
88

9-
This SW/HW co-simulation evironment has been developed to support "chip-level" simulation of the CEP.
9+
This SW/HW co-simulation evironment has been developed to support "chip-level" simulation of the CEP.
1010

1111
Several environments are supported:
1212

@@ -25,19 +25,19 @@ Several environments are supported:
2525

2626
* SW and HW are de-coupled such that mistakes that are found in the test/driver (SW side) during development process can be quickly corrected and rerun without having to rebuild the HW. Sometimes, it might takes minutes (or even hours for big ASIC) just to rebuild the HW if test and DUT (Device Under Test) are tightly coupled
2727

28-
* Makefile is setup to support vendor independent designs such that same design can be used to target FPGA vendor as Xilinx or TSMC for ASIC, for example.
28+
* Makefile is setup to support vendor independent designs such that the same design can be used to target an FPGA vendor such as Xilinx or TSMC for ASIC.
2929

3030
* To take advantage of multi-core machines, support up to 4K+ threads where all threads can run in parallel and target different HW sections. For example: one core can target the AES block while another core targets the FIR block, etc...
3131

3232
* Mailboxes are setup to support in between thread communication for synchronization, handshaking, etc...
3333

34-
* All are *makefile* driven with scripts to support auto-dependencies generation. Which means anything changes in either HW files or SW files: incremental builds will be called to save time. This is a must in order to support parallel batching.
34+
* All are *makefile* driven with scripts to support auto-dependencies generation. Which means when anything changes in either HW files or SW files, incremental builds will be called to save time. This is a must in order to support parallel batching.
3535

3636
* Provide 100% visibility to everything in the test bench via wave capturing. From the SW (test) side, any signal in HW can be observed and forced (for negative testing) or to be used to synchronize events (wait for something before sending packet, etc...)
3737

3838
* Same setup can be used for any design. Therefore, it takes only hour to set up new test bench for new design and let designer/verification engineers start writing tests right away.
3939

40-
* Most of the tests can even be re-used across multiple projects such as memory test, register tests, packet generator and checker. They are written as template where only simple read/write methods need to be overload.
40+
* Most of the tests can even be re-used across multiple projects such as memory test, register tests, packet generator and checker. They are written as templates where only simple read/write methods need to be overload.
4141

4242
* Open source codebase
4343

@@ -66,7 +66,19 @@ For CEP, the path to tools required are as listed below (see **common.make**)
6666
SIMULATOR_PATH ?= /opt/questa-2019.1/questasim/bin
6767
RISCV ?= /opt/riscv
6868

69-
**NOTE**: If they are not matched your setup, dont need to edit the common.make file, use enviroment variables to override as such (assuming bash shell is used).
69+
As of release 3.2 or later, Cadence tool set is also supported, all setup related to Cadence tool set can be found in `cadence.make`
70+
71+
If you decide to use Cadence's xcelium for simulation, modify cadence.make or override with environment variables to match the below variables:
72+
73+
```
74+
export VMGR_VERSION ?= VMANAGERAGILE20.06.001
75+
export XCELIUM_VERSION ?= XCELIUMAGILE20.09.001
76+
77+
export VMGR_PATH ?= /brewhouse/cad4/x86_64/Cadence/${VMGR_VERSION}
78+
export XCELIUM_INSTALL ?= /brewhouse/cad4/x86_64/Cadence/${XCELIUM_VERSION}
79+
```
80+
81+
**NOTE**: If they are not matched to your setup, you dont need to edit the common.make file. Instead, use enviroment variables to override as such (assuming bash shell is used).
7082
```
7183
export VIVADO_PATH=<Your_path_to_Vivado_tool>
7284
export SIMULATOR_PATH=<Your_path_to_questa_tool>
@@ -116,7 +128,7 @@ You should see something like this under *cosim* directory:
116128

117129
## Compiling the Xilinx Simulation Libraries ##
118130

119-
**NOTE**: xil_lib is the generated library packages created via vivado 's compile_simlib command. Not all Vivado / Modelsim version combinations yield the desired result. See the following notes:
131+
**NOTE**: xil_lib is the generated library packages created via vivado's compile_simlib command. Not all Vivado / Modelsim version combinations yield the desired result. See the following notes:
120132
- When Vivado 2019.1 and Questa 2019.1 is selected ,the compilation will stop and not generate the appropriate modelsim.ini file, which is required by the co-simulation environemt.
121133
- When Vivado 2018.3 and Questa 2019.1 (or Quest 10.7c) is selected, the compilation will return with an error in the qdma_v3_0_0 library. This library is not required for CEP simulation and thus the error can be safely ignored.
122134
- When Vivado 2018.3 and Question 10.6c is selected, the compilation will complete without error. However, it is recommended that Questa 2019.1 be used in order to take advantage of optimizations and bug fixes.

cosim/bareMetalTests/.DS_Store

0 Bytes
Binary file not shown.

cosim/bfmTests/Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#//************************************************************************
22
#// Copyright 2021 Massachusetts Institute of Technology
3-
#// SPDX License Identifier: MIT
3+
#// SPDX License Identifier: BSD-2-Clause
44
#//
55
#// File Name:
66
#// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/ddr3Test/Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#//************************************************************************
22
#// Copyright 2021 Massachusetts Institute of Technology
3-
#// SPDX License Identifier: MIT
3+
#// SPDX License Identifier: BSD-2-Clause
44
#//
55
#// File Name:
66
#// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/fragmentors/cepFragmentorTest.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//************************************************************************
22
// Copyright 2021 Massachusetts Institute of Technology
3-
// SPDX License Identifier: MIT
3+
// SPDX License Identifier: BSD-2-Clause
44
//
55
// File Name:
66
// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/fragmentors/cepFragmentorTest.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//************************************************************************
22
// Copyright 2021 Massachusetts Institute of Technology
3-
// SPDX License Identifier: MIT
3+
// SPDX License Identifier: BSD-2-Clause
44
//
55
// File Name:
66
// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/lockTest/Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#//************************************************************************
22
#// Copyright 2021 Massachusetts Institute of Technology
3-
#// SPDX License Identifier: MIT
3+
#// SPDX License Identifier: BSD-2-Clause
44
#//
55
#// File Name:
66
#// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/macroMix/Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#//************************************************************************
22
#// Copyright 2021 Massachusetts Institute of Technology
3-
#// SPDX License Identifier: MIT
3+
#// SPDX License Identifier: BSD-2-Clause
44
#//
55
#// File Name:
66
#// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/macroMix/c_dispatch.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//************************************************************************
22
// Copyright 2021 Massachusetts Institute of Technology
3-
// SPDX License Identifier: MIT
3+
// SPDX License Identifier: BSD-2-Clause
44
//
55
// File Name:
66
// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/macroMix/c_dispatch.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//************************************************************************
22
// Copyright 2021 Massachusetts Institute of Technology
3-
// SPDX License Identifier: MIT
3+
// SPDX License Identifier: BSD-2-Clause
44
//
55
// File Name:
66
// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/macroMix/c_module.cc

+22-19
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//************************************************************************
22
// Copyright 2021 Massachusetts Institute of Technology
3-
// SPDX License Identifier: MIT
3+
// SPDX License Identifier: BSD-2-Clause
44
//
55
// File Name:
66
// Program: Common Evaluation Platform (CEP)
@@ -54,27 +54,30 @@ void *c_module(void *arg) {
5454
// ======================================
5555
// Test starts here
5656
// ======================================
57-
// MUST
58-
// wait until Calibration is done..
59-
//int calibDone = calibrate_ddr3(50);
57+
// MUST wait until Calibration is done..
6058
pio.RunClk(1000);
61-
//
59+
60+
int mask = seed; // seed is used as cpuActiveMask from c_dispatch
6261

63-
// Select which tests to run. Core indicies are defined in CEP.h
64-
int mask = seed; // seed is used as cpuActiveMask from c_displatch
65-
int cryptoMask = 0xFFFFFFFF; // all cores
66-
// int cryptoMask = 0x00000001; // AES only
67-
// int cryptoMask = 0x00000002; // MD5 only
68-
// int cryptoMask = 0x00000004; // SHA256 only
69-
// int cryptoMask = 0x00000008; // RSA only
70-
// int cryptoMask = 0x00000010; // DES3 only
71-
// int cryptoMask = 0x00000020; // DFT only
72-
// int cryptoMask = 0x00000040; // IDFT only
73-
// int cryptoMask = 0x00000080; // FIR only
74-
// int cryptoMask = 0x00000100; // IIR only
75-
// int cryptoMask = 0x00000200; // GPS only
62+
int coreMask = 0xFFFFFFFF; // all cores
63+
// int coreMask = 0x00000001; // AES
64+
// int coreMask = 0x00000002; // MD5
65+
// int coreMask = 0x00000004; // SHA256.0
66+
// int coreMask = 0x00000008; // SHA256.1
67+
// int coreMask = 0x00000010; // SHA256.2
68+
// int coreMask = 0x00000020; // SHA256.3
69+
// int coreMask = 0x00000040; // RSA
70+
// int coreMask = 0x00000080; // DES3
71+
// int coreMask = 0x00000100; // DFT
72+
// int coreMask = 0x00000200; // IDFT
73+
// int coreMask = 0x00000400; // FIR
74+
// int coreMask = 0x00000800; // IIR
75+
// int coreMask = 0x00001000; // GPS.0
76+
// int coreMask = 0x00002000; // GPS.1
77+
// int coreMask = 0x00004000; // GPS.2
78+
// int coreMask = 0x00008000; // GPS.3
7679

77-
if (!errCnt) { errCnt = cepMacroMix_runTest(cpuId, mask, cryptoMask, seed, verbose); }
80+
if (!errCnt) { errCnt = cepMacroMix_runTest(cpuId, mask, coreMask, seed, verbose); }
7881
//
7982
pio.RunClk(100);
8083
//

cosim/bfmTests/macroMix/c_module.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//************************************************************************
22
// Copyright 2021 Massachusetts Institute of Technology
3-
// SPDX License Identifier: MIT
3+
// SPDX License Identifier: BSD-2-Clause
44
//
55
// File Name:
66
// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/memPreload/Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#//************************************************************************
22
#// Copyright 2021 Massachusetts Institute of Technology
3-
#// SPDX License Identifier: MIT
3+
#// SPDX License Identifier: BSD-2-Clause
44
#//
55
#// File Name:
66
#// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/memPreload/c_dispatch.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//************************************************************************
22
// Copyright 2021 Massachusetts Institute of Technology
3-
// SPDX License Identifier: MIT
3+
// SPDX License Identifier: BSD-2-Clause
44
//
55
// File Name:
66
// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/memPreload/c_dispatch.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//************************************************************************
22
// Copyright 2021 Massachusetts Institute of Technology
3-
// SPDX License Identifier: MIT
3+
// SPDX License Identifier: BSD-2-Clause
44
//
55
// File Name:
66
// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/memPreload/c_module.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//************************************************************************
22
// Copyright 2021 Massachusetts Institute of Technology
3-
// SPDX License Identifier: MIT
3+
// SPDX License Identifier: BSD-2-Clause
44
//
55
// File Name:
66
// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/memPreload/c_module.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//************************************************************************
22
// Copyright 2021 Massachusetts Institute of Technology
3-
// SPDX License Identifier: MIT
3+
// SPDX License Identifier: BSD-2-Clause
44
//
55
// File Name:
66
// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/memPreload/riscv_wrapper.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//************************************************************************
22
// Copyright 2021 Massachusetts Institute of Technology
3-
// SPDX License Identifier: MIT
3+
// SPDX License Identifier: BSD-2-Clause
44
//
55
// File Name:
66
// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/multiLock/Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#//************************************************************************
22
#// Copyright 2021 Massachusetts Institute of Technology
3-
#// SPDX License Identifier: MIT
3+
#// SPDX License Identifier: BSD-2-Clause
44
#//
55
#// File Name:
66
#// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/multiThread/Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#//************************************************************************
22
#// Copyright 2021 Massachusetts Institute of Technology
3-
#// SPDX License Identifier: MIT
3+
#// SPDX License Identifier: BSD-2-Clause
44
#//
55
#// File Name:
66
#// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/multiThread/c_dispatch.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//************************************************************************
22
// Copyright 2021 Massachusetts Institute of Technology
3-
// SPDX License Identifier: MIT
3+
// SPDX License Identifier: BSD-2-Clause
44
//
55
// File Name:
66
// Program: Common Evaluation Platform (CEP)

cosim/bfmTests/multiThread/c_dispatch.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//************************************************************************
22
// Copyright 2021 Massachusetts Institute of Technology
3-
// SPDX License Identifier: MIT
3+
// SPDX License Identifier: BSD-2-Clause
44
//
55
// File Name:
66
// Program: Common Evaluation Platform (CEP)

0 commit comments

Comments
 (0)