I did a google on tpo surgery and there seem to be lots of positive stories about it out there.
As they recommend the surgery only for dogs under 1 year and your dog is in such obvious pain, I do think you are doing the right thing. It is hard with dogs when you cannot prepare them for it. But I'm sure he'll be fine!
I wish you lots of courage for dealing with the op and the recovery.