He still has one more regeneration after this. This will be #11. 12th Doctor, 11th regeneration.
I loathed Matt Smith, so I am very glad to see him go. As for what they will do when the Doctor runs out of regenerations — I wouldn't worry about it. The show's own continuity has already established that the Time Lords can bestow a new slate of regenerations upon someone if they so choose. So there are plenty of options. I have always suspected that they are going to say that since the Doctor is the last Time Lord left in this reality, he has effectively "inherited" the regenerations of his entire race, meaning that he has, effectively, an infinite number of regenerations. Or they could simply "refill" his twelve and start over.
I have always thought a cool way to end the series, when that day eventually comes, would be to have the Doctor regenerate into a younger version of his first incarnation, revealing that his entire life is an infinite loop.