Prior to the release of Thor: Ragnarok, it leaked that Matt Damon had a cameo role.
Now Kevin Feige explains how that role came to be, which also happened to feature a scene with both Sam Neill and Chris Hemsworth's brother, Luke Hemsworth.
The scene featured Thor back in Asgard after fighting Surtur discovering that Loki had pretended to be Odin and had taken over the crown. "Odin" was watching a play where Loki was the hero, played by Matt Damon, with Odin played by Sam Neill, Thor played by Luke Hemsworth, and Sif played by Charlotte Nicdao.
Via Slash Film:
We had this idea to do this stage play that brings some people up to speed on the fact that the Asgardians believe Loki to be dead. We thought it was funny that Loki was putting on a show for himself in an amphitheater to his own image. And we had the idea for a Hemsworth, not Chris, to play Thor in it and that’s Luke Hemsworth. Taika said he was gonna have Sam Neill come in and play Odin. And we were trying to think of who could come in and play Loki. And at one point Hemsworth said, what about my mate, Matt? We said, who’s your mate, Matt? He goes Matt Damon. Okay. Yeah, sure, call your friend Matt Damon. See if he wants to play Loki in a play. And next thing you know, Matt Damon’s on set wearing a Loki costume and shooting it. He just flew down. I think he was in New York and he flew down to Atlanta. Because of his friendship with Hemsworth. It was amazing.
Thor: Raganarok has a November 3, 2017 release directed by Taika Waititi starring Chris Hemsworth as Thor, Mark Ruffalo as Hulk/Banner, Tom Hiddleston as Loki, Idris Elba as Heimdall, Cate Blanchett as Hela, Tessa Thompson as Valkyrie, Jeff Goldblum as Grandmaster, Anthony Hopkins as Odin and Sam Neill in an unknown role.
Thor's world is about to explode in Marvel's Thor: Ragnarok. His devious brother, Loki, has taken over Asgard, the powerful Hela has emerged to steal the throne for herself and Thor is imprisoned on the other side of the universe. To escape captivity and save his home from imminent destruction, Thor must first win a deadly alien contest by defeating his former ally and fellow Avengers... The Incredible Hulk!