I think the solution is simply
$$P=G_1 G_2 A^{-1}(1 +\lambda ).$$
Let me check by substitution
$$G_1G_2P^\top(PAP^\top)^{-1}P=G_1 G_2(G_1G_2A^{-1})^\top\bigl(G_1G_2(G_1G_2A^{-1})^\top\bigr)^{-1}G_1G_2A^{-1}=G_1G_2A^{-1},$$
so yes, it solves
$$P - G_1G_2(\lambda P^\top(PAP^\top)^{-1}P + A^{-1} ) = 0.$$