“But they shall serve Yahweh,
They shall serve David,
Whom I will raise up for them.”
Yahweh said that they had to serve him. They also had to serve David the king. As King David was dead, there would be someone from the house of David who would be raised up to be king in this future time.