On his return to Edoras, Éomer reports this meeting to Théoden, and is imprisoned on the orders of Gríma Wormtongue, Théoden's sinister advisor. Aragorn, Gimli and Legolas arrive in Edoras with the wizard Gandalf, who releases the king from Gríma's spell. Éomer is set free and restored to honour. He fights at the battle of Helm's Deep, where the forces of Rohan drive Saruman's army of Orcs and Dunlendings from the walls of the Hornburg, buying enough time for Gandalf to arrive with Erkenbrand and his men of the Westfold of Rohan.