I want to show that if the Frobenius-endomorphism (FE) $\phi:K\rightarrow K, x\mapsto x^p$ is surjective, then $K$ (with characteristic $p>0$) is a perfect field (meaning every irreducible polynomial is separable over $K$)
My attempt
Because the FE is surjective $\Rightarrow $ $\forall a\in K \exists b\in K: b^p = a$. Let's look at an irreducible polynomial $P\in K[X]$. Assume that $\alpha_1\in K$ is a root of $P$ which is also it's minimal polynomial.
Then I can display $\alpha_2 = \alpha_1^p$, $\alpha_3 = \alpha_2^p=\alpha_1^{p^2}$ and so on until I get $\alpha_{p}=\alpha_1^{p^p}$, right? Since FE is bijective (it's injective too) all these elements must be distinct.
So I think I just need to show that they're all roots of $P$, so we can say that $K$ is separable.
How can I do that? And if my attempt is not correct, how can I prove this?
Let $f(x)$ be an irreducible polynomial. We know that $\gcd(f,f')\neq 1$ only if $f'=0$, which would mean that $f(x)$ is a polynomial in $x^p$; that is, $$f(x) = a_nx^{p^n} + a_{n-1}x^{p^{n-1}}+\cdots+a_1x^p + a_0.$$ So it suffices to show that no polynomial in $x^p$ is irreducible over $K$.
So let $f(x) = a_nx^{p^n}+\cdots + a_1x^p + a_0$ be a polynomial in $x^p$ with coefficients in $K$.
Since the Frobenius endomorphism is surjective, for each $k=0,\ldots,n$ there exists $b_k\in K$ such that $b_k^p=a_k$. So we can write $$\begin{align*} f(x) &= a_nx^{p^n}+\cdots + a_1x^p + a_0\\ &= b_n^px^{p^n}+\cdots + b_1^px^p + b_0^p\\ &= (b_nx^{p^{n-1}})^p+(b_{n-1}x^{p^{n-2}})^p+\cdots + (b_1x)^p + b_0^p\\ &= (b_nx^{p^{n-1}} + \cdots + b_1x + b_0)^p. \end{align*}$$ Thus, $f(x)$ is not irreducible, as desired.
Therefore, if $f$ is irreducible, then $\gcd(f,f')=1$, which means $f$ does not have multiple roots; i.e., $f$ is separable over $K$.