If you use g.711, that's basically the same codec used when your calls pass over a T1 or other digital phone service. Which should be fine.
You're adding latency though, because g.711 over RTP is generally sending 20 ms bursts of data, so now you've got that to deal with.
I don't know if the cisco ata's short circuit the audio path if both ends of the call are on the same gateway, if so that would eliminate or significantly reduce the latency penalty.