"And Eli the priest sat" (1 Samuel 1:9). Rabbi Ami said: Even for the kings of the house of David there is no sitting in the Temple court. And for whom was sitting permitted? For the high priest, as it is said, "And Eli the priest sat upon the seat." If so, what of "And King David came and sat before the LORD" (2 Samuel 7:18)? It means that he settled himself in prayer. "And Eli the priest sitting" - this teaches that on that very day they appointed him high priest.
Eli the Priest Sat Upon the Seat
Yalkut Shimoni on Nach 78:1
ועלי הכהן ישב. אמר רבי אמי אף למלכי בית דוד אין ישיבה בעזרה ולמי היתה ישיבה לכהן גדול שנאמר ועלי הכהן ישב על הכסא. אם כן מהו ויבא המלך דוד וישב לפני ה' שישב עצמו בתפלה. ועלי הכהן יושב מלמד שבאותו יום מינוהו כהן גדול: