This work investigates a double layer stack system that can be used for surface passivation of crystalline silicon. The stack consists of amorphous silicon-rich silicon oxynitride and amorphous silicon nitride on top. Both layers are fabricated by means of plasma-enhanced chemical vapour deposition. We investigate the stack in terms of changes in the hydrogen content and distribution within the different stack layers due to a high temperature treatment. For that purpose the stack is studied by Fourier-transformed infrared spectroscopy and nuclear reaction analysis before and after fast firing at 850 °C. Our results determine the bottom silicon oxynitride layer as very hydrogen-rich. Furthermore, we identify the silicon nitride capping layer as diffusion barrier to atomic hydrogen but still allowing an effusion of molecular hydrogen. We present a qualitative model that explains our findings and distinguishes between atomic and molecular hydrogen.