Find all polynomials $P(x) \in \mathbb R[x]$ such that $P(x)^2=4P\left(x^2-5x+1\right)+2$.
This comes from a no-solution class problem so it should have a definitive solution, unless my teacher wrongly wrote it as it is now.
Approach
This is like solving a functional equation, but only that it's a polynomial. I first thought I would solve for $x=x^2-5x+1$ or $x^2-6x+1=0$ which yields $x_1=3+2\sqrt2$ or $x_2=3-2\sqrt2$.
Which yields the value for $P(x_1)$ and $P(x_2)$. But then I couldn't proceed.
If $d>0$ and $ax^d$ is the leading term of $P(x)$, then $a^2x^{2d}=4ax^{2d}$, and thus $a=4$.
Another way I considered is using sequence to prove that there's infinitely many values of $P(x)=P(y)$ but that doesn't work either.
Any help is appreciated!