To me, the idea that Link warns Zelda about Ganondorf when after returning to the past is so flawed, I cringe every time I read it. Zelda already had a premonition about Ganondorf, warned her father, and he didn't believe her. So her going to her father again after being told by Link what she already knew, doesn't make a lick of sense. In addition, Link clearly returned to the exact point when he drew the Master Sword (the Door of Time is open and the three Spiritial Stones are present), which happened AFTER Ganondorf attacked and Impa ran off with Zelda. Not to mention, that there would be two Links present at once if he were sent back earlier. The scene at the end of the credits was simply replaying the moment where Link meets Zelda for the first time, it wasn't showing new events. I understand how easy it is to misinterpret that scene, but the other facts clearly make that the only valid interpretation. So when Link returns the Master Sword to the pedistal (which closes the seal), Ganondorf is already in the Sacred Realm, thus creating the history for A Link to the Past where Ganon has the full Triforce but is unable to return to the Light World.