The following is a theorem of Elkik from 1978 describing how rational singularities behave under flat morphisms.

Let $f:X\rightarrow S$ be a flat morphism of schemes of finite type over $\mathbb{C}$ such that both $S$ and the fibres of $f$ have rational singularities.

I am confused about one step in the proof and I am afraid that it should be obvious.

Let $\varphi:S'\rightarrow S$ be a resolution of singularities and let $X'=X\times_S S'$ be the fiber product, with projections $\varphi'$ and $f'$ to $X$ and $S'$ respectively. Also, let $\psi:Y\rightarrow X'$ be a resolution of singularities.

$$\begin{array}{ccccc} Y & \stackrel{\psi}{\longrightarrow} & X'=X\times_S S' & \stackrel{\varphi'}{\longrightarrow} & X \\ & & \downarrow & & \downarrow \\ & & S' & \stackrel{\varphi}{\longrightarrow} & S \end{array} f$$

By assumption, we have that $R^{\bullet}\psi\mathcal{O}_Y=\mathcal{O}_{X'}$ and $R^{\bullet}\varphi\mathcal{O}_{S'}=\mathcal{O}_S$. I am trying to show that then $X$ also has rational singularities, namely $R^{\bullet}(\varphi'\circ \psi)\mathcal{O}_Y=\mathcal{O}_X$.

By Grothendieck spectral sequence, since $X'$ has rational singularities, we have that $R^i(\varphi'\circ \psi)\mathcal{O}_Y = R^i\varphi'\mathcal{O}_{X'}$ so we have to show that $R^{\bullet}\varphi'\mathcal{O}_{X'}=\mathcal{O}_X$.

I am not sure about how this follows: by flat base change the natural map $$f^{\ast}R^i\varphi_{\ast}\mathcal{O}_{S'}\rightarrow R^i\varphi'f'^{\ast}\mathcal{O}_{S'}$$ is an isomorphism.

Now for instance for $i=0$ flat base change yields $\varphi_{\ast}'f'^{\ast}\mathcal{O}_{S'}=f^{\ast}\mathcal{O}_S$. Pushing forward by $f$ on both sides yields $$f_{\ast}\varphi'_{\ast}f'^{\ast}\mathcal{O}_{S'}=f_{\ast}f^{\ast}\mathcal{O}_S=\mathcal{O}_S\otimes f_{\ast}\mathcal{O}_X=f_{\ast}\mathcal{O}_X$$

Commutativity on the LHS yields $$f_{\ast}\varphi'_{\ast}f'^{\ast}\mathcal{O}_{S'}=\varphi_{\ast}f'_{\ast}f'^{\ast}\mathcal{O}_{S'}=\varphi_{\ast}(\mathcal{O}_{S'}\otimes f'_{\ast}\mathcal{O}_{S'})=\varphi_{\ast}f'_{\ast}\mathcal{O}_{X'}$$

So $f_{\ast}\varphi'_{\ast}\mathcal{O}_{X'}=f_{\ast}\mathcal{O}_X$.

Does it follow that $\varphi'_{\ast}\mathcal{O}_{X'}=\mathcal{O}_X$? Am I making this more complicated than it actually is?

**Added**: For instance, if $f$ is injective, the claim would follow, since then $f_{\ast}\mathcal{F}\simeq f_{\ast}\mathcal{G} \Longrightarrow \mathcal{F}\simeq \mathcal{G}$. (by definition $\mathcal{F}(f^{-1}(U))\simeq \mathcal{G}(f^{-1}(U))$ for every $U\subseteq Y$ open and provided that $f$ is flat and injective, for any open set $V\subseteq X$, we have $V=f^{-1}(f(V))$ (since flat morphisms of finite type between Noetherian schemes are open). But this is more than we need.