From: Luke Kenneth Casson Leighton Date: Sat, 28 Jul 2018 05:08:26 +0000 (+0100) Subject: cleanup soc template X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=fbe9450bcfdf71d7ce067d047e25f55ca3e01a93;p=pinmux.git cleanup soc template --- diff --git a/src/bsv/bsv_lib/soc_template.bsv b/src/bsv/bsv_lib/soc_template.bsv index 62febf8..9c27b1d 100644 --- a/src/bsv/bsv_lib/soc_template.bsv +++ b/src/bsv/bsv_lib/soc_template.bsv @@ -38,8 +38,7 @@ package socgen; import Vector::*; import Connectable::*; import Clocks::*; - /*========================== */ -{10} + /*=== Project imports === */ import ConcatReg::*; import AXI4_Types::*; @@ -53,11 +52,6 @@ package socgen; `include "instance_defines.bsv" `include "core_parameters.bsv" {8} - /*====== AXI4 slave declarations =======*/ -{3} - /*====== AXI4 Master declarations =======*/ -{4} - `ifdef DMA import DMA :: *; @@ -116,38 +110,7 @@ package socgen; {1} endinterface -function FastTuple2 #(Bool, Bit#(TLog#(Num_Slaves))) - fn_addr_to_slave_num (Bit#(`PADDR) addr); - - if(addr>=`SDRAMMemBase && addr<=`SDRAMMemEnd) - return tuple2(True,fromInteger(valueOf(Sdram_slave_num))); - else if(addr>=`DebugBase && addr<=`DebugEnd) - return tuple2(True,fromInteger(valueOf(Debug_slave_num))); - `ifdef SDRAM - else if(addr>=`SDRAMCfgBase && addr<=`SDRAMCfgEnd ) - return tuple2(True,fromInteger(valueOf(Sdram_cfg_slave_num))); - `endif - `ifdef BOOTROM - else if(addr>=`BootRomBase && addr<=`BootRomEnd) - return tuple2(True,fromInteger(valueOf(BootRom_slave_num))); - `endif - `ifdef DMA - else if(addr>=`DMABase && addr<=`DMAEnd) - return tuple2(True,fromInteger(valueOf(Dma_slave_num))); - `endif - `ifdef VME - else if(addr>=`VMEBase && addr<=`VMEEnd) - return tuple2(True,fromInteger(valueOf(VME_slave_num))); - `endif - `ifdef TCMemory - else if(addr>=`TCMBase && addr<=`TCMEnd) - return tuple2(True,fromInteger(valueOf(TCM_slave_num))); - `endif - else -{11} - return tuple2(False,?); -endfunction - + //============ mkSoc module ================= (*synthesize*) module mkSoc #(Bit#(`VADDR) reset_vector,