Verses 41 through 53 describe Adonijah's surrender.
Verses 41 through 52 speak of Adonijah's submission to and begging of Solomon. When Adonijah heard that David had made Solomon king, he took hold of the horns of the altar, saying, "Let King Solomon swear to me today that he will not kill his servant with the sword" (v. 51).
Solomon accepted Adonijah and pardoned him (v. 53).
In 2:1-9 David gave the final charge to Solomon his son as the successor to the Davidic throne.
David charged Solomon to be strong and be a man (v. 2).
David continued by charging Solomon to walk in Jehovah's ways and keep His commandments as written in the law of Moses, that he might prosper and that his throne might be established (vv. 3-4). However, as we will see, Solomon eventually became more indulgent than David. As a result, he did not prosper. Rather, he suffered and lost ten tribes of his kingdom.
Finally, in verses 5 through 9 David charged Solomon to end the lives of Joab, who helped Adonijah in his usurpation of the throne (1:7), and Shimei, who cursed David when he was escaping from Absalom (2 Sam. 16:5-13), and to reward the sons of Barzillai, who supported David in the escape from Absalom's rebellion (17:27-29). David's concern here indicates that while he was on his deathbed he had no peace or comfort in his heart. His dealing with these persons was the issue of his indulgence in sin. God forgave him, but God's righteous judgment would not let him go.