68 #define THIS_NAME "TOE/RSt"
70 #define TRACE_OFF 0x0000
71 #define TRACE_RST 1 << 1
72 #define TRACE_ALL 0xFFFF
74 #define DEBUG_LEVEL (TRACE_OFF)
106 stream<RXeRxSarQuery> &siRXe_RxSarQry,
107 stream<RxSarReply> &soRXe_RxSarRep,
108 stream<RAiRxSarQuery> &siRAi_RxSarQry,
109 stream<RAiRxSarReply> &soRAi_RxSarRep,
110 stream<SessionId> &siTXe_RxSarReq,
111 stream<RxSarReply> &soTxe_RxSarRep)
114 #pragma HLS PIPELINE II=1 enable_flush
119 static RxSarEntry RX_SAR_TABLE[TOE_MAX_SESSIONS];
120 #pragma HLS RESOURCE variable=RX_SAR_TABLE core=RAM_2P
121 #pragma HLS DEPENDENCE variable=RX_SAR_TABLE inter false
123 if(!siTXe_RxSarReq.empty()) {
128 siTXe_RxSarReq.read(sessId);
129 soTxe_RxSarRep.write(
RxSarReply(RX_SAR_TABLE[sessId].appd,
130 RX_SAR_TABLE[sessId].rcvd,
131 RX_SAR_TABLE[sessId].ooo,
132 RX_SAR_TABLE[sessId].oooHead,
133 RX_SAR_TABLE[sessId].oooTail));
136 (
RxBufPtr)RX_SAR_TABLE[sessId].oooHead(TOE_WINDOW_BITS-1, 0)) - 1);
137 printInfo(myName,
"[TXe] Read S%d - FreeSpace=%d\n",
138 sessId.to_uint(), free_space.to_uint());
141 else if(!siRAi_RxSarQry.empty()) {
146 siRAi_RxSarQry.read(raiQry);
152 printInfo(myName,
"[RAi] Write S%d - FreeSpace=%d\n",
153 raiQry.
sessionID.to_uint(), free_space.to_uint());
162 printInfo(myName,
"[RAi] Read S%d - FreeSpace=%d\n",
163 raiQry.
sessionID.to_uint(), free_space.to_uint());
167 else if(!siRXe_RxSarQry.empty()) {
190 printInfo(myName,
"[RXe] Write S%d - FreeSpace=%d\n",
191 rxeQry.
sessionID.to_uint(), free_space.to_uint());
204 printInfo(myName,
"[RXe] Read S%d - FreeSpace=%d\n",
205 rxeQry.
sessionID.to_uint(), free_space.to_uint());
void rx_sar_table(stream< RXeRxSarQuery > &siRXe_RxSarQry, stream< RxSarReply > &soRXe_RxSarRep, stream< RAiRxSarQuery > &siRAi_RxSarQry, stream< RAiRxSarReply > &soRAi_RxSarRep, stream< SessionId > &siTXe_RxSarReq, stream< RxSarReply > &soTxe_RxSarRep)
Rx SAR Table (RSt)
#define printInfo(callerName, format,...)
A macro to print an information message.
: Rx Segmentation And Re-assembly Table (RSt).