[PATCH PM-QA] functions: correct get_os logic