Cancellation

Versal ACAP Technical Reference Manual (AM011)

Document ID
AM011
Release Date
2022-04-26
Revision
1.4 English

Each [CRnn] bit of the TX Buffer Cancel Request ( Tx_Buff_Cancel_Req ) register corresponds to a message element in the TX buffer (and, consequently, corresponds to a TxBuff_Ready_Req [RRnn] bit).

Software Actions

  1. Poll the TxBuff_Ready_Req register (TRR) to check current pending transmission requests.
  2. Poll the Tx_Buff_Cancel_Req register (TCR) to check current pending cancellation requests.
    1. Transmit cancellation for a buffer (TXB_i) can be requested only if there is a corresponding pending transmission request set in the TRR register.
    2. If there is already a pending cancellation request for TXB_i, no action is required and the host should wait (by poll/interrupt) until the core serves a cancellation request for TXB_i.
  3. If the TXB_i buffer has a pending transmission request but no pending cancellation request, then transmit cancellation can be requested as follows:
    1. Enable interrupt generation as required.
    2. Set the required TCR [CRnn] bit(s). The software can request the cancellation of multiple buffers with one write to the TCR register.
    3. Wait for the interrupt or poll the TCR register to determine the cancellation status.
  4. The controller clears the bit in the TCR register when the respective buffer transmit cancellation request is completed.
  5. The controller also clears the corresponding bit in the TRR register when cancellation is performed.

Controller Actions

  1. The controller performs the cancellation of a buffer immediately except:
    1. When the buffer is locked by the transfer layer for transmission on the CAN bus. In this case, cancellation is performed at the end of the transmission irrespective of whether the transmission is successful or not (arbitration loss or error).
    2. When the core is performing a scheduling round to find out the next buffer for transmission. In this case, cancellation is performed after the scheduling round is finished.
  2. The controller clears the respective bits in the Tx_Buff_Cancel_Req and TxBuff_Ready_Req registers when cancellation is done.
  3. If enabled through the TxBuff_Ready_Req_Intr_En (IETRS) or APB_MISC_IER (IER) registers, then the APB_MISC_ISR [TXRRS] bit is set = 1 (when the controller clears the bit in the Tx_Buff_Cancel_Req register) and an interrupt is generated.