Changeset 586


Ignore:
Timestamp:
Nov 1, 2018, 12:33:12 PM (5 years ago)
Author:
alain
Message:

Introduce the txt_type and fbf_type (and the associated use_txt_x & use_fbf_* variables)
in arch_info. For Both the C and python files. This was required to support the tsar_generic_leti architecture.

Location:
trunk/tools/arch_info
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/tools/arch_info/arch_classes.py

    r571 r586  
    4848    'ROM_SCL',         # 1.0
    4949    'FBF_SCL',         # 2.0
     50    'FBF_LTI',         # 2.1
    5051    'IOB_TSR',         # 3.0
    5152    'IOC_BDV',         # 4.0
     
    5960    'TIM_SCL',         # 8.0
    6061    'TXT_TTY',         # 9.0
    61     'TXT_MTY',         # 9.1
     62    'TXT_RS2',         # 9.1
     63    'TXT_MTY',         # 9.2
    6264    'ICU_XCU',         # A.0
    6365    'PIC_TSR',         # B.0
     
    6769    0x00000000,        # 0.0
    6870    0x00010000,        # 1.0
    69     0x00020000,        # 1.0
     71    0x00020000,        # 2.0
     72    0x00020001,        # 2.1
    7073    0x00030000,        # 3.0
    7174    0x00040000,        # 4.0
     
    8083    0x00090000,        # 9.0
    8184    0x00090001,        # 9.1
     85    0x00090002,        # 9.2
    8286    0x000A0000,        # A.0
    8387    0x000B0000,        # B.0
    8488    ]
    8589
    86  #########################################################################################
     90#########################################################################################
    8791class Archinfo( object ):         
    8892#########################################################################################
     
    385389        fbf_arg0     = 0
    386390        fbf_arg1     = 0
     391        use_fbf_scl  = False
     392        use_fbf_lti  = False
    387393
    388394        nb_iob       = 0
     
    430436        txt_base     = 0xFFFFFFFFFFFFFFFF
    431437        txt_size     = 0
     438        use_txt_tty  = False
     439        use_txt_rs2  = False
     440        use_txt_mty  = False
    432441
    433442        nb_icu       = 0
     
    467476                    fbf_size     = device.size
    468477                    fbf_channels = device.channels
     478                    use_fbf_scl  = True
     479                    fbf_arg0     = device.arg0
     480                    fbf_arg1     = device.arg1
     481                    nb_fbf +=1
     482                elif ( device.ptype == 'FBF_LTI' ):
     483                    fbf_base     = device.base
     484                    fbf_size     = device.size
     485                    fbf_channels = device.channels
     486                    use_fbf_lti  = True
    469487                    fbf_arg0     = device.arg0
    470488                    fbf_arg1     = device.arg1
     
    536554                    txt_size     = device.size
    537555                    txt_channels = device.channels
     556                    use_txt_tty  = True
     557                    nb_txt +=1
     558                elif ( device.ptype == 'TXT_RS2' ):
     559                    txt_base     = device.base
     560                    txt_size     = device.size
     561                    txt_channels = device.channels
     562                    use_txt_rs2  = True
     563                    nb_txt +=1
     564                elif ( device.ptype == 'TXT_MTY' ):
     565                    txt_base     = device.base
     566                    txt_size     = device.size
     567                    txt_channels = device.channels
     568                    use_txt_mty  = True
    538569                    nb_txt +=1
    539570
     
    625656        s += '#define USE_IOC_RDK            %d\n'    % use_ioc_rdk
    626657        s += '\n'
     658        s += '#define USE_TXT_TTY            %d\n'    % use_txt_tty
     659        s += '#define USE_TXT_RS2            %d\n'    % use_txt_rs2
     660        s += '#define USE_TXT_MTY            %d\n'    % use_txt_mty
     661        s += '\n'
     662        s += '#define USE_FBF_SCL            %d\n'    % use_fbf_scl
     663        s += '#define USE_FBF_LTI            %d\n'    % use_fbf_lti
     664        s += '\n'
    627665        s += '#define FBUF_X_SIZE            %d\n'    % fbf_arg0
    628666        s += '#define FBUF_Y_SIZE            %d\n'    % fbf_arg1
     
    930968            print '    irq global index = %d / expected = %d' \
    931969                       % (self.index , expected)
    932             sys.exit(1)
    933 
    934970        # compute source device type numerical value
    935971        dev_id = 0xFFFFFFFF
  • trunk/tools/arch_info/arch_info.h

    r571 r586  
    7171    DEV_TYPE_ROM_SCL   = 0x00010000,
    7272    DEV_TYPE_FBF_SCL   = 0x00020000,
     73    DEV_TYPE_FBF_LTI   = 0x00020001,
    7374    DEV_TYPE_IOB_TSR   = 0x00030000,
    7475    DEV_TYPE_IOC_BDV   = 0x00040000,
     
    8283    DEV_TYPE_TIM_SCL   = 0x00080000,
    8384    DEV_TYPE_TXT_TTY   = 0x00090000,
    84     DEV_TYPE_TXT_MTY   = 0x00090001,
     85    DEV_TYPE_TXT_RS2   = 0x00090001,
     86    DEV_TYPE_TXT_MTY   = 0x00090002,
    8587    DEV_TYPE_ICU_XCU   = 0x000A0000,
    8688    DEV_TYPE_PIC_TSR   = 0x000B0000,
  • trunk/tools/arch_info/genarch.py

    r575 r586  
    1414# to store the "arch_info.bin" file are defined by parameters on the command line:
    1515#  --arch=string     : path to directory containing the "arch_info.py" file
    16 #  --bin=string      : path to directory store the "arch_info.bin" file
     16#  --bin=string      : path to directory to store the "arch_info.bin" file
    1717#
    1818# As the target architecture is generic, the following hardware parameters can be
     
    2323#  --nb_ttys=int     : number of TTY channels
    2424#  --nb_nics=int     : number of NIC channels
    25 #  --fbf_size=int    : frame buffer width & heigth
    2625#  --ioc_type=string : can be IOC_BDV , IOC_HBA , IOC_SDC , IOC_SPI
     26#  --txt_type=string : can be TXT_TTY , TXT_MTY
     27#  --fbf_type=string : can be FBF_LTI , FBF_SCL
     28#  --sys_clk=int     : system clock frequency (Hz)
    2729#
    2830# The following parameters can be used to generate the optional "hard_config.h" file,
     
    7173                   help = 'define number ot NIC channels' )
    7274
    73 parser.add_option( '--fbf_size', type = 'int', dest = 'fbf_size',
    74                    default = 128,
    75                    help = 'define frame buffer width and heigth' )
    76 
    7775parser.add_option( '--ioc_type', type = 'string', dest = 'ioc_type',
    7876                   default = 'IOC_BDV',
    79                    help = 'define type of IOC: BDV / HBA / SDC / RDK / SPI' )
     77                   help = 'IOC type : BDV / HBA / SDC / RDK / SPI' )
     78
     79parser.add_option( '--txt_type', type = 'string', dest = 'txt_type',
     80                   default = 'TXT_TTY',
     81                   help = 'TXT type : TTY / RS2 / MTY' )
     82
     83parser.add_option( '--fbf_type', type = 'string', dest = 'fbf_type',
     84                   default = 'FBF_SCL',
     85                   help = 'FBF type : LTI / SCL' )
    8086
    8187parser.add_option( '--sys_clk', type = 'int', dest = 'sys_clk',
    82                    default = 25000,
    83                    help = 'define system clock frequency (25MHz for FPGA, 600MHz for TSARLET)' )
    84 
    85 parser.add_option( '--segs_set', type = 'string', dest = 'segs_set',
    86                    default = 'SIMU',
    87                    help = 'define which set of base addresses to use (may differ between simulation and real machine' )
     88                   default = 50000,
     89                   help = 'system clock frequency (50 KHz simu / 25 MHz FPGA, 600 MHz VLSI)' )
    8890
    8991parser.add_option( '--hard', type = 'string', dest = 'hard_path',
     
    110112nb_cores       = options.nb_cores    # number of cores in a cluster
    111113nb_ttys        = options.nb_ttys     # number of TTY channels           
    112 fbf_size       = options.fbf_size    # frame buffer width & heigth
    113114nb_nics        = options.nb_nics     # number of NIC channels           
    114115ioc_type       = options.ioc_type    # ioc controller type
    115 sys_clk        = options.sys_clk     # system clock frequency in kHz
    116 segs_set       = options.segs_set    # Set of base addresses used (simu or real)
     116txt_type       = options.txt_type    # txt terminal type
     117fbf_type       = options.fbf_type    # fbf terminal type
     118sys_clk        = options.sys_clk     # system clock frequency in Hertz
    117119
    118120hard_path      = options.hard_path   # path for hard_config.h file
     
    143145                        nb_ttys,
    144146                        nb_nics,
    145                         fbf_size,
    146                         ioc_type )
     147                        ioc_type,
     148                        txt_type,
     149                        fbf_type,
     150                        sys_clk )
    147151
    148152print '[genarch] archinfo build for %s' % archinfo.name
Note: See TracChangeset for help on using the changeset viewer.