The Portuguese forward came on as a substitute in the second half on Sunday and restored Real's first-leg lead with a ferocious strike from range 10 minutes from time.
However, he was sent off two minutes later after picking up a second yellow card for diving after going down under pressure from Samuel Umtiti, and then pushed referee Ricardo de Burgos Bengoetxea after being shown the red card.
Gerard Pique's own goal had put Real ahead after a low-key first half, but in a frantic finish Lionel Messi equalised from the spot before Ronaldo struck, with Marco Asensio grabbing a last-minute third for the 10 men.
Real head coach Zidane told Sky Sports News after the game: "I'm annoyed that Cristiano Ronaldo was sent off, it might not have been a penalty, but still, giving him a card is ludicrous.
"Let's see if we can make arrangements for him to be available on Wednesday [the second leg]. I am truly proud of my players, they played well as 10 and really wanted the win. Now we turn our attentions to the return leg and we need to relax".
Los Blancos host Barca at the Bernabeu in Wednesday's second leg at 10pm BST.