Update, May 19: Now that the Game of Thrones finale has aired and Jon Snow’s actual fate has been revealed, the Lord of the Rings parallels laid out below seem even clearer!

Now that the Battle of Winterfell has been fought and won, a number of Game of Thrones fans are left wondering what, exactly, is the endgame for this huge, mythologically rich saga. A recent swing of anti-Daenerys sentiment throughout the seven kingdoms might indicate where we’re headed with the Targaryen queen, but what of her nephew/lover, Jon Snow? Between his fancy sword and his secret birthright, Jon has all the hallmarks of a classic hero but is that really where A Song of Ice and Fire author George R.R. Martin—who has said the show will follow his planned ending—is taking this story?

Doubtful. In fact, we might have already learned exactly what’s in store for Jon during last Sunday’s episode “The Last of the Starks.” It wouldn’t exactly be a happy ending, but it would be very good news for fans worried that the direwolf Ghost got left out in the cold this week. What follows is a lot of speculation based on hints from the show, the books, and Martin’s own words.

First it’s useful to consider what Martin himself has said on the record about how his saga will end. He’s repeatedly deployed the word “bittersweet” to describe the tone of his final chapter, but went even further during a 2015 interview with The Observer. First of all he promised the ending would not be some dire apocalyptic the-Night-King-wins-and-everyone-dies scenario. We now know that to be true. Then Martin cited the story that his saga has been in conversation with from the beginning: “It’s no secret that J.R.R. Tolkien has been a huge influence on me and I love the way he ended Lord of the Rings.”

That ending, if you don’t recall, sees the heroes triumphant over the dark lord Sauron and the ring of power melted into oblivion thanks, in large part, to Gollum and his grasping desire for it. (More on that in a bit.) The wise and good hero Aragorn takes the throne and the valiant, gentle hobbits return to the Shire. But that’s not exactly where Tolkien, who was writing as much about his own experience during World War I as he was elves and wizards, ended it. There’s a section of the story that director Peter Jackson omitted from his film trilogy called the Scouring of the Shire, where the hobbits return home from battling Sauron to find their idyllic home ripped apart by the wizard Saruman who, having lost the war, was determined to make their homecoming a hell on Middle Earth.

Tolkien’s take on the post-war experience might have been too dark for Jackson but Martin is a fan: “The scouring of the Shire—brilliant piece of work, which I didn’t understand when I was 13 years old: ‘Why is this here? The story’s over?’ But every time I read it I understand the brilliance of that segment more and more. All I can say is that’s the kind of tone I will be aiming for.”

So with the great battle with the Night King over, there’s no doubt that Game of Thrones is in its own Scouring of the Shire now. Or, as Tyrion put it last Sunday: