How to create regAdapter for pipelined protocol like AHB

Hi,

Any one please suggest me how to create regAdapter for pipelined protocol like AHB.

Thanks
Saravanan

In reply to saravanan_kpk:

I belive nothing to be taken care in regAdapter. the driver should have the capability

In reply to saravanan_kpk:

Hello, saravanan_kpk.
I hope I understand your intention correctly.
You can use uvm_reg_frontdoor instead:

  1. Implement your own ahb_frontdoor with single/burst support and analyzing kind of accesses (UVM_READ/UVM_WRITE/UVM_BURST_READ/UVM_BURST_WRITE).
  2. Pass as argument your frontdoor when configure your uvm_reg_map by methods add_reg()/add_mem().
  3. By calling methods read()/write()/burst_read()/burst_write(), you will receive bus requests corresponding with your frontdoor implementation.
    For example, I attach some prototype:

class smt_ahb_burst_frontdoor extends uvm_reg_frontdoor;
  ahb_transaction bus_access;
  //..............
  task body();
    int access_number = my_method_to_count_access(rw_info);
    for (int access_index = 0; access_index < access_number; access_index++) begin
      bus_access = my_method_to_create_ahb_access_from_reg_item(rw_info, access_index);
      `uvm_send(bus_access)
      get_response(rsp);
      my_method_to_analyze_response(rw_info, rsp);
    end
  endtask
  //..............
  function int my_method_to_count_access(uvm_reg_item rw_info);
    my_method_to_count_access = 0;
    if(rw_info.kind inside {UVM_READ, UVM_WRITE})
      my_method_to_count_access = 1;
    else if(rw_info.kind inside {UVM_READ, UVM_WRITE})
      my_method_to_count_access = rw_info.value.size();
  endfunction
  //..............
endclass

Best regards, Maksim.