Efficient activation of Mg acceptors for obtaining a high hole concentration is a challenging topic. In this paper, we report the results of Mg acceptor activation in GaN with irradiation of the second-harmonic photons (532 nm in wavelength) of a Q-switch