  Let $A$ be an Artin algebra, $M$ be a Gorenstein projective $A$-module and $B
=$ End$_A M$, then $M$ is a $A$-$B$-bimodule. We use the restricted flat
dimension of $M_B$ to give a characterization of the homological dimensions of
$A$ and $B$, and obtain the following main results: (1) if $A$ is a CM-finite
algebra with $\cal GP$($A$) = add$_AE$ and fin.dim $A \geq 2,$ then ${\rm
fin.dim}\ B \leq {\rm fin.dim}\ A + {\rm rfd}(M_B) +{\rm pd}_B{\rm Hom}_A(M,
E);$ (2) If $A$ is a CM-finite $n$-Gorenstein algebra with $\cal GP$($A$) =
add$_AE$ and $n \geq 2$, then gl.dim $B \leq n + {\rm pd}_B{\rm Hom}_A(M, E).$
