@@ -40,41 +40,96 @@ The eFPGA block
40
40
41
41
Math Units
42
42
^^^^^^^^^^
43
+ The EFPGA has 2 Math units attached. Each math unit has 3 block RAMS (4KBytes) and 2 Multipliers.
44
+ Each Block RAM has one read port and one write port with independant clocks. Each Port can be independenly configured as 8-bit, 16-bit or 32-bit by the configuration on the appropriate rmode, or wmode inputs.
45
+ The Write data can also be selected to be from the fabric or the output of the Associated Multiplier.
46
+
47
+
48
+ .. figure :: ../images/A2_MATH_UNIT.png
49
+ :name: MATH Unit Diagram
50
+ :align: center
51
+ :alt:
43
52
44
53
Block RAM
45
54
^^^^^^^^^
46
55
47
- FIFO Controller
48
- ^^^^^^^^^^^^^^^
49
-
50
56
Clocking
51
57
^^^^^^^^
58
+ The eFPGA recieves 6 clocks from the SOC.
59
+
60
+ - Clk0 is sourced by the PLL and the eFPGA divisor Circuit.
61
+ - CLK1 is sources by the PLL and the peripheral divisor Circuit.
62
+ - CLK2 is sourced by the RefClock divisor Circut.
63
+ - CLK3 is source by an IO pin.
64
+ - CLK4 is sourced by an IO pin.
65
+ - CLK5 is sourced by an IO pin.
52
66
53
67
54
68
SoC Interfaces
55
69
--------------
56
70
57
71
Configurable Input/Output Signals
58
72
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
73
+ The example RTL file top.sv in the rtl/simulation folder is functional rtl design for verifying the eFPGA interfaces.
74
+ It contain the mapping from the eFPGA to the SoC and IO. The example design instantiates all the interfaces and has simple logic that allows for exercising the interfaces, The various registers allow for control of all the resources and interfaces with simple state machines to demostrate the use of the resources.
59
75
60
- APB Interface
76
+ L2 Interface
61
77
~~~~~~~~~~~~~
78
+ The L2 interface to the eFPGA is a memory mapped interface that is allocated a 1Mbyte address space.
79
+ It is asynchronous to the CPU and contains clock crossing registers to maintain data integrity.
80
+ the following table contains the L2 Interface signals. Various control registers are accessible via the L2 interface to test other functions in the eFPGA.
81
+
82
+ +------------+-----------------+---------------------------+
83
+ | direction | Name | Description. |
84
+ +============+=================+===========================+
85
+ | input | lint_REQ | Cycle request active high|
86
+ +------------+-----------------+---------------------------+
87
+ | input | lint_WEN | Write = 1, Read = 0. |
88
+ +------------+-----------------+---------------------------+
89
+ | input | lint_ADDR[19:0] | Address 20-bits |
90
+ +------------+-----------------+---------------------------+
91
+ | input | lint_WDATA[31:0]| Write Data 32-bits |
92
+ +------------+-----------------+---------------------------+
93
+ | input | lint_BE[3:0] | Byte enables 4-bits. |
94
+ +------------+-----------------+---------------------------+
95
+ | output | lint_VALID | Valid signal (ack) |
96
+ +------------+-----------------+---------------------------+
97
+ | output | lint_GNT | Grant signal |
98
+ +------------+-----------------+---------------------------+
99
+ | output | lint_RDATA[31:0]| Read Data 32-bits |
100
+ +------------+-----------------+---------------------------+
101
+ | output | lint_clk | Clock back to CDC logic |
102
+ +------------+-----------------+---------------------------+
62
103
63
104
TCDM Interface
64
105
~~~~~~~~~~~~~~
65
-
66
- Interrupts
67
- ~~~~~~~~~~
68
-
69
-
70
- eFPGA Bitstream Loading
71
- -----------------------
72
-
73
- eFPGA Configuration Control
74
- ~~~~~~~~~~~~~~~~~~~~~~~~~~~
75
-
76
- eFPGA Template
77
- ~~~~~~~~~~~~~~
106
+ Core-v-mcu provides 4 TCDM (Tightly Coupled Distributed memory) Each of the these interfaces has full access to the 512KB of SoC memory allowing
107
+ the eFPGA to perform reads and writes to memory. Each interface is connected through Clock Domain Crossing registers as the eFPGA is clocked by
108
+ asynchronously from the SoC.
109
+
110
+ +-----------+----------------------+--------------------------------------------------+
111
+ | Direction | Name | Description |
112
+ +===========+======================+==================================================+
113
+ | output | tcdm_addr_p0[19:0] | 20-bit address for TCDM |
114
+ +-----------+----------------------+--------------------------------------------------+
115
+ | input | tcdm_rdata_p0[31:0] | 32-bit Read data returned from TCDM |
116
+ +-----------+----------------------+--------------------------------------------------+
117
+ | input | tcdm_valid_p0 | TCDM read data Valid |
118
+ +-----------+----------------------+--------------------------------------------------+
119
+ | input | tcdm_gnt_p0 | TCDM Grant indicating the cycle is in progress |
120
+ +-----------+----------------------+--------------------------------------------------+
121
+ | input | tcdm_fmo_p0 | TCDM interface can accept only one more request |
122
+ +-----------+----------------------+--------------------------------------------------+
123
+ | output | tcdm_wdata_p0[31:0] | 32-bit Data to write to TCDM |
124
+ +-----------+----------------------+--------------------------------------------------+
125
+ | output | tcdm_be_p0[3:0] | 4 byte enables for byte writes |
126
+ +-----------+----------------------+--------------------------------------------------+
127
+ | output | tcdm_wen_p0 | Write enable active high |
128
+ +-----------+----------------------+--------------------------------------------------+
129
+ | output | tcdm_req_p0 | TCDM cycle request |
130
+ +-----------+----------------------+--------------------------------------------------+
131
+ | output | tcdm_clk_p0 | TCDM clock from eFPGA to CDC logic |
132
+ +-----------+----------------------+--------------------------------------------------+
78
133
79
134
80
135
eFPGA Subsystem Registers
@@ -144,6 +199,8 @@ TCDM_CTL_P3 offset = 0x0C
144
199
| tcdm_addr_p3 | 19:0 | RW | 0x0 | Sets the address to be used on TCDM 3 |
145
200
+--------------+-------+------+------------+-------------------------------------------------------------+
146
201
202
+ There are 4 control regsisters (1 for each of te multiplier units) the bits in these registers will configure the multipler operation.
203
+
147
204
M0_M0_CONTROL offset = 0x10
148
205
~~~~~~~~~~~~~~~~~~~~~~~~~~~
149
206
@@ -236,29 +293,41 @@ M1_M1_CONTROL offset = 0x1C
236
293
| m1_m1_outsel | 5:0 | RW | 0x0 | Math Unit 1, Mutliplier 1 output select |
237
294
+--------------+-------+------+------------+---------------------------------------------------------------------------------+
238
295
296
+ Two RAM control registers are provide to configure the RAMs (1 for each Math unit)
297
+
298
+
239
299
M0_RAM_CONTROL offset = 0x20
240
300
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
241
301
242
302
+----------------+-------+------+------------+-----------------------------------------------+
243
303
| Field | Bits | Type | Default | Description |
244
304
+================+=======+======+============+===============================================+
245
305
| m0_coef_wdsel | 14:14 | RW | 0x0 | Math Unit 0 coefficient RAM write data select |
306
+ | | | | | 0 = Fabric, 1 = Multipler output |
246
307
+----------------+-------+------+------------+-----------------------------------------------+
247
308
| m0_oper1_wdsel | 13:13 | RW | 0x0 | Math Unit 0 Operand 0 RAM write data select |
309
+ | | | | | 0 = Fabric, 1 = Multipler output |
248
310
+----------------+-------+------+------------+-----------------------------------------------+
249
311
| m0_oper0_wdsel | 12:12 | RW | 0x0 | Math Unit 0 Operand 1 RAM write data select |
312
+ | | | | | 0 = Fabric, 1 = Multipler output |
250
313
+----------------+-------+------+------------+-----------------------------------------------+
251
314
| m0_coef_wmode | 11:10 | RW | 0x0 | Math Unit 0 coefficient RAM write mode |
315
+ | | | | | 00 = 32-bit, 01 = 16=bit 10 = 8=bit |
252
316
+----------------+-------+------+------------+-----------------------------------------------+
253
317
| m0_coef_rmode | 9:8 | RW | 0x0 | Math Unit 0 coefficient RAM read mode |
318
+ | | | | | 00 = 32-bit, 01 = 16=bit 10 = 8=bit |
254
319
+----------------+-------+------+------------+-----------------------------------------------+
255
320
| m0_oper1_wmode | 7:6 | RW | 0x0 | Math Unit 0 operand 0 RAM write mode |
321
+ | | | | | 00 = 32-bit, 01 = 16=bit 10 = 8=bit |
256
322
+----------------+-------+------+------------+-----------------------------------------------+
257
323
| m0_oper1_rmode | 5:4 | RW | 0x0 | Math Unit 0 operand 0 RAM read mode |
324
+ | | | | | 00 = 32-bit, 01 = 16=bit 10 = 8=bit |
258
325
+----------------+-------+------+------------+-----------------------------------------------+
259
326
| m0_oper0_wmode | 3:2 | RW | 0x0 | Math Unit 0 operand 1 RAM write mode |
327
+ | | | | | 00 = 32-bit, 01 = 16=bit 10 = 8=bit |
260
328
+----------------+-------+------+------------+-----------------------------------------------+
261
329
| m0_oper0_rmode | 1:0 | RW | 0x0 | Math Unit 0 operand 1 RAM read mode |
330
+ | | | | | 00 = 32-bit, 01 = 16=bit 10 = 8=bit |
262
331
+----------------+-------+------+------------+-----------------------------------------------+
263
332
264
333
M1_RAM_CONTROL offset = 0x24
@@ -268,24 +337,37 @@ M1_RAM_CONTROL offset = 0x24
268
337
| Field | Bits | Type | Default | Description |
269
338
+================+=======+======+============+===============================================+
270
339
| m1_coef_wdsel | 14:14 | RW | 0x0 | Math Unit 1 coefficient RAM write data select |
340
+ | | | | | 0 = Fabric, 1 = Multipler output |
271
341
+----------------+-------+------+------------+-----------------------------------------------+
272
342
| m1_oper1_wdsel | 13:13 | RW | 0x0 | Math Unit 1 Operand 0 RAM write data select |
343
+ | | | | | 0 = Fabric, 1 = Multipler output |
273
344
+----------------+-------+------+------------+-----------------------------------------------+
274
345
| m1_oper0_wdsel | 12:12 | RW | 0x0 | Math Unit 1 Operand 1 RAM write data select |
346
+ | | | | | 0 = Fabric, 1 = Multipler output |
275
347
+----------------+-------+------+------------+-----------------------------------------------+
276
348
| m1_coef_wmode | 11:10 | RW | 0x0 | Math Unit 1 coefficient RAM write mode |
349
+ | | | | | 00 = 32-bit, 01 = 16=bit 10 = 8=bit |
277
350
+----------------+-------+------+------------+-----------------------------------------------+
278
351
| m1_coef_rmode | 9:8 | RW | 0x0 | Math Unit 1 coefficient RAM read mode |
352
+ | | | | | 00 = 32-bit, 01 = 16=bit 10 = 8=bit |
279
353
+----------------+-------+------+------------+-----------------------------------------------+
280
354
| m1_oper1_wmode | 7:6 | RW | 0x0 | Math Unit 1 operand 0 RAM write mode |
355
+ | | | | | 00 = 32-bit, 01 = 16=bit 10 = 8=bit |
281
356
+----------------+-------+------+------------+-----------------------------------------------+
282
357
| m1_oper1_rmode | 5:4 | RW | 0x0 | Math Unit 1 operand 0 RAM read mode |
358
+ | | | | | 00 = 32-bit, 01 = 16=bit 10 = 8=bit |
283
359
+----------------+-------+------+------------+-----------------------------------------------+
284
360
| m1_oper0_wmode | 3:2 | RW | 0x0 | Math Unit 1 operand 1 RAM write mode |
361
+ | | | | | 00 = 32-bit, 01 = 16=bit 10 = 8=bit |
285
362
+----------------+-------+------+------------+-----------------------------------------------+
286
363
| m1_oper0_rmode | 1:0 | RW | 0x0 | Math Unit 1 operand 1 RAM read mode |
364
+ | | | | | 00 = 32-bit, 01 = 16=bit 10 = 8=bit |
287
365
+----------------+-------+------+------------+-----------------------------------------------+
288
366
367
+
368
+ Four clock enable registers that are write only and clear to zero, when written to a '1' and single
369
+ clock enable will be generated to the specified multiplier.
370
+
289
371
M0_M0_CLKEN offset = 0x30
290
372
~~~~~~~~~~~~~~~~~~~~~~~~~
291
373
0 commit comments