Answer
The solution is
$$f(x)=3x-2.$$
Work Step by Step
On the right side we have a polynomial of the second degree. On the left we have $(f(x))^2$. Since this has to be a polynomial of 2nd degree we have to demand that $f$ is a first degree polynomial function i.e. it is of the form of $f(x)=ax+b$. Now lets determine $a$ and $b$.
$$(f(x))^2=(ax+b)^2=(ax)^2+2abx+b^2=a^2x^2+2abx+b^2=9x^2-12x+4.$$
Equating the coefficinets multiplyng same powers of $x$ we get
$$a^2=9\Rightarrow a=3;$$
$$2ab=-12\Rightarrow2\cdot3b=-12\Rightarrow b=-2;$$
The last equation $$b^2=4$$
is now used just for checking and indeed $2^2=4$.
Finally, $$f(x)=3x-2.$$