Write the workstatus in critical sections and flush before all
workstatus reads