Don't electrons have discrete energy levels in semiconductors?

I am having a hard time understanding the relation between the fermi distribution of electrons in a semiconductor, and the fact the electron energy states are discrete.

The fermi distribution is supposed to give us the probability of an energy level being occupied by electrons. It looks like this:

yet electrons are supposed to have discrete energy states, and no electron is supposed to be in the band gap:

I must be missing something here, how is it that electrons have a fairly high probability of being in the band gap ?

If the Fermi level lies in the band gap, the undoped semiconductor behaves like an insulator because all electronic states in the valence band are occupied and the electrons can't move. If $E_\mathrm{F}$ was smaller than the highest energy level in the valence band, the material would become conductive because free states in the valence band become available. If $E_\mathrm{F}$ was larger than the lowest energy level in the conduction band, the material would also become conductive for the same reason.