マルチ・チャネル DMA PCI Express* 用インテル FPGA IP ユーザー・ガイド

ID 683821
日付 10/06/2023
Public

このドキュメントの新しいバージョンが利用できます。お客様は次のことを行ってください。 こちらをクリック 最新バージョンに移行する。

ドキュメント目次

3.1.2. 書き込みデータムーバー

D2H Data Mover (D2HDM) は、デバイス メモリからホスト メモリにデータを転送します。 Avalon-MM Read Master / Avalon-ST Sink インターフェイスを介してユーザーロジックからデータを受信し、PCIe アドレス (宛先)、データサイズ、MPS などの記述子情報に基づいてデータをホストに移動するための Mem Wr TLP を生成します。 ホスト メモリ内の受信バッファにデータを送信するための値。

AVMM モードでは、D2HDM は、PCIe アドレス、MPS、および DMA 転送サイズに基づいて、マスター ポート経由で一連の AVMM 読み取りを送信します。 AVMM 読み取りは次のように生成されます。
  • 最初の AVMM は 64 バイトのアドレス境界まで読み取られます。 次の場合、最初の AVMM 読み取り時に複数のバーストが読み取られます。
    • AVMM アドレスは 64 バイトでアラインされています。
    • 記述子の合計ペイロード数は 64 バイトでアライメントされており、サポートされている最大 MPS 未満です。
  • サポートされている最大 MPS サイズでの AVMM 読み取りが続きます。
  • 残りのサイズの最後の AVMM 読み取り。
AVST モードでは、記述子が利用できない場合、D2HDM AVST シンクは準備完了のアサートを解除します。
  • ホストはポートのソフトウェア記述子を設定します。 最大ペイロード数は最大 1MB です。 記述子の SOF/EOF フィールドはホストによって設定されない場合があります。
    • D2HDM は、記述子更新シーケンスを使用して、メモリ書き込み要求を通じてホストの場所にあるソフトウェア記述子の SOF、EOF、Rx ペイロード カウント フィールドを更新します。
  • AVST d2h_st_sof_i signal assertion triggers a descriptor update sequence by D2HDM to mark start of AVST frame.
    • D2HDM issues a MWr to set the SOF field in the descriptor
    • WB/MSI-X, if set in the descriptor, is issued
  • AVST d2h_st_eof_i signal assertion triggers a descriptor update sequence by D2HDM to mark end of AVST frame. The descriptor update sequence is as follows:
    • D2HDM terminates the descriptor at d2h_st_eof_i and initiates a descriptor update sequence.
    • During descriptor update sequence, a MWr is issued to set EOF field in the descriptor and update Rx payload count field with total bytes transferred.
    • WB/MSI-X if set in descriptor, is issued
  • The descriptor immediately after EOF sequence, is considered as start of next AVST data frame and initiates a descriptor update sequence to set SOF field.
When a descriptor is completed, that is, all DMA data corresponding to the descriptor has been sent to the host, the D2HDM performs housekeeping tasks that include:
  • Schedule MSI-X for a completed queue, if enabled in the descriptor
  • Schedule Writeback Consumed Head Pointer for a completed queue, if enabled in the descriptor
  • Update Consume Head Pointer for software polling
  • MSI-X and Writeback are memory write to host via the D2HDM to avoid race condition due to out-of-order writes.

Based on the updated status, software can proceed with releasing the receive buffer and reuse the descriptor ring entries.