First-principles study of lattice instabilities in ferromagnetic Ni2MnGa