I haven't seen any of them in ages, but here is what I can remember about what happens.
The Matrix has a flaw because human will and potential cannot be bottled up like that. Eventually enough of the system will go off the rails to let resistances like Zion come about, so Neo is actually a cog of the Matrix to facilitate an easy transition of these resistances.
Like the Architect said, Neo isn't the first Neo, and it's gotten easier to do this thing every time the system closes another loop. Revolutions focuses on Neo finding a third option to chaos of human extinction vs. the machines giving humanity false hope through figurehead messiahs like himself so that the system can continue.