  We have performed high-precision mass measurements of neutron-rich rare-earth
Tb, Dy and Ho isotopes using the Phase-Imaging Ion-Cyclotron-Resonance
technique at the JYFLTRAP double Penning trap. We report on the first
experimentally determined mass values for $^{169}$Tb, $^{170}$Dy and
$^{171}$Dy, as well as the first direct mass measurements of $^{169}$Dy and
$^{169\text{-}171}$Ho. For $^{170}$Ho, the two long-lived ground and isomeric
states were resolved and their mass measured, yielding an isomer excitation
energy of $E_\text{exc}=150.8(54)$ keV. In addition, we have performed
independent crosschecks of previous Penning-trap values obtained for
$^{167\text{,} 168}$Tb and $^{167\text{,} 168}$Dy. We have extended the
systematics of two-neutron separation energies to the neutron midshell at
$N=104$ in all of the studied isotopic chains. Our updated and new mass
measurements provide better constraints for the neutron-capture reaction rates
relevant to the astrophysical rapid neutron capture (r) process. The r-process
abundances calculated with the new mass values seem to produce a steeper
minimum at A=170 and differ by around 15-30\% from the abundances computed with
the Atomic Mass Evaluation 2020 values.
