This is an excellent question. Within the novel, one of the most significant actions that shaped Amir was his childhood experiences with Hassan. They were best friends and Hassan was always a faithful friend, almost to a fault. However, when Hassan was in need, Amir pretended not to see and did nothing to help. For this reason, Hassan was raped. Amir never forgot this. His guilt was ever before him.
Later in the novel, when Amir found out that Hassan had a child and that Hassan and Farzana were killed by the Taliban, he knew what he had to do. There was a way for Amir to atone for his misdeeds in the past. So, he went to Afghanistan to get the son of Hassan, Sorhab. Amir succeeds even though it was difficult. Finally, he was able to stand for what was right. Redemption is the point. Also Amir's journey to Kabul shows that he is now a man.
On another note, this violence also shows the brutality of the Taliban. When the Taliban came to Baba's old house, where Hassan was a custodian, the Taliban shot him. When Farzana ran out to help Hassan, they shot her as well. And they placed Sorhab in an orphanage. We can read about these events in chapters 16 and 17.