Unified work function.