The phrase Samuel served the Lord refers to the religious duties of Levites and priests (see, for example, Numbers 3:4; 8:19, 24; Deuteronomy 18:7). Samuel, like Eli's sons, was a Levite (see study note on 1 Samuel 1:1). However, unlike Eli's sons, Samuel performed his duties well.
He wore a linen garment similar to what priests wore when serving in the sanctuary (see study note on 1 Samuel 22:18).