data_offload: Flush the DMA if the transaction size is bigger than the storage

main
Istvan Csomortani 2021-03-24 08:19:57 +00:00 committed by Mihaita Nagy
parent 564ef77588
commit 9b1108ea87
1 changed files with 5 additions and 2 deletions

View File

@ -254,9 +254,12 @@ module data_offload_fsm #(
end end
end end
// flush out the DMA if the transfer is bigger than the storage size
assign wr_ready = ((wr_fsm_state == WR_WRITE_TO_MEM) ||
((wr_fsm_state == WR_WAIT_TO_END) && wr_valid_in)) ? 1'b1 : 1'b0;
// write control // write control
assign wr_ready = (wr_fsm_state != WR_WRITE_TO_MEM) ? 1'b0 : 1'b1; assign wr_valid_out = (wr_fsm_state == WR_WRITE_TO_MEM) & wr_valid_in;
assign wr_valid_out = wr_ready & wr_valid_in;
// sample counter for debug purposes, the value of the counter resets at // sample counter for debug purposes, the value of the counter resets at
// every new incoming request // every new incoming request