FIG. 7 is a graph illustrating how the quantity of holes trapped in the surface region of a tunnel insulating film, which is formed by patterning a silicon oxynitride film according to the third embodiment, changes with a nitrogen diffusion temperature.