The European champions' bid to sign the player looked to have failed last week when it was announced the clubs could not agree a fee.

But both teams confirmed a deal had eventually been struck via their official websites on Tuesday evening.

Emerson arrived at the Bernabeu in summer 2006 from Juventus and helped the capital side win the Primera Liga last season before deciding on a quick return to Serie A.