Periodic solutions for second order Hamiltonian systems