We construct the equation of state in a wide-density range for neutron stars within relativistic Hartree-Fock approximation. The properties of uniform and nonuniform nuclear matter are studied consistently. The tensor couplings of vector mesons to baryons due to exchange contributions (Fock terms) are included, and the change of baryon internal structure in matter is also taken into account using the quark-meson coupling model. The Thomas-Fermi calculation is adopted to describe nonuniform matter, where the lattice of nuclei and the neutron drip out of nuclei are considered. Even if hyperons exist in the core of a neutron star, we obtain the maximum neutron-star mass of 1.95M ⊙, which is consistent with the recently observed massive pulsar, PSR J1614-2230. In addition, the strange vector (φ) meson also plays a important role in supporting a massive neutron star.