A man who was holding his relatives captive inside his home in southern Brazil was killed by police after earlier shooting and killing his father, brother and a police officer, local authorities said.

Armed with two pistols and two carbines, the man, a 45-year-old professional driver who was said to be suffering from psychological problems, also wounded his mother, his brother’s wife and six of the policemen who had surrounded the house for nine hours.

The events unfolded on the night of Tuesday to Wednesday in Novo Aburgo, on the outskirts of Porto Alegre, the capital of Rio Grande do Sul. Two of the injured police officers are hospitalized in serious condition, said the Minister of the Interior of that State, Sandro Caron.

The perpetrator had a license to carry firearms for sporting purposes. More than 300 bullets were found in his house.

Police were dispatched to the scene after receiving a call from the 45-year-old’s father. The attacker “greeted” the police with a barrage of fire, said the governor of Rio Grande do Sul, Eduardo Leyte. The police returned fire and the gunman was killed.

Sandro Caron explained that the assailant refused any attempt to negotiate and started shooting at his relatives and the police.

His motive remains unclear.