When he came to, he found himself locked in a dark room.
Literal
Eyes [obj-を] awakened-and-saw [discovery-と], he [topic-は] dark room [in-に] locked-in-was.
閉じこめられていた layers passive (閉じこめられる, 'be confined/locked in') with ~ていた (state discovered upon waking). A tense narrative moment — the discovery と sets up the dramatic reveal.