Changeset 874 for trunk/platforms
- Timestamp:
- Nov 11, 2014, 4:07:29 PM (10 years ago)
- Location:
- trunk/platforms/tsar_generic_iob
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/platforms/tsar_generic_iob/arch.py
r817 r874 19 19 # - y_size : number of clusters in a column 20 20 # - nb_procs : number of processors per cluster 21 # - nb_ttys : number of TTY channels 21 22 # - fbf_width : frame_buffer width = frame_buffer heigth 22 23 # 23 24 # The "hidden" parameters (defined below) are: 24 # - nb_ttys : number of TTY channels25 25 # - nb_nics : number of NIC channels 26 26 # - x_io : cluster_io x coordinate … … 48 48 y_size = 2, 49 49 nb_procs = 2, 50 nb_ttys = 1, 50 51 fbf_width = 128 ): 51 52 52 53 ### define architecture constants 53 54 54 nb_ttys = 155 55 nb_nics = 2 56 56 x_io = 0 … … 76 76 or (y_size == 8) or (y_size == 16) ) 77 77 78 assert( nb_ttys == 1)78 assert( (nb_ttys >= 1) and (nb_ttys <= 16) ) 79 79 80 80 assert( ((x_io == 0) and (y_io == 0)) or 81 81 ((x_io == x_size-1) and (y_io == y_size-1)) ) 82 82 83 platform_name = 'tsar_iob_%d_%d_%d_%d ' % ( x_size, y_size, nb_procs, fbf_width)83 platform_name = 'tsar_iob_%d_%d_%d_%d_%d' % (x_size,y_size,nb_procs,nb_ttys,fbf_width) 84 84 85 85 ### define replicated physical segments … … 116 116 117 117 fbf_base = 0x00B7000000 + offset_io 118 fbf_size = fbf_width * fbf_width 118 fbf_size = fbf_width * fbf_width # fbf_width * fbf_width bytes 119 119 120 120 pic_base = 0x00B8000000 + offset_io … … 207 207 pic = mapping.addPeriph( 'PIC', base = pic_base, size = pic_size, ptype = 'PIC', channels = 32 ) 208 208 209 mapping.addIrq( pic, index = 0, isrtype = 'ISR_NIC_RX', channel = 0 ) 210 mapping.addIrq( pic, index = 1, isrtype = 'ISR_NIC_RX', channel = 1 ) 211 212 mapping.addIrq( pic, index = 2, isrtype = 'ISR_NIC_TX', channel = 0 ) 213 mapping.addIrq( pic, index = 3, isrtype = 'ISR_NIC_TX', channel = 1 ) 214 215 mapping.addIrq( pic, index = 4, isrtype = 'ISR_CMA' , channel = 0 ) 216 mapping.addIrq( pic, index = 5, isrtype = 'ISR_CMA' , channel = 1 ) 217 mapping.addIrq( pic, index = 6, isrtype = 'ISR_CMA' , channel = 2 ) 218 mapping.addIrq( pic, index = 7, isrtype = 'ISR_CMA' , channel = 3 ) 219 220 mapping.addIrq( pic, index = 8, isrtype = 'ISR_BDV' , channel = 0 ) 221 222 mapping.addIrq( pic, index = 9, isrtype = 'ISR_TTY_RX', channel = 0 ) 209 mapping.addIrq( pic, index = 0, isrtype = 'ISR_NIC_RX', channel = 0 ) 210 mapping.addIrq( pic, index = 1, isrtype = 'ISR_NIC_RX', channel = 1 ) 211 212 mapping.addIrq( pic, index = 2, isrtype = 'ISR_NIC_TX', channel = 0 ) 213 mapping.addIrq( pic, index = 3, isrtype = 'ISR_NIC_TX', channel = 1 ) 214 215 mapping.addIrq( pic, index = 4, isrtype = 'ISR_CMA' , channel = 0 ) 216 mapping.addIrq( pic, index = 5, isrtype = 'ISR_CMA' , channel = 1 ) 217 mapping.addIrq( pic, index = 6, isrtype = 'ISR_CMA' , channel = 2 ) 218 mapping.addIrq( pic, index = 7, isrtype = 'ISR_CMA' , channel = 3 ) 219 220 mapping.addIrq( pic, index = 8, isrtype = 'ISR_BDV' , channel = 0 ) 221 222 mapping.addIrq( pic, index = 16, isrtype = 'ISR_TTY_RX', channel = 0 ) 223 mapping.addIrq( pic, index = 17, isrtype = 'ISR_TTY_RX', channel = 1 ) 224 mapping.addIrq( pic, index = 18, isrtype = 'ISR_TTY_RX', channel = 2 ) 225 mapping.addIrq( pic, index = 19, isrtype = 'ISR_TTY_RX', channel = 3 ) 226 mapping.addIrq( pic, index = 20, isrtype = 'ISR_TTY_RX', channel = 4 ) 227 mapping.addIrq( pic, index = 21, isrtype = 'ISR_TTY_RX', channel = 5 ) 228 mapping.addIrq( pic, index = 22, isrtype = 'ISR_TTY_RX', channel = 6 ) 229 mapping.addIrq( pic, index = 23, isrtype = 'ISR_TTY_RX', channel = 7 ) 230 mapping.addIrq( pic, index = 24, isrtype = 'ISR_TTY_RX', channel = 8 ) 231 mapping.addIrq( pic, index = 25, isrtype = 'ISR_TTY_RX', channel = 9 ) 232 mapping.addIrq( pic, index = 26, isrtype = 'ISR_TTY_RX', channel = 10 ) 233 mapping.addIrq( pic, index = 27, isrtype = 'ISR_TTY_RX', channel = 11 ) 234 mapping.addIrq( pic, index = 28, isrtype = 'ISR_TTY_RX', channel = 12 ) 235 mapping.addIrq( pic, index = 29, isrtype = 'ISR_TTY_RX', channel = 13 ) 236 mapping.addIrq( pic, index = 30, isrtype = 'ISR_TTY_RX', channel = 14 ) 237 mapping.addIrq( pic, index = 31, isrtype = 'ISR_TTY_RX', channel = 15 ) 223 238 224 239 ### hardware components replicated in all clusters … … 272 287 identity = True , local = False, big = True ) 273 288 274 ### global vsegs kernel_code, kernel_init : local / big page 275 ### replicated in all clusters with the same name (same vbase) 289 ### Global vsegs kernel_ptab_x_y : big page 290 ### one vseg per cluster: name indexed by (x,y) 291 ### vbase address incremented by (cluster_xy * vseg_increment) 292 for x in xrange( x_size ): 293 for y in xrange( y_size ): 294 offset = ((x << y_width) + y) * ptab_increment 295 base = kernel_ptab_vbase + offset 296 mapping.addGlobal( 'seg_kernel_ptab_%d_%d' %(x,y), base, kernel_ptab_size, 297 'CXW_', vtype = 'PTAB', x = x, y = y, pseg = 'RAM', 298 local = False , big = True ) 299 300 ### global vsegs kernel_code, kernel_init : big page 301 ### replicated in all clusters with the same name & same vbase 276 302 for x in xrange( x_size ): 277 303 for y in xrange( y_size ): … … 286 312 local = True, big = True ) 287 313 288 ### global vseg kernel_data : non local /big page314 ### global vseg kernel_data : big page 289 315 ### Only mapped in cluster[0][0] 290 316 mapping.addGlobal( 'seg_kernel_data', kernel_data_vbase, kernel_data_size, … … 293 319 local = False, big = True ) 294 320 295 ### global vseg kernel_uncdata : non local /small page321 ### global vseg kernel_uncdata : small page 296 322 ### Only mapped in cluster[0][0] 297 323 mapping.addGlobal( 'seg_kernel_uncdata', kernel_uncdata_vbase, kernel_uncdata_size, … … 300 326 local = False, big = False ) 301 327 302 ### Global vsegs kernel_ptab_x_y: non local / big pages 303 ### replicated in all clusters with name indexed by (x,y) 304 ### as vbase address is incremented by (cluster_xy * vseg_increment) 305 for x in xrange( x_size ): 306 for y in xrange( y_size ): 307 offset = ((x << y_width) + y) * ptab_increment 308 mapping.addGlobal( 'seg_kernel_ptab_%d_%d' %(x,y), kernel_ptab_vbase + offset , kernel_ptab_size, 309 'CXW_', vtype = 'PTAB', x = x, y = y, pseg = 'RAM', 310 local = False , big = True ) 311 312 ### global vsegs kernel_sched : non local / small pages 313 ### allocated in all clusters with name indexed by (x,y) 328 ### global vsegs kernel_sched_x_y : small pages 329 ### one vseg per cluster with name indexed by (x,y) 314 330 ### as vbase address is incremented by (cluster_xy * vseg_increment) 315 331 for x in xrange( x_size ): -
trunk/platforms/tsar_generic_iob/top.cpp
r818 r874 38 38 // The external peripherals HWI IRQs are translated to WTI IRQs by the 39 39 // external IOPIC component, that must be configured by the OS to route 40 // these WTI I TQS to one or several internal XICU components.40 // these WTI IRQS to one or several internal XICU components. 41 41 // - IOPIC HWI[1:0] connected to IRQ_NIC_RX[1:0] 42 42 // - IOPIC HWI[3:2] connected to IRQ_NIC_TX[1:0] 43 43 // - IOPIC HWI[7:4] connected to IRQ_CMA_TX[3:0]] 44 44 // - IOPIC HWI[8] connected to IRQ_BDEV 45 // - IOPIC HWI[ 9] connected to IRQ_TTY_RX[0]45 // - IOPIC HWI[31:16] connected to IRQ_TTY_RX[15:0] 46 46 // 47 47 // Besides the external peripherals, each cluster contains one XICU component, … … 78 78 // - Y_SIZE : number of clusters in a column 79 79 // - NB_PROCS_MAX : number of processors per cluster (power of 2) 80 // - NB_TTY_CHANNELS : number of TTY channels in I/O network ( must be 1)80 // - NB_TTY_CHANNELS : number of TTY channels in I/O network (up to 16) 81 81 // - NB_NIC_CHANNELS : number of NIC channels in I/O network (up to 2) 82 82 // - NB_CMA_CHANNELS : number of CMA channels in I/O network (up to 4) … … 454 454 "The NB_DMA_CHANNELS parameter cannot be larger than 4" ); 455 455 456 assert( (NB_TTY_CHANNELS == 1) and457 "The NB_TTY_CHANNELS parameter must be 1" );456 assert( (NB_TTY_CHANNELS >= 1) and (NB_TTY_CHANNELS <= 16) and 457 "The NB_TTY_CHANNELS parameter cannot be larger than 16" ); 458 458 459 459 assert( (NB_NIC_CHANNELS == 2) and … … 801 801 sc_signal<bool> signal_irq_false; 802 802 sc_signal<bool> signal_irq_bdev; 803 sc_signal<bool> signal_irq_mtty_rx ;803 sc_signal<bool> signal_irq_mtty_rx[NB_TTY_CHANNELS]; 804 804 sc_signal<bool> signal_irq_mnic_rx[NB_NIC_CHANNELS]; 805 805 sc_signal<bool> signal_irq_mnic_tx[NB_NIC_CHANNELS]; … … 1156 1156 mtty->p_resetn (signal_resetn); 1157 1157 mtty->p_vci (signal_vci_tgt_mtty); 1158 mtty->p_irq[0] (signal_irq_mtty_rx); 1159 1158 for ( size_t i=0 ; i<NB_TTY_CHANNELS ; i++ ) 1159 { 1160 mtty->p_irq[i] (signal_irq_mtty_rx[i]); 1161 } 1160 1162 std::cout << " - MTTY connected" << std::endl; 1161 1163 … … 1185 1187 else if(i < 4+NB_CMA_CHANNELS) iopi->p_hwi[i] (signal_irq_cdma[i-4]); 1186 1188 else if(i < 8) iopi->p_hwi[i] (signal_irq_false); 1187 else if(i == 8) iopi->p_hwi[i] (signal_irq_bdev); 1188 else if(i == 9) iopi->p_hwi[i] (signal_irq_mtty_rx); 1189 else if(i < 9) iopi->p_hwi[i] (signal_irq_bdev); 1190 else if(i < 16) iopi->p_hwi[i] (signal_irq_false); 1191 else if(i < 16+NB_TTY_CHANNELS) iopi->p_hwi[i] (signal_irq_mtty_rx[i-16]); 1189 1192 else iopi->p_hwi[i] (signal_irq_false); 1190 1193 } … … 1523 1526 { 1524 1527 clusters[0][0]->iob->print_trace(); 1525 clusters[XMAX-1][YMAX-1]->iob->print_trace();1526 1528 // clusters[0][0]->signal_int_vci_tgt_iobx.print_trace( "[SIG]IOB0_INT_TGT"); 1527 1529 // clusters[0][0]->signal_int_vci_ini_iobx.print_trace( "[SIG]IOB0_INT_INI"); … … 1531 1533 // signal_vci_tgt_iob0.print_trace("[SIG]IOB0_IOX_TGT"); 1532 1534 1533 //cdma->print_trace();1534 //signal_vci_tgt_cdma.print_trace("[SIG]IOX_CDMA_TGT");1535 //signal_vci_ini_cdma.print_trace("[SIG]IOX_CDMA_INI");1535 cdma->print_trace(); 1536 signal_vci_tgt_cdma.print_trace("[SIG]IOX_CDMA_TGT"); 1537 signal_vci_ini_cdma.print_trace("[SIG]IOX_CDMA_INI"); 1536 1538 1537 1539 // brom->print_trace(); … … 1541 1543 // signal_vci_tgt_mtty.print_trace("[SIG]IOX_MTTY_TGT"); 1542 1544 1543 1544 1545 1545 // bdev->print_trace(); 1546 // signal_vci_tgt_bdev.print_trace("[SIG]BDEV_TGT"); 1547 // signal_vci_ini_bdev.print_trace("[SIG]BDEV_INI"); 1546 1548 1547 1549 // mnic->print_trace(); … … 1551 1553 // signal_vci_tgt_fbuf.print_trace("[SIG]FBUF"); 1552 1554 1553 1554 1555 1556 1555 // iopi->print_trace(); 1556 // signal_vci_ini_iopi.print_trace("[SIG]IOPI_INI"); 1557 // signal_vci_tgt_iopi.print_trace("[SIG]IOPI_TGT"); 1558 // iox_network->print_trace(); 1557 1559 1558 1560 // interrupts 1559 1561 if (signal_irq_bdev) std::cout << "### IRQ_BDEV ACTIVE" << std::endl; 1560 if (signal_irq_mtty_rx ) std::cout << "### IRQ_MTTY ACTIVE"<< std::endl;1562 if (signal_irq_mtty_rx[0]) std::cout << "### IRQ_MTTY_RX[0] ACTIVE" << std::endl; 1561 1563 if (signal_irq_mnic_rx[0]) std::cout << "### IRQ_MNIC_RX[0] ACTIVE" << std::endl; 1562 1564 if (signal_irq_mnic_rx[1]) std::cout << "### IRQ_MNIC_RX[1] ACTIVE" << std::endl;
Note: See TracChangeset
for help on using the changeset viewer.