minor update

This commit is contained in:
Blaise Tine
2021-04-24 01:17:38 -04:00
parent 4cb98a25a7
commit cad21a4b92
4 changed files with 8 additions and 10 deletions

View File

@@ -312,8 +312,7 @@ void opae_sim::avs_bus() {
// process DRAM requests
if (!dram_stalled) {
assert(!vortex_afu_->avs_read || !vortex_afu_->avs_write);
if (vortex_afu_->avs_write) {
assert(0 == vortex_afu_->mem_bank_select);
if (vortex_afu_->avs_write) {
uint64_t byteen = vortex_afu_->avs_byteenable;
unsigned base_addr = vortex_afu_->avs_address * DRAM_BLOCK_SIZE;
uint8_t* data = (uint8_t*)(vortex_afu_->avs_writedata);
@@ -329,7 +328,6 @@ void opae_sim::avs_bus() {
printf("\n");*/
}
if (vortex_afu_->avs_read) {
assert(0 == vortex_afu_->mem_bank_select);
dram_rd_req_t dram_req;
dram_req.addr = vortex_afu_->avs_address;
ram_.read(vortex_afu_->avs_address * DRAM_BLOCK_SIZE, DRAM_BLOCK_SIZE, dram_req.data.data());

View File

@@ -9,9 +9,7 @@ import ccip_if_pkg::*;
import local_mem_cfg_pkg::*;
/* verilator lint_on IMPORTSTAR */
module vortex_afu_shim #(
parameter NUM_LOCAL_MEM_BANKS = 2
) (
module vortex_afu_shim (
// global signals
input clk,
input reset,
@@ -83,14 +81,14 @@ module vortex_afu_shim #(
output t_local_mem_burst_cnt avs_burstcount,
input avs_readdatavalid,
output logic [$clog2(NUM_LOCAL_MEM_BANKS)-1:0] mem_bank_select
output logic [$clog2(`PLATFORM_PARAM_LOCAL_MEMORY_BANKS)-1:0] mem_bank_select
);
t_if_ccip_Rx cp2af_sRxPort;
t_if_ccip_Tx af2cp_sTxPort;
vortex_afu #(
.NUM_LOCAL_MEM_BANKS(NUM_LOCAL_MEM_BANKS)
.NUM_LOCAL_MEM_BANKS(`PLATFORM_PARAM_LOCAL_MEMORY_BANKS)
) afu (
.clk(clk),
.reset(reset),

View File

@@ -1,8 +1,6 @@
`ifndef VX_CONFIG
`define VX_CONFIG
`include "VX_user_config.vh"
`ifndef NUM_CLUSTERS
`define NUM_CLUSTERS 1
`endif

View File

@@ -5,6 +5,10 @@
`define PLATFORM_PROVIDES_LOCAL_MEMORY
`ifndef PLATFORM_PARAM_LOCAL_MEMORY_BANKS
`define PLATFORM_PARAM_LOCAL_MEMORY_BANKS 2
`endif
`ifndef PLATFORM_PARAM_LOCAL_MEMORY_DATA_SIZE_BITS
`define PLATFORM_PARAM_LOCAL_MEMORY_DATA_SIZE_BITS 6
`endif