Let $R$ be a prime ring of characteristic different from $2$ with the center $Z(R)$ and $F$, $G$ be $b$-generalized skew derivations on $R$. Let $U$ be Utumi quotient ring of $R$ with the extended centroid $C$ and $f(x_1,\ldots,x_n)$ be a multilinear polynomial over $C$ which is not central valued on $R$. Suppose that $P\notin Z(R)$ such that $$\big[P,[F(f(r)),f(r)]\big]=[G(f(r)), f(r)],$$ for all $r=(r_1,\ldots,r_n)\in R^n$, then one of the following holds: \begin{itemize} em [(1)] there exist $\lambda,µ\in C$ such that $F(x)=\lambda x$, $G(x)=µx$ for all $x\in R$; em [(2)] there exist $a,b \in U$, $\lambda,µ\in C$ such that $F(x)=ax+\lambda x+xa$, $G(x)=bx+µx+xb$ for all $x\in R$ and $f(x_1,\ldots,x_n)^2$ is central valued on $R$. \end{itemize}