Generalized Ginzburg-Landau equation for self-pulsing instability in a two-photon laser