The Prophet ﷺ was leading the prayer and stood up after the second rakah. The people said, "Subhan Allah," to alert him, but he continued. When he finished his prayer, he performed two prostrations and then gave the salam.
أخبرنا أبو داود سليمان بن سيف قال حدثنا وهب بن جرير قال حدثنا شعبة عن يحيى بن سعيد عن عبد الرحمن الأعرج
أن النبي ﷺ صلى فقام في الركعتين فسبحوا فمضى فلما فرغ من صلاته سجد سجدتين ثم سلم