phy_mdc also one clock generated by the dut. actually my requirement is am having one set of phy_mdio and phy_mdc, with single set. I have to choose one phy from the 2 phys. This single mdio should share between two phys. to get this functionality am trying like this
this mdio and mdc am taking in one interface mdio_if and remining phy related signals am taking in another interface phy_if.
interface mdio_if (input bit phy_mdc,clk);
wire phy_mdio;
bit phy_rst_n;
endinterface
interface phy_if (input bit phy_mdc,clk_p);
bit phy_intr;
bit phy_rst_n;
wire phy_mdio;
eninterface
module l4_crypt_top_tb();
mdio_if mdio(phy_mdc,clk);
phy_if phy_addr_4(phy_mdc,clk);
phy_if phy_addr_7(phy_mdc,clk);
l4_crypt_test_top DUT(.clk_p (clk_p),
.phy_mdc (phy_mdc),
.phy_mdio (mdio.phy_mdio),
.phy_rst_n_0 ( phy_addr_4.phy_rst_n),
.phy_intr_0 ( phy_addr_4.phy_intr),
.phy_rst_n_1 ( phy_addr_7.phy_rst_n), .phy_intr_1 ( phy_addr_7.phy_intr)),