Maverick dies in the opening scene. If you watch closely, you'll see he has no shadow while they are playing football on the beach. He's a ghost.
Everything from the moment he enters the airforce base is his journey through limbo. His soul undoing the damage of his life by redeeming itself in the afterlife.
Saving Gooses life, reconciling with Jennifer Connelly, making amends with Iceman, realising that combativeness is not an essential element to combat. It all took place in the short space between 10g and 10.1g as his brain started to collapse under the pressure.
There was no mission to Iran. The entire movie was a ghost story.