Ignore:
Timestamp:
Nov 3, 2014, 11:15:07 AM (10 years ago)
Author:
alain
Message:

Removing support for the (use_tty, use_tim, use_nic, use_cma) constructs in the mapping.
Introducing the "display" application using the CMA component to acces the frame buffer.

Location:
soft/giet_vm/giet_python
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • soft/giet_vm/giet_python/genmap

    r432 r441  
    102102                   help = 'map the "router" application for the GietVM' )
    103103
     104parser.add_option( '--display', action = 'store_true', dest = 'display',     
     105                   default = False,
     106                   help = 'map the "display" application for the GietVM' )
     107
    104108######################################################################################
    105109#   Get command line arguments
     
    129133map_convol    = options.convol      # map "convol" application if True
    130134map_router    = options.router      # map "convol" application if True
     135map_display   = options.display     # map "convol" application if True
    131136
    132137######################################################################################
     
    155160    app = __import__( 'transpose' )
    156161    app.transpose( mapping )
    157     print '[genmap] application "transpose" loaded'
     162    print '[genmap] application "transpose" will be loaded'
    158163
    159164if ( map_sort ):     
    160165    app = __import__( 'sort' )
    161166    app.sort( mapping )
    162     print '[genmap] application "sort" loaded'
     167    print '[genmap] application "sort" will be loaded'
    163168
    164169if ( map_convol ):     
    165170    app = __import__( 'convol' )
    166171    app.convol( mapping )
    167     print '[genmap] application "convol" loaded'
     172    print '[genmap] application "convol" will be loaded'
    168173
    169174if ( map_router ):     
    170175    app = __import__( 'router' )
    171176    app.router( mapping )
    172     print '[genmap] application "router" loaded'
     177    print '[genmap] application "router" will be loaded'
     178
     179if ( map_display ):     
     180    app = __import__( 'display' )
     181    app.display( mapping )
     182    print '[genmap] application "display" will be loaded'
    173183
    174184######################################################################################
  • soft/giet_vm/giet_python/mapping.py

    r425 r441  
    1919#                        a set of 'Task'      (user tasks mapping)
    2020# - A 'Vseg'   contains  a set of 'Vobj'
    21 # - A 'Periph' contains  a set of 'Irq'       (only for XCU, ICU and PIC types )
     21# - A 'Periph' contains  a set of 'Irq'       (only for XCU and PIC types )
    2222# - A 'Coproc' contains  a set of 'Cpports'   (one port per MWMR channel)
    2323##########################################################################################
     
    5454                  'DMA',
    5555                  'FBF',
    56                   'ICU',
    5756                  'IOB',
    5857                  'IOC',
     
    173172        self.x_size         = x_size
    174173        self.y_size         = y_size
    175         self.nprocs      = nprocs
     174        self.nprocs         = nprocs
    176175        self.x_width        = x_width
    177176        self.y_width        = y_width
     
    494493                 stackname,             # name of vobj containing stack
    495494                 heapname,              # name of vobj containing heap
    496                  startid,               # index in start_vector
    497                  usetty = False,        # request a private TTY channel
    498                  usenic = False,        # request a private NIC channel
    499                  usecma = False,        # request a private CMA channel
    500                  usehba = False,        # request a private HBA channel
    501                  usetim = False ):      # request a private TIM channel
     495                 startid ):             # index in start_vector
    502496
    503497        assert (x < self.x_size) and (y < self.y_size)
     
    505499
    506500        # add one task into mapping
    507         task = Task( name, trdid, x, y, lpid, stackname, heapname, startid,
    508                      usetty, usenic, usecma, usehba, usetim )
     501        task = Task( name, trdid, x, y, lpid, stackname, heapname, startid )
    509502        vspace.tasks.append( task )
    510503        task.index = self.total_tasks
     
    854847        seg_fbf_size = 0
    855848
    856         nb_icu       = 0
    857         icu_channels = 0
    858         seg_icu_base = 0xFFFFFFFF
    859         seg_icu_size = 0
    860 
    861849        nb_iob       = 0
    862850        iob_channels = 0
     
    941929                    nb_fbf +=1
    942930
    943                 elif ( periph.ptype == 'ICU' ):
    944                     seg_icu_base = periph.pseg.base & 0xFFFFFFFF
    945                     seg_icu_size = periph.pseg.size
    946                     icu_channels = periph.channels
    947                     nb_icu +=1
    948 
    949931                elif ( periph.ptype == 'IOB' ):
    950932                    seg_iob_base = periph.pseg.base & 0xFFFFFFFF
     
    10191001                    xcu_arg      = periph.arg
    10201002                    nb_xcu +=1
    1021 
    1022         # don't mix ICU and XCU
    1023         assert ( nb_icu*nb_xcu == 0 )
    10241003
    10251004        # no more than two access to external peripherals
     
    11681147        s += '#define SEG_FBF_BASE           0x%x\n'  % seg_fbf_base
    11691148        s += '#define SEG_FBF_SIZE           0x%x\n'  % seg_fbf_size
    1170         s += '\n'
    1171         s += '#define SEG_ICU_BASE           0x%x\n'  % seg_icu_base
    1172         s += '#define SEG_ICU_SIZE           0x%x\n'  % seg_icu_size
    11731149        s += '\n'
    11741150        s += '#define SEG_IOB_BASE           0x%x\n'  % seg_iob_base
     
    13261302                    s += '    reg = <0x%x  0x%x  0x%x>;\n' % (msb, lsb, size)
    13271303                    s += '  };\n\n'
    1328 
    1329                 # search ICU (non supported by Linux)
    1330                 if ( periph.ptype == 'ICU' ):
    1331                     print '[genmap warning] in linux_dts() : ICU peripheral not supported by LINUX'
    13321304
    13331305            # we need one interrupt controler in any cluster containing peripherals
     
    17621734                    sys.exit(1)
    17631735
    1764                 # research ICU component
    1765                 elif ( periph.ptype == 'ICU' ):
    1766                     print '[genmap error] in netbsd_dts() : ICU peripheral not supported by NetBSD'
    1767                     sys.exit(1)
    1768 
    17691736        # topology
    17701737        s += '\n'
     
    20892056                  stackname,
    20902057                  heapname,
    2091                   startid,
    2092                   usetty = False,
    2093                   usenic = False,
    2094                   usecma = False,
    2095                   usehba = False,
    2096                   usetim = False ):
     2058                  startid ):
    20972059
    20982060        self.index     = 0             # global index value set by addTask()
     
    21052067        self.heapname  = heapname      # name of vobj containing the heap
    21062068        self.startid   = startid       # index in start_vector
    2107         self.usetty    = usetty        # request a private TTY channel
    2108         self.usenic    = usenic        # request a private NIC channel
    2109         self.usecma    = usecma        # request a private CMA channel
    2110         self.usehba    = usehba        # request a private HBA channel
    2111         self.usetim    = usetim        # request a private TIM channel
    21122069        return
    21132070
     
    21232080        s += ' heapname="%s"'              % self.heapname
    21242081        s += ' startid="%d"'               % self.startid
    2125         if self.usetty != 0: s += ' usetty="1"'
    2126         if self.usenic != 0: s += ' usenic="1"'
    2127         if self.usecma != 0: s += ' usehba="1"'
    2128         if self.usehba != 0: s += ' usehba="1"'
    2129         if self.usetim != 0: s += ' usehba="1"'
    21302082        s += ' />\n'
    21312083
     
    21752127        byte_stream += mapping.int2bytes( 4,  vobj_heap_id )    # heap vobj local index
    21762128        byte_stream += mapping.int2bytes( 4,  self.startid )    # index in start vector
    2177         byte_stream += mapping.int2bytes( 4,  self.usetty )     # TTY channel required
    2178         byte_stream += mapping.int2bytes( 4,  self.usenic )     # NIC channel required
    2179         byte_stream += mapping.int2bytes( 4,  self.usecma )     # CMA channel required
    2180         byte_stream += mapping.int2bytes( 4,  self.usehba )     # IOC channel required
    2181         byte_stream += mapping.int2bytes( 4,  self.usetim )     # TIM channel required
    21822129
    21832130        if ( verbose ):
     
    25012448        s += ' channels="%d"'                % self.channels
    25022449        s += ' arg="%d" >\n'                 % self.arg
    2503         if ( (self.ptype == 'PIC') or (self.ptype == 'XCU') or (self.ptype == 'ICU') ):
     2450        if ( (self.ptype == 'PIC') or (self.ptype == 'XCU') ):
    25042451            for irq in self.irqs: s += irq.xml()
    25052452        s += '            </periph>\n'
Note: See TracChangeset for help on using the changeset viewer.