-static inline _buffer *get_rxbuf_desc(union recv_frame *precvframe)
-{
- _buffer *buf_desc;
- if (precvframe == NULL)
- return NULL;
- return buf_desc;
-}
-
-static inline union recv_frame *rxmem_to_recvframe(u8 *rxmem)
-{
- /* due to the design of 2048 bytes alignment of recv_frame, we can
- * reference the union recv_frame from any given member of recv_frame.
- * rxmem indicates the any member/address in recv_frame */
- return (union recv_frame *)(((addr_t)rxmem >> RXFRAME_ALIGN) <<
- RXFRAME_ALIGN);
-}
-
-static inline union recv_frame *pkt_to_recvframe(_pkt *pkt)
-{
- u8 *buf_star;
- union recv_frame *precv_frame;
-
- precv_frame = rxmem_to_recvframe((unsigned char *)buf_star);
- return precv_frame;
-}
-
-static inline u8 *pkt_to_recvmem(_pkt *pkt)
-{
- /* return the rx_head */
- union recv_frame *precv_frame = pkt_to_recvframe(pkt);
-
- return precv_frame->u.hdr.rx_head;
-}
-
-static inline u8 *pkt_to_recvdata(_pkt *pkt)
-{
- /* return the rx_data */
- union recv_frame *precv_frame = pkt_to_recvframe(pkt);
-
- return precv_frame->u.hdr.rx_data;
-}
-
-static inline sint get_recvframe_len(union recv_frame *precvframe)
-{
- return precvframe->u.hdr.len;
-}
-