Contrary to 1e, in 5e you can prepare a spell once and cast it any number of times. I think this is proof enough that the spell is well imprinted in your brain.
Falling unconscious does not really mean that your brain was hurt. Of course, that could happen and the DM could decide that it happened (actually some monsters specifically attack your brain..)
In 5e, it will be much more likely for you to lose your spellbook than a spell in your brain. Actually, Out of the Abyss starts that way... all your belongings get taken. That's quite a hit for a wizard. On the other hand, the spell you still have in your head stays there until you get your spellbook back or a get a new spellbook at some point.
What can also cause problems is losing your focus. It won't prevent you from casting the spell, just that you will need to find material components if the spell requires such. Without a focus or those material components, the spell won't work.