It occurs to me that you only need your companion for the first room, to open the door, you can just leave him stuck on something thanks to your shield and the ending working as soon as you get to it