Let $p\equiv 8 \mod 9$ be a prime, I find the following equation:

$$2\sum_{\substack{0<x<p\\ 2|x}}\sum_{r|p^2-x^2}\left(\frac{-3}{r}\right)=p+1.$$
where $\left(\frac{-3}{r}\right)$ is the Kronecker symbol.
I checked it for many $p$ using computer. Does anyone have ideal how to prove it?