Nine-times winners Real Madrid will have to face seven-times champions AC Milan in Group C, meaning an early return to the San Siro for Brazilian playmaker Kaka.
However, the win still lifted Madrid to the top of Group C and they are now two points clear of AC Milan and three clear of Marseille, who Manuel Pellegrini's side play in their final match.