Ignore:
Timestamp:
Sep 2, 2010, 2:22:12 PM (14 years ago)
Author:
guthmull
Message:

Add broadcast limitation compatibility, indicate the type of response when possible

Location:
trunk/modules/vci_mem_cache_v4/caba/source
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/modules/vci_mem_cache_v4/caba/source/include/vci_mem_cache_v4.h

    r2 r82  
    354354      const soclib::common::AddressMaskingTable<vci_addr_t>   m_nline;
    355355
     356      // broadcast address
     357      vci_addr_t broadcast_addr;
     358
    356359      //////////////////////////////////////////////////
    357360      // Others registers
  • trunk/modules/vci_mem_cache_v4/caba/source/src/vci_mem_cache_v4.cpp

    r57 r82  
    321321      assert(nways <= 32);
    322322
     323      // Set the broadcast address with Xmin,Xmax,Ymin,Ymax set to maximum
     324      broadcast_addr = 0x3 | (0x7C1F << (vci_param::N-20));
    323325
    324326      // Get the segments associated to the MemCache
     
    23242326            }
    23252327            if ( (p_vci_tgt_cleanup.cmd.read() == vci_param::CMD_WRITE) &&
    2326                 (((addr_t)(p_vci_tgt_cleanup.address.read())) != BROADCAST_ADDR) &&
     2328                (((addr_t)(p_vci_tgt_cleanup.address.read())&0x3) != 0x3) &&
    23272329                reached) {
    23282330
     
    42474249        p_vci_tgt.rtrdid   = r_write_to_tgt_rsp_trdid.read();
    42484250        p_vci_tgt.rpktid   = r_write_to_tgt_rsp_pktid.read();
    4249         p_vci_tgt.rerror   = 0;
     4251        p_vci_tgt.rerror   = 0x2 & ( (1 << (vci_param::E + 1)) - 1); // Write OK
    42504252        p_vci_tgt.reop     = true;
    42514253        break;
     
    42564258        p_vci_tgt.rtrdid   = r_cleanup_to_tgt_rsp_trdid.read();
    42574259        p_vci_tgt.rpktid   = r_cleanup_to_tgt_rsp_pktid.read();
    4258         p_vci_tgt.rerror   = 0;
     4260        p_vci_tgt.rerror   = 0; // Can be a SC rsp
    42594261        p_vci_tgt.reop     = true;
    42604262        break;
     
    42834285        p_vci_tgt.rtrdid   = r_init_rsp_to_tgt_rsp_trdid.read();
    42844286        p_vci_tgt.rpktid   = r_init_rsp_to_tgt_rsp_pktid.read();
    4285         p_vci_tgt.rerror   = 0;
     4287        p_vci_tgt.rerror   = 0; // Can be a SC rsp
    42864288        p_vci_tgt.reop     = true;     
    42874289        break;
     
    43314333      case INIT_CMD_XRAM_BRDCAST:
    43324334        p_vci_ini.cmdval  = true;
    4333         p_vci_ini.address = BROADCAST_ADDR;
     4335        p_vci_ini.address = broadcast_addr;
    43344336        p_vci_ini.wdata   = (uint32_t)r_xram_rsp_to_init_cmd_nline.read();
    43354337        p_vci_ini.be      = ((r_xram_rsp_to_init_cmd_nline.read() >> 32) & 0x3);
     
    43414343      case INIT_CMD_WRITE_BRDCAST:
    43424344        p_vci_ini.cmdval  = true;
    4343         p_vci_ini.address = BROADCAST_ADDR;
     4345        p_vci_ini.address = broadcast_addr;
    43444346        p_vci_ini.wdata   = (addr_t)r_write_to_init_cmd_nline.read();
    43454347        p_vci_ini.be      = ((r_write_to_init_cmd_nline.read() >> 32) & 0x3);
     
    43964398      case INIT_CMD_SC_BRDCAST:
    43974399        p_vci_ini.cmdval  = true;
    4398         p_vci_ini.address = BROADCAST_ADDR;
     4400        p_vci_ini.address = broadcast_addr;
    43994401        p_vci_ini.wdata   = (addr_t)r_llsc_to_init_cmd_nline.read();
    44004402        p_vci_ini.be      = ((r_llsc_to_init_cmd_nline.read() >> 32) & 0x3);
     
    45074509          p_vci_tgt_cleanup.rpktid = r_cleanup_pktid.read();
    45084510          p_vci_tgt_cleanup.rtrdid = r_cleanup_trdid.read();
    4509           p_vci_tgt_cleanup.rerror = 0;
     4511          p_vci_tgt_cleanup.rerror = 0x2 & ( (1 << (vci_param::E + 1)) - 1);
    45104512          p_vci_tgt_cleanup.reop   = 1;
    45114513          break;
Note: See TracChangeset for help on using the changeset viewer.