In a photoluminescence and surface photovoltage study of porous silicon films with crystallite dimensions assessed with the Atomic Force Microscope, we have found cases when the blue shifts of the luminescence spectrum and the optical absorption edge take place upon increasing crystallite dimensions, which is contrary to quantum size effects. Fourier transform infrared spectroscopy analysis of these samples shows significant differences in hydrogen and oxygen bonding, which imply that the origin of the luminescence is of chemical nature. Our results show that porous silicon luminescence is not a consequence of one mechanism, but rather results from several mechanisms with contributions depending on the chemistry and structure of porous silicon.