Influence of microstructure on the carrier concentration of Mg-doped GaN films