Etymology
Today it means: Used to express assent, especially to a male superior. Full definition →
From yes + sir.
Etymology from Wiktionary, CC BY-SA 4.0.