These were their cities unto the reign of David - It appears that David took some of the cities of the Simeonites, and added them to Judah; Ziklag for instance, 1 Samuel 27:6.
As the tribe of Simeon had withdrawn their allegiance from the house of David, the kings of Judah extended their domination as far as possible into the territories of that tribe, so that they were obliged to seek pasture for their flocks at Gedor, and in the mountains of Seir, as we find 1 Chronicles 4:39-42.
Unto the reign of David - It is not quite clear why this clause is added. Perhaps the writer is quoting from a document belonging to David‘s reign. Or, he may mean that some of the cities, as Ziklag 1 Samuel 27:6, were lost to Simeon about David‘s time.