CMD_FLUSH aborts (calls AbortIO() ) all CMD_WRITE and all ADCMD_WAITCYCLEs that are queued up for the channel or channels. It does not abort ADCMD_LOCKs (only ADCMD_FREE clears locks).