OpenCores
URL https://opencores.org/ocsvn/xgate/xgate/trunk

Subversion Repositories xgate

[/] [xgate/] [trunk/] [bench/] [verilog/] [tst_bench_top.v] - Diff between revs 60 and 62

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 60 Rev 62
Line 101... Line 101...
 
 
  parameter CHECK_POINT = 16'h8000;
  parameter CHECK_POINT = 16'h8000;
  parameter CHANNEL_ACK = CHECK_POINT + 2;
  parameter CHANNEL_ACK = CHECK_POINT + 2;
  parameter CHANNEL_ERR = CHECK_POINT + 4;
  parameter CHANNEL_ERR = CHECK_POINT + 4;
 
 
  parameter SYS_RAM_BASE = 24'h0000_0000;
  parameter SYS_RAM_BASE = 24'h00_0000;
 
 
  //
  //
  // wires && regs
  // wires && regs
  //
  //
  reg         mstr_test_clk;
  reg         mstr_test_clk;
Line 116... Line 116...
  reg  [15:0] q, qq;
  reg  [15:0] q, qq;
 
 
  reg         rstn;
  reg         rstn;
  reg         sync_reset;
  reg         sync_reset;
  reg         por_reset_b;
  reg         por_reset_b;
  reg         stop_mode;
 
  reg         wait_mode;
 
  reg         debug_mode;
 
  reg         scantestmode;
  reg         scantestmode;
 
 
  wire [15:0] dat_i;
 
  wire        ack;
 
 
 
  reg  [MAX_CHANNEL:0] channel_req;  // XGATE Interrupt inputs
  reg  [MAX_CHANNEL:0] channel_req;  // XGATE Interrupt inputs
  wire [MAX_CHANNEL:0] xgif;         // XGATE Interrupt outputs
  wire [MAX_CHANNEL:0] xgif;         // XGATE Interrupt outputs
  wire         [  7:0] xgswt;        // XGATE Software Trigger outputs
  wire         [  7:0] xgswt;        // XGATE Software Trigger outputs
  wire                 xg_sw_irq;    // Xgate Software Error interrupt
  wire                 xg_sw_irq;    // Xgate Software Error interrupt
 
 
Line 139... Line 133...
 
 
  reg         mem_wait_state_enable;
  reg         mem_wait_state_enable;
 
 
  wire [15:0] tb_ram_out;
  wire [15:0] tb_ram_out;
 
 
 
  wire [15:0] tb_slave_dout; // WISHBONE data bus output from testbench slave module
 
  wire        error_pulse;   // Error detected output pulse from the testbench slave module
 
  wire        test_reg_ack;  // WISHBONE ack from testbench slave module
 
  wire        ack_pulse;     // Thread ack output pulse from testbench slave module
 
 
 
  wire        wbm_cyc_o;
 
  wire        wbm_stb_o;
 
  wire        wbm_we_o;
 
  wire        wbs_err_o;
 
 
 
 
  // Registers used to mirror internal registers
  // Registers used to mirror internal registers
  reg  [15:0] data_xgmctl;
  reg  [15:0] data_xgmctl;
  reg  [15:0] data_xgchid;
  reg  [15:0] data_xgchid;
  reg  [15:0] data_xgvbr;
  reg  [15:0] data_xgvbr;
  reg  [15:0] data_xgswt;
  reg  [15:0] data_xgswt;
Line 187... Line 192...
    begin
    begin
      mstr_test_clk = 0;
      mstr_test_clk = 0;
      vector = 0;
      vector = 0;
      test_num = 0;
      test_num = 0;
      por_reset_b = 0;
      por_reset_b = 0;
      stop_mode  = 0;
 
      wait_mode  = 0;
 
      debug_mode = 0;
 
      scantestmode = 0;
      scantestmode = 0;
      error_count = 0;
      error_count = 0;
      mem_wait_state_enable = 0;
      mem_wait_state_enable = 0;
      // channel_req = 0;
      // channel_req = 0;
 
 
Line 322... Line 324...
    .slv1_ack( xgate_s_ack ),
    .slv1_ack( xgate_s_ack ),
    .slv1_din( xgate_s_dout ),
    .slv1_din( xgate_s_dout ),
    // Slave #2 Bus I/O
    // Slave #2 Bus I/O
    .slv2_stb( slv2_stb ),
    .slv2_stb( slv2_stb ),
    .slv2_ack( test_reg_ack ),
    .slv2_ack( test_reg_ack ),
    .slv2_din( ram_dout ),
    .slv2_din( tb_slave_dout ),
    // Miscellaneous
    // Miscellaneous
    .host_clk( mstr_test_clk ),
    .host_clk( mstr_test_clk ),
    .risc_clk( mstr_test_clk ),
    .risc_clk( mstr_test_clk ),
    .rst( rstn ),  // No Connect
    .rst( rstn ),  // No Connect
    .err( 1'b0 ),  // No Connect
    .err( 1'b0 ),  // No Connect
Line 364... Line 366...
          .xgif( xgif ),             // XGATE Interrupt Flag output
          .xgif( xgif ),             // XGATE Interrupt Flag output
          .xg_sw_irq( xg_sw_irq ),   // XGATE Software Error Interrupt Flag output
          .xg_sw_irq( xg_sw_irq ),   // XGATE Software Error Interrupt Flag output
          .xgswt( xgswt ),
          .xgswt( xgswt ),
          .risc_clk( mstr_test_clk ),
          .risc_clk( mstr_test_clk ),
          .chan_req_i( {channel_req[MAX_CHANNEL:40], xgswt, channel_req[31:0]} ),
          .chan_req_i( {channel_req[MAX_CHANNEL:40], xgswt, channel_req[31:0]} ),
 
          .debug_mode_i( 1'b0 ),
 
          .secure_mode_i( 1'b0 ),
          .scantestmode( scantestmode )
          .scantestmode( scantestmode )
  );
  );
 
 
  tb_slave #(.DWIDTH(16),
  tb_slave #(.DWIDTH(16),
             .SINGLE_CYCLE(1'b1))
             .SINGLE_CYCLE(1'b1))
Line 376... Line 380...
          .wb_clk_i( mstr_test_clk ),
          .wb_clk_i( mstr_test_clk ),
          .wb_rst_i( 1'b0 ),
          .wb_rst_i( 1'b0 ),
          .arst_i( rstn ),
          .arst_i( rstn ),
          .wb_adr_i( sys_adr[3:1] ),
          .wb_adr_i( sys_adr[3:1] ),
          .wb_dat_i( sys_dout ),
          .wb_dat_i( sys_dout ),
          .wb_dat_o(),
          .wb_dat_o( tb_slave_dout),
          .wb_we_i( sys_we ),
          .wb_we_i( sys_we ),
          .wb_stb_i( slv2_stb ),
          .wb_stb_i( slv2_stb ),
          .wb_cyc_i( sys_cyc ),
          .wb_cyc_i( sys_cyc ),
          .wb_sel_i( sys_sel ),
          .wb_sel_i( sys_sel ),
          .wb_ack_o( test_reg_ack ),
          .wb_ack_o( test_reg_ack ),
Line 1375... Line 1379...
  input  [DWIDTH-1:0] wb_dat_i,     // databus input
  input  [DWIDTH-1:0] wb_dat_i,     // databus input
  input               wb_we_i,      // write enable input
  input               wb_we_i,      // write enable input
  input               wb_stb_i,     // stobe/core select signal
  input               wb_stb_i,     // stobe/core select signal
  input               wb_cyc_i,     // valid bus cycle input
  input               wb_cyc_i,     // valid bus cycle input
  input         [1:0] wb_sel_i,     // Select byte in word bus transaction
  input         [1:0] wb_sel_i,     // Select byte in word bus transaction
  // PIT IO Signals
  // Slave unique IO Signals
  output reg          error_pulse,  // Error detected output pulse
  output reg          error_pulse,  // Error detected output pulse
  output reg          ack_pulse,    // Thread ack output pulse
  output reg          ack_pulse,    // Thread ack output pulse
  input        [19:0] vector
  input        [19:0] vector
  );
  );
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.