Changeset 710
- Timestamp:
- Jun 10, 2014, 11:09:40 AM (11 years ago)
- Location:
- trunk/platforms/tsar_generic_iob
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/platforms/tsar_generic_iob/genmap.py
r707 r710 159 159 cma = mapping.addPeriph( 'CMA', base = cma_base, size = cma_size, ptype = 'CMA', channels = 2*nb_nics ) 160 160 161 fbf = mapping.addPeriph( 'FBF', base = fbf_base, size = fbf_size, ptype = 'FBF', arg 1 = 128, arg2= 128 )161 fbf = mapping.addPeriph( 'FBF', base = fbf_base, size = fbf_size, ptype = 'FBF', arg = 128 ) 162 162 163 163 rom = mapping.addPeriph( 'ROM', base = rom_base, size = rom_size, ptype = 'ROM' ) … … 165 165 pic = mapping.addPeriph( 'PIC', base = pic_base, size = pic_size, ptype = 'PIC', channels = 32 ) 166 166 167 mapping.addIrq( pic, index = 0, isrtype = 'ISR_NIC_RX', channel = 0 ) 168 mapping.addIrq( pic, index = 1, isrtype = 'ISR_NIC_RX', channel = 1 ) 169 mapping.addIrq( pic, index = 2, isrtype = 'ISR_NIC_TX', channel = 0 ) 170 mapping.addIrq( pic, index = 3, isrtype = 'ISR_NIC_TX', channel = 1 ) 171 172 mapping.addIrq( pic, index = 4, isrtype = 'ISR_CMA' , channel = 0 ) 173 mapping.addIrq( pic, index = 5, isrtype = 'ISR_CMA' , channel = 1 ) 174 mapping.addIrq( pic, index = 6, isrtype = 'ISR_CMA' , channel = 2 ) 175 mapping.addIrq( pic, index = 7, isrtype = 'ISR_CMA' , channel = 3 ) 176 177 mapping.addIrq( pic, index = 8, isrtype = 'ISR_BDV' , channel = 0 ) 178 179 mapping.addIrq( pic, index = 16, isrtype = 'ISR_TTY_RX', channel = 0 ) 180 mapping.addIrq( pic, index = 17, isrtype = 'ISR_TTY_RX', channel = 1 ) 181 mapping.addIrq( pic, index = 18, isrtype = 'ISR_TTY_RX', channel = 2 ) 182 mapping.addIrq( pic, index = 19, isrtype = 'ISR_TTY_RX', channel = 3 ) 183 mapping.addIrq( pic, index = 20, isrtype = 'ISR_TTY_RX', channel = 4 ) 184 mapping.addIrq( pic, index = 21, isrtype = 'ISR_TTY_RX', channel = 5 ) 185 mapping.addIrq( pic, index = 22, isrtype = 'ISR_TTY_RX', channel = 6 ) 186 mapping.addIrq( pic, index = 23, isrtype = 'ISR_TTY_RX', channel = 7 ) 167 mapping.addIrq( pic, index = 0, isrtype = 'ISR_NIC_RX', channel = 0 ) 168 mapping.addIrq( pic, index = 1, isrtype = 'ISR_NIC_RX', channel = 1 ) 169 170 mapping.addIrq( pic, index = 2, isrtype = 'ISR_NIC_TX', channel = 0 ) 171 mapping.addIrq( pic, index = 3, isrtype = 'ISR_NIC_TX', channel = 1 ) 172 173 mapping.addIrq( pic, index = 4, isrtype = 'ISR_CMA' , channel = 0 ) 174 mapping.addIrq( pic, index = 5, isrtype = 'ISR_CMA' , channel = 1 ) 175 mapping.addIrq( pic, index = 6, isrtype = 'ISR_CMA' , channel = 2 ) 176 mapping.addIrq( pic, index = 7, isrtype = 'ISR_CMA' , channel = 3 ) 177 178 mapping.addIrq( pic, index = 8, isrtype = 'ISR_BDV' , channel = 0 ) 179 180 mapping.addIrq( pic, index = 9, isrtype = 'ISR_TTY_RX', channel = 0 ) 187 181 188 182 ### hardware components replicated in all clusters … … 202 196 203 197 xcu = mapping.addPeriph( 'XCU', base = xcu_base + offset, size = xcu_size, 204 ptype = 'XCU', channels = nb_procs * irq_per_proc, 205 arg1 = 16, arg2 = 16, arg3 = 16 ) 206 207 # MMC IRQ replicated in all clusters 208 mapping.addIrq( xcu, index = 0, isrtype = 'ISR_MMC' ) 198 ptype = 'XCU', channels = nb_procs * irq_per_proc, arg = 16 ) 209 199 210 200 # DMA IRQs replicated in all clusters … … 212 202 mapping.addIrq( xcu, index = (p+1), isrtype = 'ISR_DMA', channel = p ) 213 203 204 # MMC IRQ replicated in all clusters 205 mapping.addIrq( xcu, index = 0, isrtype = 'ISR_MMC' ) 206 214 207 # processors 215 208 for p in xrange ( nb_procs ): … … 273 266 vtype = 'PERI', x = 0, y = 0, pseg = 'ROM', identity = True ) 274 267 275 ### Global vsegs for replicated peripherals, and for scheduler 276 ### Note: one vseg per cluster: the vseg name is indexed by (x,y)277 ### thevseg base address is incremented by (cluster_xy * 0x10000)268 ### Global vsegs for replicated peripherals, and for scheduler. 269 ### A replicated vseg is replicated in all clusters: vseg name is indexed by (x,y), 270 ### and vseg base address is incremented by (cluster_xy * 0x10000) 278 271 279 272 mapping.addGlobal( 'seg_xcu' , xcu_base , xcu_size , '__W_', -
trunk/platforms/tsar_generic_iob/top.cpp
r707 r710 82 82 // - Y_SIZE : number of clusters in a column 83 83 // - NB_PROCS_MAX : number of processors per cluster (power of 2) 84 // - NB_TTY_CHANNELS : number of TTY channels in I/O network ( up to 16)84 // - NB_TTY_CHANNELS : number of TTY channels in I/O network (must be 1) 85 85 // - NB_NIC_CHANNELS : number of NIC channels in I/O network (up to 2) 86 86 // - NB_CMA_CHANNELS : number of CMA channels in I/O network (up to 4) … … 415 415 { 416 416 debug_memc_id = atoi(argv[n+1]); 417 418 std::cout << "@@@@@@@@@@@@@@ MEMCID = " << debug_memc_id << std::endl; 419 417 420 size_t x = debug_memc_id >> 4; 418 421 size_t y = debug_memc_id & 0xF; … … 497 500 "The NB_DMA_CHANNELS parameter cannot be larger than 4" ); 498 501 499 assert( (NB_TTY_CHANNELS < 16) and500 "The NB_TTY_CHANNELS parameter must be smaller than 16" );502 assert( (NB_TTY_CHANNELS == 1) and 503 "The NB_TTY_CHANNELS parameter must be 1" ); 501 504 502 505 assert( (NB_NIC_CHANNELS == 2) and … … 507 510 << " - YMAX = " << YMAX << std::endl 508 511 << " - NB_PROCS_MAX = " << NB_PROCS_MAX << std::endl 512 << " - NB_TTY_CHANNELS = " << NB_TTY_CHANNELS << std::endl 509 513 << " - NB_DMA_CHANNELS = " << NB_DMA_CHANNELS << std::endl 510 << " - NB_TTY_CHANNELS = " << NB_TTY_CHANNELS << std::endl511 514 << " - NB_NIC_CHANNELS = " << NB_NIC_CHANNELS << std::endl 512 515 << " - MEMC_WAYS = " << MEMC_WAYS << std::endl … … 845 848 sc_signal<bool> signal_irq_false; 846 849 sc_signal<bool> signal_irq_bdev; 850 sc_signal<bool> signal_irq_mtty_rx; 847 851 sc_signal<bool> signal_irq_mnic_rx[NB_NIC_CHANNELS]; 848 852 sc_signal<bool> signal_irq_mnic_tx[NB_NIC_CHANNELS]; 849 sc_signal<bool> signal_irq_mtty_rx[NB_TTY_CHANNELS];850 // sc_signal<bool> signal_irq_mtty_tx[NB_TTY_CHANNELS];851 853 sc_signal<bool> signal_irq_cdma[NB_CMA_CHANNELS]; 852 854 … … 1028 1030 IntTab(0, IOPI_LOCAL_SRCID), 1029 1031 IntTab(0, IOX_IOPI_TGT_ID), 1030 32, // number of input HWI 1031 5000 ); // period between WTI 1032 32 ); // number of input HWI 1032 1033 // Clusters 1033 1034 TsarIobCluster<vci_param_int, … … 1188 1189 mtty->p_resetn (signal_resetn); 1189 1190 mtty->p_vci (signal_vci_tgt_mtty); 1190 for ( size_t i=0 ; i<NB_TTY_CHANNELS ; i++ ) 1191 { 1192 mtty->p_irq[i] (signal_irq_mtty_rx[i]); 1193 } 1191 mtty->p_irq[0] (signal_irq_mtty_rx); 1194 1192 1195 1193 std::cout << " - MTTY connected" << std::endl; … … 1221 1219 else if(i < 8) iopi->p_hwi[i] (signal_irq_false); 1222 1220 else if(i == 8) iopi->p_hwi[i] (signal_irq_bdev); 1223 else if(i < 16) iopi->p_hwi[i] (signal_irq_false); 1224 else if(i < 16+NB_TTY_CHANNELS) iopi->p_hwi[i] (signal_irq_mtty_rx[i-16]); 1225 else if(i < 24) iopi->p_hwi[i] (signal_irq_false); 1226 else if(i < 24+NB_TTY_CHANNELS) iopi->p_hwi[i] (signal_irq_false); 1227 // else if(i < 24+NB_TTY_CHANNELS) iopi->p_hwi[i] (signal_irq_mtty_tx[i-24]); 1221 else if(i == 9) iopi->p_hwi[i] (signal_irq_mtty_rx); 1228 1222 else iopi->p_hwi[i] (signal_irq_false); 1229 1223 } … … 1615 1609 // signal_vci_ini_cdma.print_trace("[SIG]IOX_CDMA_INI"); 1616 1610 1617 1618 1611 // brom->print_trace(); 1612 // signal_vci_tgt_brom.print_trace("[SIG]IOX_BROM_TGT"); 1619 1613 1620 1614 // mtty->print_trace(); … … 1634 1628 1635 1629 // interrupts 1636 if (signal_irq_bdev) 1637 if (signal_irq_mtty_rx [0]) std::cout << "### IRQ_MTTY ACTIVE" << std::endl;1630 if (signal_irq_bdev) std::cout << "### IRQ_BDEV ACTIVE" << std::endl; 1631 if (signal_irq_mtty_rx) std::cout << "### IRQ_MTTY ACTIVE" << std::endl; 1638 1632 } 1639 1633 }
Note: See TracChangeset
for help on using the changeset viewer.