Everton manager Roberto Martinez felt the referee was right to send off Diego Costa and Gareth Barry in their FA Cup win over Chelsea.