Let $L$ be a restricted Lie algebra over a field of characteristic $p>0$. It is well known that the commutator subalgebra $[L,L]$ is not necessarily restricted (that is, closed under the $p$-map).


Does there exist any such counterexample where the restricted Lie algebra comes from an associative algebra?


I recall that an associative algebra over a field of characteristic $p>0$ can be regarded as a restricted Lie algebra via the Lie bracket $[x,y]=xy-yx$ and $p$-map given by ordinary $p$-exponentation.



Derived subalgebra of a restricted Lie algebra
There is no such a counterexample, as the derived subalgebra of the restricted Lie algebra associated to an associative algebra over a field of positive characteristic is always restricted.


For instance, this follows from Lemma 4.5 in Chapter 2 of the book "D. Passmann: The algebraic structure of group rings" ([MathSciNet](https://mathscinet.ams.org/mathscinet/article?mr=0798076)).


