Impact of Valence States on Superconductivity of Oxygen Incorporated Iron Telluride and Iron Selenide Films