use a single mutex for scheduling