2 Kings says Jehoiakim was the son of Josiah, and Jehoiachin was the son of Jehoiakim. 1 Chronicles says the same thing.
Matthew’s genealogy, on the other hand, claims that Josiah was the father of Jeconiah (AKA Jehoiachin), rather than his grandfather.