library ieee;
use ieee.std_logic_1164.all;

entity reset_synchronizer is
	 port(
		 clock_in			: in  std_logic;
		 async_reset_n_in	: in  std_logic;
		 sync_reset_out		: out std_logic
	     );
end reset_synchronizer;

architecture synthesis of reset_synchronizer is	 
signal reset_ff 	: std_logic;	
signal async_reset	: std_logic;
begin				  
	async_reset <= not async_reset_n_in;
	process (clock_in, async_reset)
	begin		 
		if async_reset = '1' then
			reset_ff <= '1';
			sync_reset_out <= '1';
		elsif rising_edge(clock_in) then	
			reset_ff <= '0';
			sync_reset_out <= reset_ff;
		end if;
	end process	;
end synthesis;