Lines Matching refs:rcd

135 fbnic_rx_csum(u64 rcd, struct sk_buff *skb, struct fbnic_ring *rcq)  in fbnic_rx_csum()  argument
142 if (FIELD_GET(FBNIC_RCD_META_L4_CSUM_UNNECESSARY, rcd)) { in fbnic_rx_csum()
145 u16 csum = FIELD_GET(FBNIC_RCD_META_L2_CSUM_MASK, rcd); in fbnic_rx_csum()
574 static void fbnic_pkt_prepare(struct fbnic_napi_vector *nv, u64 rcd, in fbnic_pkt_prepare() argument
578 unsigned int hdr_pg_idx = FIELD_GET(FBNIC_RCD_AL_BUFF_PAGE_MASK, rcd); in fbnic_pkt_prepare()
579 unsigned int hdr_pg_off = FIELD_GET(FBNIC_RCD_AL_BUFF_OFF_MASK, rcd); in fbnic_pkt_prepare()
581 unsigned int len = FIELD_GET(FBNIC_RCD_AL_BUFF_LEN_MASK, rcd); in fbnic_pkt_prepare()
589 hdr_pg_end = FIELD_GET(FBNIC_RCD_AL_PAGE_FIN, rcd) ? in fbnic_pkt_prepare()
596 hdr_pg_start += (FBNIC_RCD_AL_BUFF_FRAG_MASK & rcd) * in fbnic_pkt_prepare()
615 static void fbnic_add_rx_frag(struct fbnic_napi_vector *nv, u64 rcd, in fbnic_add_rx_frag() argument
619 unsigned int pg_idx = FIELD_GET(FBNIC_RCD_AL_BUFF_PAGE_MASK, rcd); in fbnic_add_rx_frag()
620 unsigned int pg_off = FIELD_GET(FBNIC_RCD_AL_BUFF_OFF_MASK, rcd); in fbnic_add_rx_frag()
621 unsigned int len = FIELD_GET(FBNIC_RCD_AL_BUFF_LEN_MASK, rcd); in fbnic_add_rx_frag()
626 truesize = FIELD_GET(FBNIC_RCD_AL_PAGE_FIN, rcd) ? in fbnic_add_rx_frag()
629 pg_off += (FBNIC_RCD_AL_BUFF_FRAG_MASK & rcd) * in fbnic_add_rx_frag()
713 static enum pkt_hash_types fbnic_skb_hash_type(u64 rcd) in fbnic_skb_hash_type() argument
715 return (FBNIC_RCD_META_L4_TYPE_MASK & rcd) ? PKT_HASH_TYPE_L4 : in fbnic_skb_hash_type()
716 (FBNIC_RCD_META_L3_TYPE_MASK & rcd) ? PKT_HASH_TYPE_L3 : in fbnic_skb_hash_type()
721 u64 rcd, struct sk_buff *skb, in fbnic_populate_skb_fields() argument
727 fbnic_rx_csum(rcd, skb, rcq); in fbnic_populate_skb_fields()
731 FIELD_GET(FBNIC_RCD_META_RSS_HASH_MASK, rcd), in fbnic_populate_skb_fields()
732 fbnic_skb_hash_type(rcd)); in fbnic_populate_skb_fields()
737 static bool fbnic_rcd_metadata_err(u64 rcd) in fbnic_rcd_metadata_err() argument
739 return !!(FBNIC_RCD_META_UNCORRECTABLE_ERR_MASK & rcd); in fbnic_rcd_metadata_err()
759 u64 rcd; in fbnic_clean_rcq() local
766 rcd = le64_to_cpu(*raw_rcd); in fbnic_clean_rcq()
768 switch (FIELD_GET(FBNIC_RCD_TYPE_MASK, rcd)) { in fbnic_clean_rcq()
770 head0 = FIELD_GET(FBNIC_RCD_AL_BUFF_PAGE_MASK, rcd); in fbnic_clean_rcq()
771 fbnic_pkt_prepare(nv, rcd, pkt, qt); in fbnic_clean_rcq()
775 head1 = FIELD_GET(FBNIC_RCD_AL_BUFF_PAGE_MASK, rcd); in fbnic_clean_rcq()
776 fbnic_add_rx_frag(nv, rcd, pkt, qt); in fbnic_clean_rcq()
781 if (FIELD_GET(FBNIC_RCD_OPT_META_TYPE_MASK, rcd)) in fbnic_clean_rcq()
787 if (likely(!fbnic_rcd_metadata_err(rcd))) in fbnic_clean_rcq()
792 fbnic_populate_skb_fields(nv, rcd, skb, qt); in fbnic_clean_rcq()