cleanup and fifo scheduling