Working the cap numbers, it seems the most we can take back is $6,025,363. This is a cap on Lopez's salary if he is all we take back. This makes is highly likely that the original reports of Warrick coming here are either wrong or indicative of a very favorable deal for Lopez. I think the former.
We could also sign him to a mini-Collison kind of deal to sweeten things for him, using cap space to give a signing bonus and keep his cap number low.
I haven't looked at the Suns' salary situation yet, but they have his bird rights, so they can sign him to any sized deal they like, but their situation could mess with a signing-bonus kind of deal.