- added gigabit--mode

Committed on the Free edition of March Hare Software CVSNT Server.
Upgrade to CVS Suite for more features and support:
http://march-hare.com/cvsnt/


git-svn-id: http://moon:8086/svn/vhdl/trunk@860 cc03376c-175c-47c8-b038-4cd826a8556b
This commit is contained in:
2010-04-06 18:30:31 +00:00
parent d7b6040c38
commit d1e30cfa5c
7 changed files with 151 additions and 102 deletions
+24 -4
View File
@@ -99,7 +99,8 @@ ARCHITECTURE behavior OF emac_tx IS
signal piso8_dout : unsigned(3 downto 0);
signal reset_pipe : unsigned(31 downto 0);
signal Gbps_en : std_logic;
subtype ifg_cnt_t is natural range 0 to 23; -- 10/100 mbps
-- subtype ifg_cnt_t is natural range 0 to 11; -- 1000 mbps
@@ -355,6 +356,14 @@ mem_free_host:
end if;
end process;
host2xfer_sync_register:
process(mii_tx_clk)
begin
if rising_edge(mii_tx_clk) then
Gbps_en <= ctrl_in.Gbps_en;
end if;
end process;
------------------------------------------------------------------
-- Fill stuff
------------------------------------------------------------------
@@ -604,7 +613,7 @@ inst_piso32 : entity work.piso
);
piso32_dout_en <= piso8_din_rdy and ifg_idle;
piso32_dout_en <= ifg_idle when Gbps_en = '1' else (piso8_din_rdy and ifg_idle);
inst_piso8 : entity work.piso
GENERIC MAP
@@ -627,7 +636,18 @@ inst_piso8 : entity work.piso
);
mii_tx_en <= piso8_dout_vld;
mii_tx <= "0000" & piso8_dout;
mii_output_register:
process(mii_tx_clk)
begin
if rising_edge(mii_tx_clk) then
if Gbps_en = '1' then
mii_tx_en <= piso32_dout_vld;
mii_tx <= piso32_dout;
else
mii_tx_en <= piso8_dout_vld;
mii_tx <= "0000" & piso8_dout;
end if;
end if;
end process;
end behavior;