Changeset 546
- Timestamp:
- Apr 5, 2015, 12:02:09 AM (10 years ago)
- Location:
- soft/giet_vm/giet_python
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
soft/giet_vm/giet_python/genmap
r539 r546 74 74 help = 'define frame buffer width and heigth' ) 75 75 76 parser.add_option( '--ioc', type = 'string', dest = 'ioc_type', 77 default = 'BDV', 78 help = 'define type of IOC: BDV / HBA / SDC / RDK' ) 79 76 80 parser.add_option( '--v', action = 'store_true', dest = 'verbose', 77 81 default = False, … … 141 145 nb_ttys = options.nb_ttys # number of TTY channels 142 146 fbf_size = options.fbf_size # frame buffer width & heigth 147 ioc_type = options.ioc_type # ioc controller type 143 148 144 149 verbose = options.verbose # report on map.bin generation if True … … 178 183 179 184 # build mapping calling the function (function name) 180 mapping = select.arch( x_size, y_size, nb_procs, nb_ttys, fbf_size )185 mapping = select.arch( x_size, y_size, nb_procs, nb_ttys, fbf_size, ioc_type ) 181 186 print '[genmap] platform %s build' % mapping.name 182 187 -
soft/giet_vm/giet_python/mapping.py
r539 r546 69 69 'BDV', 70 70 'HBA', 71 'SPI', 72 'NONE', 71 'SDC', 73 72 ] 74 73 … … 101 100 'ISR_MMC', 102 101 'ISR_DMA', 103 'ISR_S PI',102 'ISR_SDC', 104 103 'ISR_MWR', 105 104 'ISR_HBA', … … 111 110 'PTAB', 112 111 'PERI', 113 'MWMR', # deprecated114 'LOCK', # deprecated115 112 'BUFFER', 116 'BARRIER', # deprecated117 'CONST', # deprecated118 'MEMSPACE', # deprecated119 113 'SCHED', 120 114 'HEAP', … … 339 333 if ( ((prev.vbase + prev.length) > vbase ) and 340 334 ((vbase + length) > prev.vbase) and 341 (prev.name != name) ):335 (prev.name[0:15] != name[0:15]) ): 342 336 print '[genmap error] in addGlobal()' 343 337 print ' global vseg %s overlap %s' % (name, prev.name) 344 print ' %s : base = %x / size = %x' %( name, vbase, size)345 print ' %s : base = %x / size = %x' %( prev.name, prev.vbase, prev.size)338 print ' %s : base = %x / size = %x' %(name, vbase, length) 339 print ' %s : base = %x / size = %x' %(prev.name, prev.vbase, prev.length) 346 340 sys.exit(1) 347 341 … … 508 502 byte_stream += self.int2bytes(4, self.total_irqs) 509 503 byte_stream += self.int2bytes(4, self.total_periphs) 510 byte_stream += self.str2bytes( 32, self.name)504 byte_stream += self.str2bytes(64, self.name) 511 505 512 506 if ( verbose ): … … 786 780 787 781 use_bdv = False 788 use_s pi= False782 use_sdc = False 789 783 use_hba = False 790 784 … … 828 822 if ( periph.subtype == 'BDV' ): use_bdv = True 829 823 elif ( periph.subtype == 'HBA' ): use_hba = True 830 elif ( periph.subtype == 'S PI' ): use_spi= True824 elif ( periph.subtype == 'SDC' ): use_sdc = True 831 825 832 826 elif ( periph.ptype == 'MMC' ): … … 910 904 if use_hba : nb_iocs += 1 911 905 if use_bdv : nb_iocs += 1 912 if use_s pi: nb_iocs += 1906 if use_sdc : nb_iocs += 1 913 907 if self.use_ramdisk: nb_iocs += 1 914 908 assert ( nb_iocs == 1 ) … … 1021 1015 s += '#define USE_PIC %d\n' % ( nb_pic != 0 ) 1022 1016 s += '#define USE_FBF %d\n' % ( nb_fbf != 0 ) 1017 s += '#define USE_NIC %d\n' % ( nb_nic != 0 ) 1023 1018 s += '\n' 1024 1019 s += '#define USE_IOC_BDV %d\n' % use_bdv 1025 s += '#define USE_IOC_S PI %d\n' % use_spi1020 s += '#define USE_IOC_SDC %d\n' % use_sdc 1026 1021 s += '#define USE_IOC_HBA %d\n' % use_hba 1027 1022 s += '#define USE_IOC_RDK %d\n' % self.use_ramdisk … … 1506 1501 sys.exit(1) 1507 1502 1508 elif ( periph.subtype == 'S PI' ):1509 1510 # get irq line index associated to s pi1503 elif ( periph.subtype == 'SDC' ): 1504 1505 # get irq line index associated to sdc 1511 1506 irq_in = 0xFFFFFFFF 1512 1507 for irq in irq_tgt.irqs: 1513 if ( irq.isrtype == 'ISR_S PI' ): irq_in = irq.srcid1508 if ( irq.isrtype == 'ISR_SDC' ): irq_in = irq.srcid 1514 1509 if ( irq_in == 0xFFFFFFFF ): 1515 1510 print '[genmap error] in netbsd.dts()' 1516 print ' ISR_S PInot found'1511 print ' ISR_SDC not found' 1517 1512 sys.exit(1) 1518 1513 1519 1514 s += ' %s@0x%x {\n' % (periph.pseg.name, periph.pseg.base) 1520 s += ' device_type = "soclib:s pi";\n'1515 s += ' device_type = "soclib:sdc";\n' 1521 1516 s += ' irq = <&{/%s@0x%x} %d>;\n' % (irq_tgt.pseg.name,irq_tgt.pseg.base,irq_in) 1522 1517 s += ' reg = <0x%x 0x%x 0x%x>;\n' % (msb, lsb, size)
Note: See TracChangeset
for help on using the changeset viewer.