22 lines
451 B
Systemverilog
22 lines
451 B
Systemverilog
`ifndef __ROUTING__SVH__
|
|
`define __ROUTING__SVH__
|
|
|
|
`include <params.svh>
|
|
|
|
function automatic logic [INTERFACE_ADDR_LEN - 1:0] next_hop(input logic [ROSE_ADDR_LEN - 1:0] interface_addr);
|
|
case(interface_addr)
|
|
0:
|
|
return 0;
|
|
1:
|
|
return 1;
|
|
2:
|
|
return 2;
|
|
3:
|
|
return 3;
|
|
default:
|
|
return 0;
|
|
endcase // case (interface_addr)
|
|
endfunction // next_hop
|
|
|
|
`endif
|