Portugal defender Pepe and Brazil midfielder FelipeMelo were both booked during a running battle, which resulted in the latter being substituted just before half-time.
Goals from FelipeMelo, Robinho and Maicon secured the three points for Dunga's side -- who will definitely reach the semifinals should they draw with Italy in their final Group B encounter.