Lines Matching refs:fp
864 static bool fcoe_oem_match(struct fc_frame *fp) in fcoe_oem_match() argument
866 struct fc_frame_header *fh = fc_frame_header_get(fp); in fcoe_oem_match()
869 if (fc_fcp_is_read(fr_fsp(fp)) && in fcoe_oem_match()
870 (fr_fsp(fp)->data_len > fcoe_ddp_min)) in fcoe_oem_match()
872 else if ((fr_fsp(fp) == NULL) && in fcoe_oem_match()
875 fcp = fc_frame_payload_get(fp, sizeof(*fcp)); in fcoe_oem_match()
1585 static int fcoe_xmit(struct fc_lport *lport, struct fc_frame *fp) in fcoe_xmit() argument
1603 WARN_ON((fr_len(fp) % sizeof(u32)) != 0); in fcoe_xmit()
1605 fh = fc_frame_header_get(fp); in fcoe_xmit()
1606 skb = fp_skb(fp); in fcoe_xmit()
1618 sof = fr_sof(fp); in fcoe_xmit()
1619 eof = fr_eof(fp); in fcoe_xmit()
1634 crc = fcoe_fc_crc(fp); in fcoe_xmit()
1696 if (lport->seq_offload && fr_max_payload(fp)) { in fcoe_xmit()
1698 skb_shinfo(skb)->gso_size = fr_max_payload(fp); in fcoe_xmit()
1710 fr_dev(fp) = lport; in fcoe_xmit()
1732 struct fc_frame *fp) in fcoe_filter_frames() argument
1737 struct sk_buff *skb = (struct sk_buff *)fp; in fcoe_filter_frames()
1746 fr_flags(fp) &= ~FCPHF_CRC_UNCHECKED; in fcoe_filter_frames()
1748 fr_flags(fp) |= FCPHF_CRC_UNCHECKED; in fcoe_filter_frames()
1751 fh = fc_frame_header_get(fp); in fcoe_filter_frames()
1757 if (is_fip_mode(ctlr) && fc_frame_payload_op(fp) == ELS_LOGO && in fcoe_filter_frames()
1763 if (!(fr_flags(fp) & FCPHF_CRC_UNCHECKED) || in fcoe_filter_frames()
1764 le32_to_cpu(fr_crc(fp)) == ~crc32(~0, skb->data, skb->len)) { in fcoe_filter_frames()
1765 fr_flags(fp) &= ~FCPHF_CRC_UNCHECKED; in fcoe_filter_frames()
1788 struct fc_frame *fp; in fcoe_recv_frame() local
1835 fp = (struct fc_frame *)skb; in fcoe_recv_frame()
1836 fc_frame_init(fp); in fcoe_recv_frame()
1837 fr_dev(fp) = lport; in fcoe_recv_frame()
1838 fr_sof(fp) = hp->fcoe_sof; in fcoe_recv_frame()
1843 fr_eof(fp) = crc_eof.fcoe_eof; in fcoe_recv_frame()
1844 fr_crc(fp) = crc_eof.fcoe_crc32; in fcoe_recv_frame()
1848 if (!fcoe_filter_frames(lport, fp)) { in fcoe_recv_frame()
1850 fc_exch_recv(lport, fp); in fcoe_recv_frame()
2731 static void fcoe_flogi_resp(struct fc_seq *seq, struct fc_frame *fp, void *arg) in fcoe_flogi_resp() argument
2738 if (IS_ERR(fp)) in fcoe_flogi_resp()
2741 mac = fr_cb(fp)->granted_mac; in fcoe_flogi_resp()
2744 fcoe_ctlr_recv_flogi(fip, lport, fp); in fcoe_flogi_resp()
2748 fc_lport_flogi_resp(seq, fp, lport); in fcoe_flogi_resp()
2760 static void fcoe_logo_resp(struct fc_seq *seq, struct fc_frame *fp, void *arg) in fcoe_logo_resp() argument
2765 if (!IS_ERR(fp)) in fcoe_logo_resp()
2767 fc_lport_logo_resp(seq, fp, lport); in fcoe_logo_resp()
2780 struct fc_frame *fp, unsigned int op, in fcoe_elsct_send() argument
2789 struct fc_frame_header *fh = fc_frame_header_get(fp); in fcoe_elsct_send()
2796 return fc_elsct_send(lport, did, fp, op, fcoe_flogi_resp, in fcoe_elsct_send()
2802 return fc_elsct_send(lport, did, fp, op, fcoe_logo_resp, in fcoe_elsct_send()
2805 return fc_elsct_send(lport, did, fp, op, resp, arg, timeout); in fcoe_elsct_send()
2912 struct fc_frame *fp; in fcoe_set_vport_symbolic_name() local
2923 fp = fc_frame_alloc(lport, in fcoe_set_vport_symbolic_name()
2926 if (!fp) in fcoe_set_vport_symbolic_name()
2928 lport->tt.elsct_send(lport, FC_FID_DIR_SERV, fp, FC_NS_RSPN_ID, in fcoe_set_vport_symbolic_name()
2955 u32 port_id, struct fc_frame *fp) in fcoe_set_port_id() argument
2961 if (fp && fc_frame_payload_op(fp) == ELS_FLOGI) in fcoe_set_port_id()
2962 fcoe_ctlr_recv_flogi(ctlr, lport, fp); in fcoe_set_port_id()