Skip to content

Commit

Permalink
Address github issue openhwgroup#39. Make parameter PMA_NUM_REGIONS i…
Browse files Browse the repository at this point in the history
…nt (not unsigned)

Signed-off-by: Oivind Ekelund <[email protected]>
  • Loading branch information
silabs-oivind committed Aug 19, 2021
1 parent a225028 commit b57afa6
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 14 deletions.
4 changes: 2 additions & 2 deletions bhv/cv32e40x_wrapper.sv
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ module cv32e40x_wrapper
#(
parameter NUM_MHPMCOUNTERS = 1,
parameter b_ext_e B_EXT = NONE,
parameter int unsigned PMA_NUM_REGIONS = 0,
parameter pma_region_t PMA_CFG[(PMA_NUM_REGIONS ? (PMA_NUM_REGIONS-1) : 0):0] = '{default:PMA_R_DEFAULT}
parameter int PMA_NUM_REGIONS = 0,
parameter pma_region_t PMA_CFG[PMA_NUM_REGIONS-1:0] = '{default:PMA_R_DEFAULT}
)
(
// Clock and Reset
Expand Down
4 changes: 2 additions & 2 deletions rtl/cv32e40x_core.sv
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ module cv32e40x_core import cv32e40x_pkg::*;
parameter NUM_MHPMCOUNTERS = 1,
parameter LIB = 0,
parameter b_ext_e B_EXT = NONE,
parameter int unsigned PMA_NUM_REGIONS = 0,
parameter pma_region_t PMA_CFG[(PMA_NUM_REGIONS ? (PMA_NUM_REGIONS-1) : 0):0] = '{default:PMA_R_DEFAULT}
parameter int PMA_NUM_REGIONS = 0,
parameter pma_region_t PMA_CFG[PMA_NUM_REGIONS-1:0] = '{default:PMA_R_DEFAULT}
)
(
// Clock and Reset
Expand Down
4 changes: 2 additions & 2 deletions rtl/cv32e40x_if_stage.sv
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@

module cv32e40x_if_stage import cv32e40x_pkg::*;
#(parameter bit A_EXTENSION = 0,
parameter int unsigned PMA_NUM_REGIONS = 0,
parameter pma_region_t PMA_CFG[(PMA_NUM_REGIONS ? (PMA_NUM_REGIONS-1) : 0):0] = '{default:PMA_R_DEFAULT})
parameter int PMA_NUM_REGIONS = 0,
parameter pma_region_t PMA_CFG[PMA_NUM_REGIONS-1:0] = '{default:PMA_R_DEFAULT})
(
input logic clk,
input logic rst_n,
Expand Down
4 changes: 2 additions & 2 deletions rtl/cv32e40x_load_store_unit.sv
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@

module cv32e40x_load_store_unit import cv32e40x_pkg::*;
#(parameter bit A_EXTENSION = 0,
parameter int unsigned PMA_NUM_REGIONS = 0,
parameter pma_region_t PMA_CFG[(PMA_NUM_REGIONS ? (PMA_NUM_REGIONS-1) : 0):0] = '{default:PMA_R_DEFAULT})
parameter int PMA_NUM_REGIONS = 0,
parameter pma_region_t PMA_CFG[PMA_NUM_REGIONS-1:0] = '{default:PMA_R_DEFAULT})
(
input logic clk,
input logic rst_n,
Expand Down
4 changes: 2 additions & 2 deletions rtl/cv32e40x_mpu.sv
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ module cv32e40x_mpu import cv32e40x_pkg::*;
parameter type CORE_REQ_TYPE = obi_inst_req_t,
parameter type CORE_RESP_TYPE = inst_resp_t,
parameter type BUS_RESP_TYPE = obi_inst_resp_t,
parameter int unsigned PMA_NUM_REGIONS = 0,
parameter pma_region_t PMA_CFG[(PMA_NUM_REGIONS ? (PMA_NUM_REGIONS-1) : 0):0] = '{default:PMA_R_DEFAULT})
parameter int PMA_NUM_REGIONS = 0,
parameter pma_region_t PMA_CFG[PMA_NUM_REGIONS-1:0] = '{default:PMA_R_DEFAULT})
(
input logic clk,
input logic rst_n,
Expand Down
4 changes: 2 additions & 2 deletions rtl/cv32e40x_pma.sv
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@
module cv32e40x_pma import cv32e40x_pkg::*;
#(
parameter bit A_EXTENSION = 0,
parameter int unsigned PMA_NUM_REGIONS = 0,
parameter pma_region_t PMA_CFG[(PMA_NUM_REGIONS ? (PMA_NUM_REGIONS-1) : 0):0] = '{default:PMA_R_DEFAULT})
parameter int PMA_NUM_REGIONS = 0,
parameter pma_region_t PMA_CFG[PMA_NUM_REGIONS-1:0] = '{default:PMA_R_DEFAULT})
(
input logic [31:0] trans_addr_i,
input logic speculative_access_i, // Indicate that ongoing access is speculative
Expand Down
4 changes: 2 additions & 2 deletions sva/cv32e40x_mpu_sva.sv
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@
////////////////////////////////////////////////////////////////////////////////

module cv32e40x_mpu_sva import cv32e40x_pkg::*; import uvm_pkg::*;
#( parameter int unsigned PMA_NUM_REGIONS = 0,
parameter pma_region_t PMA_CFG[(PMA_NUM_REGIONS ? (PMA_NUM_REGIONS-1) : 0):0] = '{default:PMA_R_DEFAULT},
#( parameter int PMA_NUM_REGIONS = 0,
parameter pma_region_t PMA_CFG[PMA_NUM_REGIONS-1:0] = '{default:PMA_R_DEFAULT},
parameter int unsigned IS_INSTR_SIDE = 0)
(
input logic clk,
Expand Down

0 comments on commit b57afa6

Please sign in to comment.