Self-catalytic etching of silicon: from nanowires to regular mesopores