Changeset 972 for trunk/platforms/tsar_generic_iob/arch.py
- Timestamp:
- Apr 11, 2015, 8:26:46 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/platforms/tsar_generic_iob/arch.py
r966 r972 19 19 # 20 20 # All clusters contain (nb_procs) processors, one L2 cache, one XCU, and 21 # one DMA controller.21 # one optional hardware coprocessor connected to a MWMR_DMA controller. 22 22 # 23 23 # The "constructor" parameters (defined in Makefile) are: … … 27 27 # - nb_ttys : number of TTY channels 28 28 # - fbf_width : frame_buffer width = frame_buffer heigth 29 # - ioc_type : can be 'BDV','HBA','SDC', but not 'RDK' 30 # 31 # The other hardware parameters (defined below) are: 29 # - ioc_type : can be 'BDV','HBA','SDC', but not 'RDK' 30 # 31 # 32 # The other hardware parameters (defined in this script) are: 32 33 # - nb_nics : number of NIC channels 33 34 # - nb_cmas : number of CMA channels … … 40 41 # - use_ramdisk : use a ramdisk when True 41 42 # - vseg_increment : address increment for replicated vsegs 43 # - mwr_type : coprocessor type / can be 'GCD','DCT','NOPE' 44 # - use_dma : one single channel DMA per cluster if non zero 42 45 # 43 46 # Regarding the boot and kernel vsegs mapping : … … 59 62 nb_ttys = 1, 60 63 fbf_width = 128, 61 ioc_type = ' BDV' ):64 ioc_type = 'HBA' ): 62 65 63 66 ### define architecture constants … … 71 74 p_width = 4 72 75 paddr_width = 40 73 irq_per_proc = 4 # NetBSD constraint76 irq_per_proc = 4 74 77 peri_increment = 0x10000 75 76 ### parameters checking 78 mwr_type = 'CPY' 79 80 ### constructor parameters checking 77 81 78 82 assert( nb_procs <= (1 << p_width) ) … … 90 94 91 95 assert( ioc_type in [ 'BDV' , 'HBA' , 'SDC' ] ) 96 97 assert( mwr_type in [ 'GCD' , 'DCT' , 'CPY' , 'NONE' ] ) 92 98 93 99 ### define platform name … … 104 110 xcu_size = 0x1000 # 4 Kbytes 105 111 106 dma_base = 0x00B1000000107 dma_size = 0x1000 # 4 Kbytes112 mwr_base = 0x00B1000000 113 mwr_size = 0x1000 # 4 Kbytes 108 114 109 115 mmc_base = 0x00B2000000 … … 207 213 208 214 ### components replicated in all clusters 209 ram =mapping.addRam( 'RAM', base = ram_base + offset,215 mapping.addRam( 'RAM', base = ram_base + offset, 210 216 size = ram_size ) 211 212 mmc = mapping.addPeriph( 'MMC', base = mmc_base + offset,213 size = mmc_size, ptype = 'MMC' )214 215 dma = mapping.addPeriph( 'DMA', base = dma_base + offset,216 size = dma_size, ptype = 'DMA',217 channels = nb_procs )218 217 219 218 xcu = mapping.addPeriph( 'XCU', base = xcu_base + offset, … … 223 222 224 223 mapping.addIrq( xcu, index = 0, isrtype = 'ISR_MMC' ) 225 226 for i in xrange ( dma.channels ): 227 mapping.addIrq( xcu, index = 1+i, isrtype = 'ISR_DMA', 228 channel = i ) 224 mapping.addIrq( xcu, index = 1, isrtype = 'ISR_MWR' ) 225 226 mapping.addPeriph( 'MMC', base = mmc_base + offset, 227 size = mmc_size, ptype = 'MMC' ) 228 229 if ( mwr_type == 'GCD' ): 230 mapping.addPeriph( 'MWR', base = mwr_base + offset, 231 size = mwr_size, ptype = 'MWR', subtype = 'GCD', 232 arg0 = 2, arg1 = 1, arg2 = 1, arg3 = 0 ) 233 234 if ( mwr_type == 'DCT' ): 235 mapping.addPeriph( 'MWR', base = mwr_base + offset, 236 size = mwr_size, ptype = 'MWR', subtype = 'DCT', 237 arg0 = 1, arg1 = 1, arg2 = 1, arg3 = 0 ) 238 239 if ( mwr_type == 'CPY' ): 240 mapping.addPeriph( 'MWR', base = mwr_base + offset, 241 size = mwr_size, ptype = 'MWR', subtype = 'CPY', 242 arg0 = 1, arg1 = 1, arg2 = 1, arg3 = 0 ) 229 243 230 244 for p in xrange ( nb_procs ): 231 mapping.addProc( x , y, p )245 mapping.addProc( x , y , p ) 232 246 233 247 ### external peripherals in cluster_io … … 406 420 local = False, big = False ) 407 421 408 mapping.addGlobal( 'seg_dma_%d_%d' %(x,y), dma_base + offset, dma_size,409 '__W_', vtype = 'PERI' , x = x , y = y , pseg = 'DMA',410 local = False, big = False )411 412 422 mapping.addGlobal( 'seg_mmc_%d_%d' %(x,y), mmc_base + offset, mmc_size, 413 423 '__W_', vtype = 'PERI' , x = x , y = y , pseg = 'MMC', 414 424 local = False, big = False ) 425 426 if ( mwr_type != 'NONE' ): 427 mapping.addGlobal( 'seg_mwr_%d_%d' %(x,y), mwr_base + offset, mwr_size, 428 '__W_', vtype = 'PERI' , x = x , y = y , pseg = 'MWR', 429 local = False, big = False ) 415 430 416 431 return mapping
Note: See TracChangeset
for help on using the changeset viewer.