Magnesium-doped zinc oxide nanorod–nanotube semiconductor/p-silicon heterojunction diodes