Lines Matching refs:rcd
161 typedef int (*intr_handler)(struct hfi1_ctxtdata *rcd, int data);
320 static inline u32 rcvhdrq_size(struct hfi1_ctxtdata *rcd) in rcvhdrq_size() argument
322 return PAGE_ALIGN(rcd->rcvhdrq_cnt * in rcvhdrq_size()
323 rcd->rcvhdrqentsize * sizeof(u32)); in rcvhdrq_size()
337 struct hfi1_ctxtdata *rcd; member
1309 struct hfi1_ctxtdata **rcd; member
1424 void handle_user_interrupt(struct hfi1_ctxtdata *rcd);
1426 int hfi1_create_rcvhdrq(struct hfi1_devdata *dd, struct hfi1_ctxtdata *rcd);
1427 int hfi1_setup_eagerbufs(struct hfi1_ctxtdata *rcd);
1430 struct hfi1_ctxtdata **rcd);
1431 void hfi1_free_ctxt(struct hfi1_ctxtdata *rcd);
1434 void hfi1_free_ctxtdata(struct hfi1_devdata *dd, struct hfi1_ctxtdata *rcd);
1435 int hfi1_rcd_put(struct hfi1_ctxtdata *rcd);
1436 int hfi1_rcd_get(struct hfi1_ctxtdata *rcd);
1440 int handle_receive_interrupt(struct hfi1_ctxtdata *rcd, int thread);
1441 int handle_receive_interrupt_nodma_rtail(struct hfi1_ctxtdata *rcd, int thread);
1442 int handle_receive_interrupt_dma_rtail(struct hfi1_ctxtdata *rcd, int thread);
1443 int handle_receive_interrupt_napi_fp(struct hfi1_ctxtdata *rcd, int budget);
1444 int handle_receive_interrupt_napi_sp(struct hfi1_ctxtdata *rcd, int budget);
1465 static inline u32 hfi1_rcd_head(struct hfi1_ctxtdata *rcd) in hfi1_rcd_head() argument
1467 return rcd->head; in hfi1_rcd_head()
1475 static inline void hfi1_set_rcd_head(struct hfi1_ctxtdata *rcd, u32 head) in hfi1_set_rcd_head() argument
1477 rcd->head = head; in hfi1_set_rcd_head()
1481 static inline __le32 *get_rhf_addr(struct hfi1_ctxtdata *rcd) in get_rhf_addr() argument
1483 return (__le32 *)rcd->rcvhdrq + rcd->head + rcd->rhf_offset; in get_rhf_addr()
1487 static inline bool get_dma_rtail_setting(struct hfi1_ctxtdata *rcd) in get_dma_rtail_setting() argument
1489 return !!HFI1_CAP_KGET_MASK(rcd->flags, DMA_RTAIL); in get_dma_rtail_setting()
1511 static inline u8 hfi1_seq_cnt(struct hfi1_ctxtdata *rcd) in hfi1_seq_cnt() argument
1513 return rcd->seq_cnt; in hfi1_seq_cnt()
1522 static inline void hfi1_set_seq_cnt(struct hfi1_ctxtdata *rcd, u8 cnt) in hfi1_set_seq_cnt() argument
1524 rcd->seq_cnt = cnt; in hfi1_set_seq_cnt()
1534 static inline bool last_rcv_seq(struct hfi1_ctxtdata *rcd, u32 seq) in last_rcv_seq() argument
1536 return seq != rcd->seq_cnt; in last_rcv_seq()
1546 static inline bool hfi1_seq_incr(struct hfi1_ctxtdata *rcd, u32 seq) in hfi1_seq_incr() argument
1548 rcd->seq_cnt = hfi1_seq_incr_wrap(rcd->seq_cnt); in hfi1_seq_incr()
1549 return last_rcv_seq(rcd, seq); in hfi1_seq_incr()
1556 static inline u8 get_hdrqentsize(struct hfi1_ctxtdata *rcd) in get_hdrqentsize() argument
1558 return rcd->rcvhdrqentsize; in get_hdrqentsize()
1565 static inline u16 get_hdrq_cnt(struct hfi1_ctxtdata *rcd) in get_hdrq_cnt() argument
1567 return rcd->rcvhdrq_cnt; in get_hdrq_cnt()
1574 static inline bool hfi1_is_slowpath(struct hfi1_ctxtdata *rcd) in hfi1_is_slowpath() argument
1576 return rcd->do_interrupt == rcd->slow_handler; in hfi1_is_slowpath()
1583 static inline bool hfi1_is_fastpath(struct hfi1_ctxtdata *rcd) in hfi1_is_fastpath() argument
1585 if (rcd->ctxt == HFI1_CTRL_CTXT) in hfi1_is_fastpath()
1588 return rcd->do_interrupt == rcd->fast_handler; in hfi1_is_fastpath()
1595 static inline void hfi1_set_fast(struct hfi1_ctxtdata *rcd) in hfi1_set_fast() argument
1597 if (unlikely(!rcd)) in hfi1_set_fast()
1599 if (unlikely(!hfi1_is_fastpath(rcd))) in hfi1_set_fast()
1600 rcd->do_interrupt = rcd->fast_handler; in hfi1_set_fast()
1938 static inline struct hfi1_ibport *rcd_to_iport(struct hfi1_ctxtdata *rcd) in rcd_to_iport() argument
1940 return &rcd->ppd->ibport_data; in rcd_to_iport()
2109 static inline __le64 *hfi1_rcvhdrtail_kvaddr(const struct hfi1_ctxtdata *rcd) in hfi1_rcvhdrtail_kvaddr() argument
2111 return (__le64 *)rcd->rcvhdrtail_kvaddr; in hfi1_rcvhdrtail_kvaddr()
2114 static inline void clear_rcvhdrtail(const struct hfi1_ctxtdata *rcd) in clear_rcvhdrtail() argument
2116 u64 *kv = (u64 *)hfi1_rcvhdrtail_kvaddr(rcd); in clear_rcvhdrtail()
2122 static inline u32 get_rcvhdrtail(const struct hfi1_ctxtdata *rcd) in get_rcvhdrtail() argument
2128 return (u32)le64_to_cpu(*hfi1_rcvhdrtail_kvaddr(rcd)); in get_rcvhdrtail()
2131 static inline bool hfi1_packet_present(struct hfi1_ctxtdata *rcd) in hfi1_packet_present() argument
2133 if (likely(!rcd->rcvhdrtail_kvaddr)) { in hfi1_packet_present()
2134 u32 seq = rhf_rcv_seq(rhf_to_cpu(get_rhf_addr(rcd))); in hfi1_packet_present()
2136 return !last_rcv_seq(rcd, seq); in hfi1_packet_present()
2138 return hfi1_rcd_head(rcd) != get_rcvhdrtail(rcd); in hfi1_packet_present()
2184 void seqfile_dump_rcd(struct seq_file *s, struct hfi1_ctxtdata *rcd);
2577 struct hfi1_ibport *ibp = &packet->rcd->ppd->ibport_data; in hfi1_make_ext_grh()