fsp 141 drivers/infiniband/hw/cxgb4/restrack.c struct t4_swsqe *fsp = NULL, *lsp = NULL; fsp 164 drivers/infiniband/hw/cxgb4/restrack.c fsp = &first_sqe; fsp 178 drivers/infiniband/hw/cxgb4/restrack.c if (fill_swsqes(msg, &wq.sq, first_sq_idx, fsp, last_sq_idx, lsp)) fsp 9 drivers/net/ethernet/aquantia/atlantic/aq_filters.c aq_rule_is_approve(struct ethtool_rx_flow_spec *fsp) fsp 11 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (fsp->flow_type & FLOW_MAC_EXT) fsp 14 drivers/net/ethernet/aquantia/atlantic/aq_filters.c switch (fsp->flow_type & ~FLOW_EXT) { fsp 26 drivers/net/ethernet/aquantia/atlantic/aq_filters.c switch (fsp->h_u.usr_ip4_spec.proto) { fsp 36 drivers/net/ethernet/aquantia/atlantic/aq_filters.c switch (fsp->h_u.usr_ip6_spec.l4_proto) { fsp 68 drivers/net/ethernet/aquantia/atlantic/aq_filters.c struct ethtool_rx_flow_spec *fsp) fsp 76 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (rule->aq_fsp.location == fsp->location) fsp 78 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (aq_match_filter(&rule->aq_fsp, fsp)) { fsp 90 drivers/net/ethernet/aquantia/atlantic/aq_filters.c struct ethtool_rx_flow_spec *fsp) fsp 92 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (fsp->location < AQ_RX_FIRST_LOC_FL3L4 || fsp 93 drivers/net/ethernet/aquantia/atlantic/aq_filters.c fsp->location > AQ_RX_LAST_LOC_FL3L4) { fsp 111 drivers/net/ethernet/aquantia/atlantic/aq_filters.c fsp->location != AQ_RX_FIRST_LOC_FL3L4 + 4 && fsp 112 drivers/net/ethernet/aquantia/atlantic/aq_filters.c fsp->location != AQ_RX_FIRST_LOC_FL3L4) { fsp 125 drivers/net/ethernet/aquantia/atlantic/aq_filters.c struct ethtool_rx_flow_spec *fsp) fsp 127 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (fsp->location < AQ_RX_FIRST_LOC_FETHERT || fsp 128 drivers/net/ethernet/aquantia/atlantic/aq_filters.c fsp->location > AQ_RX_LAST_LOC_FETHERT) { fsp 136 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (be16_to_cpu(fsp->m_ext.vlan_tci) == VLAN_PRIO_MASK && fsp 137 drivers/net/ethernet/aquantia/atlantic/aq_filters.c fsp->m_u.ether_spec.h_proto == 0U) { fsp 149 drivers/net/ethernet/aquantia/atlantic/aq_filters.c struct ethtool_rx_flow_spec *fsp) fsp 151 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (fsp->location < AQ_RX_FIRST_LOC_FVLANID || fsp 152 drivers/net/ethernet/aquantia/atlantic/aq_filters.c fsp->location > AQ_RX_LAST_LOC_FVLANID) { fsp 161 drivers/net/ethernet/aquantia/atlantic/aq_filters.c (!test_bit(be16_to_cpu(fsp->h_ext.vlan_tci) & VLAN_VID_MASK, fsp 168 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (fsp->ring_cookie > aq_nic->aq_nic_cfg.num_rss_queues) { fsp 179 drivers/net/ethernet/aquantia/atlantic/aq_filters.c struct ethtool_rx_flow_spec *fsp) fsp 184 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (fsp->flow_type & FLOW_EXT) { fsp 185 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (be16_to_cpu(fsp->m_ext.vlan_tci) == VLAN_VID_MASK) { fsp 186 drivers/net/ethernet/aquantia/atlantic/aq_filters.c err = aq_check_approve_fvlan(aq_nic, rx_fltrs, fsp); fsp 187 drivers/net/ethernet/aquantia/atlantic/aq_filters.c } else if (be16_to_cpu(fsp->m_ext.vlan_tci) == VLAN_PRIO_MASK) { fsp 188 drivers/net/ethernet/aquantia/atlantic/aq_filters.c err = aq_check_approve_fl2(aq_nic, rx_fltrs, fsp); fsp 192 drivers/net/ethernet/aquantia/atlantic/aq_filters.c be16_to_cpu(fsp->m_ext.vlan_tci)); fsp 196 drivers/net/ethernet/aquantia/atlantic/aq_filters.c switch (fsp->flow_type & ~FLOW_EXT) { fsp 198 drivers/net/ethernet/aquantia/atlantic/aq_filters.c err = aq_check_approve_fl2(aq_nic, rx_fltrs, fsp); fsp 206 drivers/net/ethernet/aquantia/atlantic/aq_filters.c err = aq_check_approve_fl3l4(aq_nic, rx_fltrs, fsp); fsp 214 drivers/net/ethernet/aquantia/atlantic/aq_filters.c err = aq_check_approve_fl3l4(aq_nic, rx_fltrs, fsp); fsp 228 drivers/net/ethernet/aquantia/atlantic/aq_filters.c struct ethtool_rx_flow_spec *fsp) fsp 237 drivers/net/ethernet/aquantia/atlantic/aq_filters.c } else if (!aq_rule_is_approve(fsp)) { fsp 241 drivers/net/ethernet/aquantia/atlantic/aq_filters.c } else if ((fsp->flow_type & ~FLOW_EXT) != ETHER_FLOW && fsp 242 drivers/net/ethernet/aquantia/atlantic/aq_filters.c (fsp->h_u.tcp_ip4_spec.tos || fsp 243 drivers/net/ethernet/aquantia/atlantic/aq_filters.c fsp->h_u.tcp_ip6_spec.tclass)) { fsp 247 drivers/net/ethernet/aquantia/atlantic/aq_filters.c } else if (fsp->flow_type & FLOW_MAC_EXT) { fsp 258 drivers/net/ethernet/aquantia/atlantic/aq_filters.c struct ethtool_rx_flow_spec *fsp) fsp 264 drivers/net/ethernet/aquantia/atlantic/aq_filters.c } else if (fsp->location > AQ_RX_MAX_RXNFC_LOC) { fsp 267 drivers/net/ethernet/aquantia/atlantic/aq_filters.c fsp->location); fsp 269 drivers/net/ethernet/aquantia/atlantic/aq_filters.c } else if (aq_check_filter(aq_nic, fsp)) { fsp 271 drivers/net/ethernet/aquantia/atlantic/aq_filters.c } else if (fsp->ring_cookie != RX_CLS_FLOW_DISC) { fsp 272 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (fsp->ring_cookie >= aq_nic->aq_nic_cfg.num_rss_queues) { fsp 286 drivers/net/ethernet/aquantia/atlantic/aq_filters.c struct ethtool_rx_flow_spec *fsp) fsp 290 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (aq_rule_is_not_correct(aq_nic, fsp)) fsp 292 drivers/net/ethernet/aquantia/atlantic/aq_filters.c else if (aq_rule_is_not_support(aq_nic, fsp)) fsp 294 drivers/net/ethernet/aquantia/atlantic/aq_filters.c else if (aq_rule_already_exists(aq_nic, fsp)) fsp 304 drivers/net/ethernet/aquantia/atlantic/aq_filters.c const struct ethtool_rx_flow_spec *fsp = &aq_rx_fltr->aq_fsp; fsp 308 drivers/net/ethernet/aquantia/atlantic/aq_filters.c data->location = fsp->location - AQ_RX_FIRST_LOC_FETHERT; fsp 310 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (fsp->ring_cookie != RX_CLS_FLOW_DISC) fsp 311 drivers/net/ethernet/aquantia/atlantic/aq_filters.c data->queue = fsp->ring_cookie; fsp 315 drivers/net/ethernet/aquantia/atlantic/aq_filters.c data->ethertype = be16_to_cpu(fsp->h_u.ether_spec.h_proto); fsp 316 drivers/net/ethernet/aquantia/atlantic/aq_filters.c data->user_priority_en = be16_to_cpu(fsp->m_ext.vlan_tci) fsp 318 drivers/net/ethernet/aquantia/atlantic/aq_filters.c data->user_priority = (be16_to_cpu(fsp->h_ext.vlan_tci) fsp 397 drivers/net/ethernet/aquantia/atlantic/aq_filters.c const struct ethtool_rx_flow_spec *fsp = &aq_rx_fltr->aq_fsp; fsp 398 drivers/net/ethernet/aquantia/atlantic/aq_filters.c int location = fsp->location - AQ_RX_FIRST_LOC_FVLANID; fsp 409 drivers/net/ethernet/aquantia/atlantic/aq_filters.c (be16_to_cpu(fsp->h_ext.vlan_tci) & VLAN_VID_MASK)) { fsp 415 drivers/net/ethernet/aquantia/atlantic/aq_filters.c aq_vlans[location].vlan_id = be16_to_cpu(fsp->h_ext.vlan_tci) fsp 417 drivers/net/ethernet/aquantia/atlantic/aq_filters.c aq_vlans[location].queue = fsp->ring_cookie & 0x1FU; fsp 466 drivers/net/ethernet/aquantia/atlantic/aq_filters.c const struct ethtool_rx_flow_spec *fsp = &aq_rx_fltr->aq_fsp; fsp 471 drivers/net/ethernet/aquantia/atlantic/aq_filters.c data->location = HW_ATL_GET_REG_LOCATION_FL3L4(fsp->location); fsp 485 drivers/net/ethernet/aquantia/atlantic/aq_filters.c switch (fsp->flow_type) { fsp 506 drivers/net/ethernet/aquantia/atlantic/aq_filters.c ntohl(fsp->h_u.tcp_ip4_spec.ip4src); fsp 508 drivers/net/ethernet/aquantia/atlantic/aq_filters.c ntohl(fsp->h_u.tcp_ip4_spec.ip4dst); fsp 516 drivers/net/ethernet/aquantia/atlantic/aq_filters.c ntohl(fsp->h_u.tcp_ip6_spec.ip6dst[i]); fsp 518 drivers/net/ethernet/aquantia/atlantic/aq_filters.c ntohl(fsp->h_u.tcp_ip6_spec.ip6src[i]); fsp 522 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (fsp->flow_type != IP_USER_FLOW && fsp 523 drivers/net/ethernet/aquantia/atlantic/aq_filters.c fsp->flow_type != IPV6_USER_FLOW) { fsp 526 drivers/net/ethernet/aquantia/atlantic/aq_filters.c ntohs(fsp->h_u.tcp_ip4_spec.pdst); fsp 528 drivers/net/ethernet/aquantia/atlantic/aq_filters.c ntohs(fsp->h_u.tcp_ip4_spec.psrc); fsp 531 drivers/net/ethernet/aquantia/atlantic/aq_filters.c ntohs(fsp->h_u.tcp_ip6_spec.pdst); fsp 533 drivers/net/ethernet/aquantia/atlantic/aq_filters.c ntohs(fsp->h_u.tcp_ip6_spec.psrc); fsp 544 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (fsp->ring_cookie != RX_CLS_FLOW_DISC) { fsp 546 drivers/net/ethernet/aquantia/atlantic/aq_filters.c data->cmd |= fsp->ring_cookie << HW_ATL_RX_QUEUE_FL3L4_SHIFT; fsp 674 drivers/net/ethernet/aquantia/atlantic/aq_filters.c struct ethtool_rx_flow_spec *fsp = fsp 679 drivers/net/ethernet/aquantia/atlantic/aq_filters.c err = aq_check_rule(aq_nic, fsp); fsp 689 drivers/net/ethernet/aquantia/atlantic/aq_filters.c memcpy(&aq_rx_fltr->aq_fsp, fsp, sizeof(*fsp)); fsp 691 drivers/net/ethernet/aquantia/atlantic/aq_filters.c err = aq_update_table_filters(aq_nic, aq_rx_fltr, fsp->location, NULL); fsp 735 drivers/net/ethernet/aquantia/atlantic/aq_filters.c struct ethtool_rx_flow_spec *fsp = fsp 742 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (fsp->location <= rule->aq_fsp.location) fsp 745 drivers/net/ethernet/aquantia/atlantic/aq_filters.c if (unlikely(!rule || fsp->location != rule->aq_fsp.location)) fsp 748 drivers/net/ethernet/aquantia/atlantic/aq_filters.c memcpy(fsp, &rule->aq_fsp, sizeof(*fsp)); fsp 441 drivers/net/ethernet/cisco/enic/enic_ethtool.c struct ethtool_rx_flow_spec *fsp = fsp 445 drivers/net/ethernet/cisco/enic/enic_ethtool.c n = htbl_fltr_search(enic, (u16)fsp->location); fsp 450 drivers/net/ethernet/cisco/enic/enic_ethtool.c fsp->flow_type = TCP_V4_FLOW; fsp 453 drivers/net/ethernet/cisco/enic/enic_ethtool.c fsp->flow_type = UDP_V4_FLOW; fsp 460 drivers/net/ethernet/cisco/enic/enic_ethtool.c fsp->h_u.tcp_ip4_spec.ip4src = flow_get_u32_src(&n->keys); fsp 461 drivers/net/ethernet/cisco/enic/enic_ethtool.c fsp->m_u.tcp_ip4_spec.ip4src = (__u32)~0; fsp 463 drivers/net/ethernet/cisco/enic/enic_ethtool.c fsp->h_u.tcp_ip4_spec.ip4dst = flow_get_u32_dst(&n->keys); fsp 464 drivers/net/ethernet/cisco/enic/enic_ethtool.c fsp->m_u.tcp_ip4_spec.ip4dst = (__u32)~0; fsp 466 drivers/net/ethernet/cisco/enic/enic_ethtool.c fsp->h_u.tcp_ip4_spec.psrc = n->keys.ports.src; fsp 467 drivers/net/ethernet/cisco/enic/enic_ethtool.c fsp->m_u.tcp_ip4_spec.psrc = (__u16)~0; fsp 469 drivers/net/ethernet/cisco/enic/enic_ethtool.c fsp->h_u.tcp_ip4_spec.pdst = n->keys.ports.dst; fsp 470 drivers/net/ethernet/cisco/enic/enic_ethtool.c fsp->m_u.tcp_ip4_spec.pdst = (__u16)~0; fsp 472 drivers/net/ethernet/cisco/enic/enic_ethtool.c fsp->ring_cookie = n->rq_id; fsp 3090 drivers/net/ethernet/intel/i40e/i40e_ethtool.c static int i40e_parse_rx_flow_user_data(struct ethtool_rx_flow_spec *fsp, fsp 3099 drivers/net/ethernet/intel/i40e/i40e_ethtool.c if (!(fsp->flow_type & FLOW_EXT)) fsp 3102 drivers/net/ethernet/intel/i40e/i40e_ethtool.c value = be64_to_cpu(*((__be64 *)fsp->h_ext.data)); fsp 3103 drivers/net/ethernet/intel/i40e/i40e_ethtool.c mask = be64_to_cpu(*((__be64 *)fsp->m_ext.data)); fsp 3130 drivers/net/ethernet/intel/i40e/i40e_ethtool.c static void i40e_fill_rx_flow_user_data(struct ethtool_rx_flow_spec *fsp, fsp 3142 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp->flow_type |= FLOW_EXT; fsp 3144 drivers/net/ethernet/intel/i40e/i40e_ethtool.c *((__be64 *)fsp->h_ext.data) = cpu_to_be64(value); fsp 3145 drivers/net/ethernet/intel/i40e/i40e_ethtool.c *((__be64 *)fsp->m_ext.data) = cpu_to_be64(mask); fsp 3197 drivers/net/ethernet/intel/i40e/i40e_ethtool.c struct ethtool_rx_flow_spec *fsp = fsp 3207 drivers/net/ethernet/intel/i40e/i40e_ethtool.c if (fsp->location <= rule->fd_id) fsp 3211 drivers/net/ethernet/intel/i40e/i40e_ethtool.c if (!rule || fsp->location != rule->fd_id) fsp 3214 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp->flow_type = rule->flow_type; fsp 3215 drivers/net/ethernet/intel/i40e/i40e_ethtool.c if (fsp->flow_type == IP_USER_FLOW) { fsp 3216 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp->h_u.usr_ip4_spec.ip_ver = ETH_RX_NFC_IP4; fsp 3217 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp->h_u.usr_ip4_spec.proto = 0; fsp 3218 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp->m_u.usr_ip4_spec.proto = 0; fsp 3224 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp->h_u.tcp_ip4_spec.psrc = rule->dst_port; fsp 3225 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp->h_u.tcp_ip4_spec.pdst = rule->src_port; fsp 3226 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp->h_u.tcp_ip4_spec.ip4src = rule->dst_ip; fsp 3227 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp->h_u.tcp_ip4_spec.ip4dst = rule->src_ip; fsp 3258 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp->m_u.tcp_ip4_spec.ip4src = htonl(0xFFFFFFFF); fsp 3261 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp->m_u.tcp_ip4_spec.ip4dst = htonl(0xFFFFFFFF); fsp 3264 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp->m_u.tcp_ip4_spec.psrc = htons(0xFFFF); fsp 3267 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp->m_u.tcp_ip4_spec.pdst = htons(0xFFFF); fsp 3270 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp->ring_cookie = RX_CLS_FLOW_DISC; fsp 3272 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp->ring_cookie = rule->q_index; fsp 3285 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp->ring_cookie |= ring_vf; fsp 3295 drivers/net/ethernet/intel/i40e/i40e_ethtool.c i40e_fill_rx_flow_user_data(fsp, &userdef); fsp 3642 drivers/net/ethernet/intel/i40e/i40e_ethtool.c struct ethtool_rx_flow_spec *fsp = fsp 3654 drivers/net/ethernet/intel/i40e/i40e_ethtool.c ret = i40e_update_ethtool_fdir_entry(vsi, NULL, fsp->location, cmd); fsp 3909 drivers/net/ethernet/intel/i40e/i40e_ethtool.c static const char *i40e_flow_str(struct ethtool_rx_flow_spec *fsp) fsp 3911 drivers/net/ethernet/intel/i40e/i40e_ethtool.c switch (fsp->flow_type & ~FLOW_EXT) { fsp 4052 drivers/net/ethernet/intel/i40e/i40e_ethtool.c struct ethtool_rx_flow_spec *fsp, fsp 4066 drivers/net/ethernet/intel/i40e/i40e_ethtool.c switch (fsp->flow_type & ~FLOW_EXT) { fsp 4101 drivers/net/ethernet/intel/i40e/i40e_ethtool.c switch (fsp->flow_type & ~FLOW_EXT) { fsp 4107 drivers/net/ethernet/intel/i40e/i40e_ethtool.c tcp_ip4_spec = &fsp->m_u.tcp_ip4_spec; fsp 4147 drivers/net/ethernet/intel/i40e/i40e_ethtool.c usr_ip4_spec = &fsp->m_u.usr_ip4_spec; fsp 4285 drivers/net/ethernet/intel/i40e/i40e_ethtool.c i40e_flow_str(fsp)); fsp 4312 drivers/net/ethernet/intel/i40e/i40e_ethtool.c i40e_flow_str(fsp), fsp 4443 drivers/net/ethernet/intel/i40e/i40e_ethtool.c struct ethtool_rx_flow_spec *fsp; fsp 4467 drivers/net/ethernet/intel/i40e/i40e_ethtool.c fsp = (struct ethtool_rx_flow_spec *)&cmd->fs; fsp 4470 drivers/net/ethernet/intel/i40e/i40e_ethtool.c if (i40e_parse_rx_flow_user_data(fsp, &userdef)) fsp 4474 drivers/net/ethernet/intel/i40e/i40e_ethtool.c if (fsp->flow_type & FLOW_MAC_EXT) fsp 4477 drivers/net/ethernet/intel/i40e/i40e_ethtool.c ret = i40e_check_fdir_input_set(vsi, fsp, &userdef); fsp 4481 drivers/net/ethernet/intel/i40e/i40e_ethtool.c if (fsp->location >= (pf->hw.func_caps.fd_filters_best_effort + fsp 4489 drivers/net/ethernet/intel/i40e/i40e_ethtool.c if (fsp->ring_cookie == RX_CLS_FLOW_DISC) { fsp 4492 drivers/net/ethernet/intel/i40e/i40e_ethtool.c u32 ring = ethtool_get_flow_spec_ring(fsp->ring_cookie); fsp 4493 drivers/net/ethernet/intel/i40e/i40e_ethtool.c u8 vf = ethtool_get_flow_spec_ring_vf(fsp->ring_cookie); fsp 4518 drivers/net/ethernet/intel/i40e/i40e_ethtool.c input->fd_id = fsp->location; fsp 4524 drivers/net/ethernet/intel/i40e/i40e_ethtool.c input->dst_ip = fsp->h_u.tcp_ip4_spec.ip4src; fsp 4525 drivers/net/ethernet/intel/i40e/i40e_ethtool.c input->src_ip = fsp->h_u.tcp_ip4_spec.ip4dst; fsp 4526 drivers/net/ethernet/intel/i40e/i40e_ethtool.c input->flow_type = fsp->flow_type & ~FLOW_EXT; fsp 4527 drivers/net/ethernet/intel/i40e/i40e_ethtool.c input->ip4_proto = fsp->h_u.usr_ip4_spec.proto; fsp 4532 drivers/net/ethernet/intel/i40e/i40e_ethtool.c input->dst_port = fsp->h_u.tcp_ip4_spec.psrc; fsp 4533 drivers/net/ethernet/intel/i40e/i40e_ethtool.c input->src_port = fsp->h_u.tcp_ip4_spec.pdst; fsp 4534 drivers/net/ethernet/intel/i40e/i40e_ethtool.c input->dst_ip = fsp->h_u.tcp_ip4_spec.ip4src; fsp 4535 drivers/net/ethernet/intel/i40e/i40e_ethtool.c input->src_ip = fsp->h_u.tcp_ip4_spec.ip4dst; fsp 4552 drivers/net/ethernet/intel/i40e/i40e_ethtool.c i40e_update_ethtool_fdir_entry(vsi, input, fsp->location, NULL); fsp 2454 drivers/net/ethernet/intel/igb/igb_ethtool.c struct ethtool_rx_flow_spec *fsp = &cmd->fs; fsp 2461 drivers/net/ethernet/intel/igb/igb_ethtool.c if (fsp->location <= rule->sw_idx) fsp 2465 drivers/net/ethernet/intel/igb/igb_ethtool.c if (!rule || fsp->location != rule->sw_idx) fsp 2469 drivers/net/ethernet/intel/igb/igb_ethtool.c fsp->flow_type = ETHER_FLOW; fsp 2470 drivers/net/ethernet/intel/igb/igb_ethtool.c fsp->ring_cookie = rule->action; fsp 2472 drivers/net/ethernet/intel/igb/igb_ethtool.c fsp->h_u.ether_spec.h_proto = rule->filter.etype; fsp 2473 drivers/net/ethernet/intel/igb/igb_ethtool.c fsp->m_u.ether_spec.h_proto = ETHER_TYPE_FULL_MASK; fsp 2476 drivers/net/ethernet/intel/igb/igb_ethtool.c fsp->flow_type |= FLOW_EXT; fsp 2477 drivers/net/ethernet/intel/igb/igb_ethtool.c fsp->h_ext.vlan_tci = rule->filter.vlan_tci; fsp 2478 drivers/net/ethernet/intel/igb/igb_ethtool.c fsp->m_ext.vlan_tci = htons(VLAN_PRIO_MASK); fsp 2481 drivers/net/ethernet/intel/igb/igb_ethtool.c ether_addr_copy(fsp->h_u.ether_spec.h_dest, fsp 2486 drivers/net/ethernet/intel/igb/igb_ethtool.c eth_broadcast_addr(fsp->m_u.ether_spec.h_dest); fsp 2489 drivers/net/ethernet/intel/igb/igb_ethtool.c ether_addr_copy(fsp->h_u.ether_spec.h_source, fsp 2494 drivers/net/ethernet/intel/igb/igb_ethtool.c eth_broadcast_addr(fsp->m_u.ether_spec.h_source); fsp 2917 drivers/net/ethernet/intel/igb/igb_ethtool.c struct ethtool_rx_flow_spec *fsp = fsp 2928 drivers/net/ethernet/intel/igb/igb_ethtool.c if ((fsp->ring_cookie == RX_CLS_FLOW_DISC) || fsp 2929 drivers/net/ethernet/intel/igb/igb_ethtool.c (fsp->ring_cookie >= adapter->num_rx_queues)) { fsp 2935 drivers/net/ethernet/intel/igb/igb_ethtool.c if (fsp->location >= IGB_MAX_RXNFC_FILTERS) { fsp 2940 drivers/net/ethernet/intel/igb/igb_ethtool.c if ((fsp->flow_type & ~FLOW_EXT) != ETHER_FLOW) fsp 2947 drivers/net/ethernet/intel/igb/igb_ethtool.c if (fsp->m_u.ether_spec.h_proto == ETHER_TYPE_FULL_MASK) { fsp 2948 drivers/net/ethernet/intel/igb/igb_ethtool.c input->filter.etype = fsp->h_u.ether_spec.h_proto; fsp 2953 drivers/net/ethernet/intel/igb/igb_ethtool.c if (is_broadcast_ether_addr(fsp->m_u.ether_spec.h_source)) { fsp 2956 drivers/net/ethernet/intel/igb/igb_ethtool.c fsp->h_u.ether_spec.h_source); fsp 2960 drivers/net/ethernet/intel/igb/igb_ethtool.c if (is_broadcast_ether_addr(fsp->m_u.ether_spec.h_dest)) { fsp 2963 drivers/net/ethernet/intel/igb/igb_ethtool.c fsp->h_u.ether_spec.h_dest); fsp 2966 drivers/net/ethernet/intel/igb/igb_ethtool.c if ((fsp->flow_type & FLOW_EXT) && fsp->m_ext.vlan_tci) { fsp 2967 drivers/net/ethernet/intel/igb/igb_ethtool.c if (fsp->m_ext.vlan_tci != htons(VLAN_PRIO_MASK)) { fsp 2971 drivers/net/ethernet/intel/igb/igb_ethtool.c input->filter.vlan_tci = fsp->h_ext.vlan_tci; fsp 2975 drivers/net/ethernet/intel/igb/igb_ethtool.c input->action = fsp->ring_cookie; fsp 2976 drivers/net/ethernet/intel/igb/igb_ethtool.c input->sw_idx = fsp->location; fsp 3009 drivers/net/ethernet/intel/igb/igb_ethtool.c struct ethtool_rx_flow_spec *fsp = fsp 3014 drivers/net/ethernet/intel/igb/igb_ethtool.c err = igb_update_ethtool_nfc_entry(adapter, NULL, fsp->location); fsp 881 drivers/net/ethernet/intel/igc/igc_ethtool.c struct ethtool_rx_flow_spec *fsp = &cmd->fs; fsp 888 drivers/net/ethernet/intel/igc/igc_ethtool.c if (fsp->location <= rule->sw_idx) fsp 892 drivers/net/ethernet/intel/igc/igc_ethtool.c if (!rule || fsp->location != rule->sw_idx) fsp 896 drivers/net/ethernet/intel/igc/igc_ethtool.c fsp->flow_type = ETHER_FLOW; fsp 897 drivers/net/ethernet/intel/igc/igc_ethtool.c fsp->ring_cookie = rule->action; fsp 899 drivers/net/ethernet/intel/igc/igc_ethtool.c fsp->h_u.ether_spec.h_proto = rule->filter.etype; fsp 900 drivers/net/ethernet/intel/igc/igc_ethtool.c fsp->m_u.ether_spec.h_proto = ETHER_TYPE_FULL_MASK; fsp 903 drivers/net/ethernet/intel/igc/igc_ethtool.c fsp->flow_type |= FLOW_EXT; fsp 904 drivers/net/ethernet/intel/igc/igc_ethtool.c fsp->h_ext.vlan_tci = rule->filter.vlan_tci; fsp 905 drivers/net/ethernet/intel/igc/igc_ethtool.c fsp->m_ext.vlan_tci = htons(VLAN_PRIO_MASK); fsp 908 drivers/net/ethernet/intel/igc/igc_ethtool.c ether_addr_copy(fsp->h_u.ether_spec.h_dest, fsp 913 drivers/net/ethernet/intel/igc/igc_ethtool.c eth_broadcast_addr(fsp->m_u.ether_spec.h_dest); fsp 916 drivers/net/ethernet/intel/igc/igc_ethtool.c ether_addr_copy(fsp->h_u.ether_spec.h_source, fsp 921 drivers/net/ethernet/intel/igc/igc_ethtool.c eth_broadcast_addr(fsp->m_u.ether_spec.h_source); fsp 1352 drivers/net/ethernet/intel/igc/igc_ethtool.c struct ethtool_rx_flow_spec *fsp = fsp 1363 drivers/net/ethernet/intel/igc/igc_ethtool.c if (fsp->ring_cookie == RX_CLS_FLOW_DISC || fsp 1364 drivers/net/ethernet/intel/igc/igc_ethtool.c fsp->ring_cookie >= adapter->num_rx_queues) { fsp 1370 drivers/net/ethernet/intel/igc/igc_ethtool.c if (fsp->location >= IGC_MAX_RXNFC_FILTERS) { fsp 1375 drivers/net/ethernet/intel/igc/igc_ethtool.c if ((fsp->flow_type & ~FLOW_EXT) != ETHER_FLOW) fsp 1382 drivers/net/ethernet/intel/igc/igc_ethtool.c if (fsp->m_u.ether_spec.h_proto == ETHER_TYPE_FULL_MASK) { fsp 1383 drivers/net/ethernet/intel/igc/igc_ethtool.c input->filter.etype = fsp->h_u.ether_spec.h_proto; fsp 1388 drivers/net/ethernet/intel/igc/igc_ethtool.c if (is_broadcast_ether_addr(fsp->m_u.ether_spec.h_source)) { fsp 1391 drivers/net/ethernet/intel/igc/igc_ethtool.c fsp->h_u.ether_spec.h_source); fsp 1395 drivers/net/ethernet/intel/igc/igc_ethtool.c if (is_broadcast_ether_addr(fsp->m_u.ether_spec.h_dest)) { fsp 1398 drivers/net/ethernet/intel/igc/igc_ethtool.c fsp->h_u.ether_spec.h_dest); fsp 1401 drivers/net/ethernet/intel/igc/igc_ethtool.c if ((fsp->flow_type & FLOW_EXT) && fsp->m_ext.vlan_tci) { fsp 1402 drivers/net/ethernet/intel/igc/igc_ethtool.c if (fsp->m_ext.vlan_tci != htons(VLAN_PRIO_MASK)) { fsp 1406 drivers/net/ethernet/intel/igc/igc_ethtool.c input->filter.vlan_tci = fsp->h_ext.vlan_tci; fsp 1410 drivers/net/ethernet/intel/igc/igc_ethtool.c input->action = fsp->ring_cookie; fsp 1411 drivers/net/ethernet/intel/igc/igc_ethtool.c input->sw_idx = fsp->location; fsp 1444 drivers/net/ethernet/intel/igc/igc_ethtool.c struct ethtool_rx_flow_spec *fsp = fsp 1449 drivers/net/ethernet/intel/igc/igc_ethtool.c err = igc_update_ethtool_nfc_entry(adapter, NULL, fsp->location); fsp 2414 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c struct ethtool_rx_flow_spec *fsp = fsp 2424 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c if (fsp->location <= rule->sw_idx) fsp 2428 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c if (!rule || fsp->location != rule->sw_idx) fsp 2436 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->flow_type = TCP_V4_FLOW; fsp 2439 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->flow_type = UDP_V4_FLOW; fsp 2442 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->flow_type = SCTP_V4_FLOW; fsp 2445 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->flow_type = IP_USER_FLOW; fsp 2446 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->h_u.usr_ip4_spec.ip_ver = ETH_RX_NFC_IP4; fsp 2447 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->h_u.usr_ip4_spec.proto = 0; fsp 2448 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->m_u.usr_ip4_spec.proto = 0; fsp 2454 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->h_u.tcp_ip4_spec.psrc = rule->filter.formatted.src_port; fsp 2455 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->m_u.tcp_ip4_spec.psrc = mask->formatted.src_port; fsp 2456 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->h_u.tcp_ip4_spec.pdst = rule->filter.formatted.dst_port; fsp 2457 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->m_u.tcp_ip4_spec.pdst = mask->formatted.dst_port; fsp 2458 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->h_u.tcp_ip4_spec.ip4src = rule->filter.formatted.src_ip[0]; fsp 2459 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->m_u.tcp_ip4_spec.ip4src = mask->formatted.src_ip[0]; fsp 2460 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->h_u.tcp_ip4_spec.ip4dst = rule->filter.formatted.dst_ip[0]; fsp 2461 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->m_u.tcp_ip4_spec.ip4dst = mask->formatted.dst_ip[0]; fsp 2462 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->h_ext.vlan_tci = rule->filter.formatted.vlan_id; fsp 2463 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->m_ext.vlan_tci = mask->formatted.vlan_id; fsp 2464 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->h_ext.vlan_etype = rule->filter.formatted.flex_bytes; fsp 2465 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->m_ext.vlan_etype = mask->formatted.flex_bytes; fsp 2466 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->h_ext.data[1] = htonl(rule->filter.formatted.vm_pool); fsp 2467 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->m_ext.data[1] = htonl(mask->formatted.vm_pool); fsp 2468 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->flow_type |= FLOW_EXT; fsp 2472 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->ring_cookie = RX_CLS_FLOW_DISC; fsp 2474 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->ring_cookie = rule->action; fsp 2633 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c static int ixgbe_flowspec_to_flow_type(struct ethtool_rx_flow_spec *fsp, fsp 2636 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c switch (fsp->flow_type & ~FLOW_EXT) { fsp 2647 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c switch (fsp->h_u.usr_ip4_spec.proto) { fsp 2658 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c if (!fsp->m_u.usr_ip4_spec.proto) { fsp 2677 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c struct ethtool_rx_flow_spec *fsp = fsp 2691 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c if (fsp->ring_cookie == RX_CLS_FLOW_DISC) { fsp 2694 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c u32 ring = ethtool_get_flow_spec_ring(fsp->ring_cookie); fsp 2695 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c u8 vf = ethtool_get_flow_spec_ring_vf(fsp->ring_cookie); fsp 2713 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c if (fsp->location >= ((1024 << adapter->fdir_pballoc) - 2)) { fsp 2725 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c input->sw_idx = fsp->location; fsp 2728 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c if (!ixgbe_flowspec_to_flow_type(fsp, fsp 2741 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c input->filter.formatted.src_ip[0] = fsp->h_u.tcp_ip4_spec.ip4src; fsp 2742 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c mask.formatted.src_ip[0] = fsp->m_u.tcp_ip4_spec.ip4src; fsp 2743 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c input->filter.formatted.dst_ip[0] = fsp->h_u.tcp_ip4_spec.ip4dst; fsp 2744 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c mask.formatted.dst_ip[0] = fsp->m_u.tcp_ip4_spec.ip4dst; fsp 2745 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c input->filter.formatted.src_port = fsp->h_u.tcp_ip4_spec.psrc; fsp 2746 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c mask.formatted.src_port = fsp->m_u.tcp_ip4_spec.psrc; fsp 2747 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c input->filter.formatted.dst_port = fsp->h_u.tcp_ip4_spec.pdst; fsp 2748 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c mask.formatted.dst_port = fsp->m_u.tcp_ip4_spec.pdst; fsp 2750 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c if (fsp->flow_type & FLOW_EXT) { fsp 2752 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c (unsigned char)ntohl(fsp->h_ext.data[1]); fsp 2754 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c (unsigned char)ntohl(fsp->m_ext.data[1]); fsp 2755 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c input->filter.formatted.vlan_id = fsp->h_ext.vlan_tci; fsp 2756 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c mask.formatted.vlan_id = fsp->m_ext.vlan_tci; fsp 2758 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c fsp->h_ext.vlan_etype; fsp 2759 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c mask.formatted.flex_bytes = fsp->m_ext.vlan_etype; fsp 2763 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c if (fsp->ring_cookie == RX_CLS_FLOW_DISC) fsp 2766 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c input->action = fsp->ring_cookie; fsp 2807 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c struct ethtool_rx_flow_spec *fsp = fsp 2812 drivers/net/ethernet/intel/ixgbe/ixgbe_ethtool.c err = ixgbe_update_ethtool_fdir_entry(adapter, NULL, fsp->location); fsp 1869 drivers/net/ethernet/mediatek/mtk_eth_soc.c struct ethtool_rx_flow_spec *fsp = fsp 1875 drivers/net/ethernet/mediatek/mtk_eth_soc.c if ((fsp->flow_type != TCP_V4_FLOW) || fsp 1876 drivers/net/ethernet/mediatek/mtk_eth_soc.c (!fsp->h_u.tcp_ip4_spec.ip4dst) || fsp 1877 drivers/net/ethernet/mediatek/mtk_eth_soc.c (fsp->location > 1)) fsp 1880 drivers/net/ethernet/mediatek/mtk_eth_soc.c mac->hwlro_ip[fsp->location] = htonl(fsp->h_u.tcp_ip4_spec.ip4dst); fsp 1881 drivers/net/ethernet/mediatek/mtk_eth_soc.c hwlro_idx = (mac->id * MTK_MAX_LRO_IP_CNT) + fsp->location; fsp 1885 drivers/net/ethernet/mediatek/mtk_eth_soc.c mtk_hwlro_val_ipaddr(eth, hwlro_idx, mac->hwlro_ip[fsp->location]); fsp 1893 drivers/net/ethernet/mediatek/mtk_eth_soc.c struct ethtool_rx_flow_spec *fsp = fsp 1899 drivers/net/ethernet/mediatek/mtk_eth_soc.c if (fsp->location > 1) fsp 1902 drivers/net/ethernet/mediatek/mtk_eth_soc.c mac->hwlro_ip[fsp->location] = 0; fsp 1903 drivers/net/ethernet/mediatek/mtk_eth_soc.c hwlro_idx = (mac->id * MTK_MAX_LRO_IP_CNT) + fsp->location; fsp 1932 drivers/net/ethernet/mediatek/mtk_eth_soc.c struct ethtool_rx_flow_spec *fsp = fsp 1936 drivers/net/ethernet/mediatek/mtk_eth_soc.c fsp->flow_type = TCP_V4_FLOW; fsp 1937 drivers/net/ethernet/mediatek/mtk_eth_soc.c fsp->h_u.tcp_ip4_spec.ip4dst = ntohl(mac->hwlro_ip[fsp->location]); fsp 1938 drivers/net/ethernet/mediatek/mtk_eth_soc.c fsp->m_u.tcp_ip4_spec.ip4dst = 0; fsp 1940 drivers/net/ethernet/mediatek/mtk_eth_soc.c fsp->h_u.tcp_ip4_spec.ip4src = 0; fsp 1941 drivers/net/ethernet/mediatek/mtk_eth_soc.c fsp->m_u.tcp_ip4_spec.ip4src = 0xffffffff; fsp 1942 drivers/net/ethernet/mediatek/mtk_eth_soc.c fsp->h_u.tcp_ip4_spec.psrc = 0; fsp 1943 drivers/net/ethernet/mediatek/mtk_eth_soc.c fsp->m_u.tcp_ip4_spec.psrc = 0xffff; fsp 1944 drivers/net/ethernet/mediatek/mtk_eth_soc.c fsp->h_u.tcp_ip4_spec.pdst = 0; fsp 1945 drivers/net/ethernet/mediatek/mtk_eth_soc.c fsp->m_u.tcp_ip4_spec.pdst = 0xffff; fsp 1946 drivers/net/ethernet/mediatek/mtk_eth_soc.c fsp->h_u.tcp_ip4_spec.tos = 0; fsp 1947 drivers/net/ethernet/mediatek/mtk_eth_soc.c fsp->m_u.tcp_ip4_spec.tos = 0xff; fsp 1402 drivers/net/ethernet/qlogic/qede/qede_filter.c struct ethtool_rx_flow_spec *fsp = &cmd->fs; fsp 1416 drivers/net/ethernet/qlogic/qede/qede_filter.c fsp->location); fsp 1419 drivers/net/ethernet/qlogic/qede/qede_filter.c fsp->location); fsp 1426 drivers/net/ethernet/qlogic/qede/qede_filter.c fsp->flow_type = TCP_V4_FLOW; fsp 1428 drivers/net/ethernet/qlogic/qede/qede_filter.c fsp->flow_type = UDP_V4_FLOW; fsp 1430 drivers/net/ethernet/qlogic/qede/qede_filter.c fsp->h_u.tcp_ip4_spec.psrc = fltr->tuple.src_port; fsp 1431 drivers/net/ethernet/qlogic/qede/qede_filter.c fsp->h_u.tcp_ip4_spec.pdst = fltr->tuple.dst_port; fsp 1432 drivers/net/ethernet/qlogic/qede/qede_filter.c fsp->h_u.tcp_ip4_spec.ip4src = fltr->tuple.src_ipv4; fsp 1433 drivers/net/ethernet/qlogic/qede/qede_filter.c fsp->h_u.tcp_ip4_spec.ip4dst = fltr->tuple.dst_ipv4; fsp 1436 drivers/net/ethernet/qlogic/qede/qede_filter.c fsp->flow_type = TCP_V6_FLOW; fsp 1438 drivers/net/ethernet/qlogic/qede/qede_filter.c fsp->flow_type = UDP_V6_FLOW; fsp 1439 drivers/net/ethernet/qlogic/qede/qede_filter.c fsp->h_u.tcp_ip6_spec.psrc = fltr->tuple.src_port; fsp 1440 drivers/net/ethernet/qlogic/qede/qede_filter.c fsp->h_u.tcp_ip6_spec.pdst = fltr->tuple.dst_port; fsp 1441 drivers/net/ethernet/qlogic/qede/qede_filter.c memcpy(&fsp->h_u.tcp_ip6_spec.ip6src, fsp 1443 drivers/net/ethernet/qlogic/qede/qede_filter.c memcpy(&fsp->h_u.tcp_ip6_spec.ip6dst, fsp 1447 drivers/net/ethernet/qlogic/qede/qede_filter.c fsp->ring_cookie = fltr->rxq_id; fsp 1450 drivers/net/ethernet/qlogic/qede/qede_filter.c fsp->ring_cookie |= ((u64)fltr->vfid) << fsp 1455 drivers/net/ethernet/qlogic/qede/qede_filter.c fsp->ring_cookie = RX_CLS_FLOW_DISC; fsp 2095 drivers/net/ethernet/qlogic/qede/qede_filter.c struct ethtool_rx_flow_spec *fsp = &info->fs; fsp 2108 drivers/net/ethernet/qlogic/qede/qede_filter.c rc = qede_flow_spec_to_rule(edev, &t, fsp); fsp 2131 drivers/net/ethernet/qlogic/qede/qede_filter.c n->sw_id = fsp->location; fsp 2137 drivers/net/ethernet/qlogic/qede/qede_filter.c qede_flow_set_destination(edev, n, fsp); fsp 7077 drivers/net/ethernet/sun/niu.c struct ethtool_rx_flow_spec *fsp) fsp 7083 drivers/net/ethernet/sun/niu.c fsp->h_u.tcp_ip4_spec.ip4src = cpu_to_be32(tmp); fsp 7086 drivers/net/ethernet/sun/niu.c fsp->h_u.tcp_ip4_spec.ip4dst = cpu_to_be32(tmp); fsp 7089 drivers/net/ethernet/sun/niu.c fsp->m_u.tcp_ip4_spec.ip4src = cpu_to_be32(tmp); fsp 7092 drivers/net/ethernet/sun/niu.c fsp->m_u.tcp_ip4_spec.ip4dst = cpu_to_be32(tmp); fsp 7094 drivers/net/ethernet/sun/niu.c fsp->h_u.tcp_ip4_spec.tos = (tp->key[2] & TCAM_V4KEY2_TOS) >> fsp 7096 drivers/net/ethernet/sun/niu.c fsp->m_u.tcp_ip4_spec.tos = (tp->key_mask[2] & TCAM_V4KEY2_TOS) >> fsp 7099 drivers/net/ethernet/sun/niu.c switch (fsp->flow_type) { fsp 7105 drivers/net/ethernet/sun/niu.c fsp->h_u.tcp_ip4_spec.psrc = cpu_to_be16(prt); fsp 7109 drivers/net/ethernet/sun/niu.c fsp->h_u.tcp_ip4_spec.pdst = cpu_to_be16(prt); fsp 7113 drivers/net/ethernet/sun/niu.c fsp->m_u.tcp_ip4_spec.psrc = cpu_to_be16(prt); fsp 7117 drivers/net/ethernet/sun/niu.c fsp->m_u.tcp_ip4_spec.pdst = cpu_to_be16(prt); fsp 7123 drivers/net/ethernet/sun/niu.c fsp->h_u.ah_ip4_spec.spi = cpu_to_be32(tmp); fsp 7127 drivers/net/ethernet/sun/niu.c fsp->m_u.ah_ip4_spec.spi = cpu_to_be32(tmp); fsp 7132 drivers/net/ethernet/sun/niu.c fsp->h_u.usr_ip4_spec.l4_4_bytes = cpu_to_be32(tmp); fsp 7136 drivers/net/ethernet/sun/niu.c fsp->m_u.usr_ip4_spec.l4_4_bytes = cpu_to_be32(tmp); fsp 7138 drivers/net/ethernet/sun/niu.c fsp->h_u.usr_ip4_spec.proto = fsp 7141 drivers/net/ethernet/sun/niu.c fsp->m_u.usr_ip4_spec.proto = fsp 7145 drivers/net/ethernet/sun/niu.c fsp->h_u.usr_ip4_spec.ip_ver = ETH_RX_NFC_IP4; fsp 7157 drivers/net/ethernet/sun/niu.c struct ethtool_rx_flow_spec *fsp = &nfc->fs; fsp 7174 drivers/net/ethernet/sun/niu.c ret = niu_class_to_ethflow(class, &fsp->flow_type); fsp 7181 drivers/net/ethernet/sun/niu.c if (fsp->flow_type == AH_V4_FLOW || fsp->flow_type == AH_V6_FLOW) { fsp 7185 drivers/net/ethernet/sun/niu.c if (fsp->flow_type == AH_V4_FLOW) fsp 7186 drivers/net/ethernet/sun/niu.c fsp->flow_type = ESP_V4_FLOW; fsp 7188 drivers/net/ethernet/sun/niu.c fsp->flow_type = ESP_V6_FLOW; fsp 7192 drivers/net/ethernet/sun/niu.c switch (fsp->flow_type) { fsp 7198 drivers/net/ethernet/sun/niu.c niu_get_ip4fs_from_tcam_key(tp, fsp); fsp 7209 drivers/net/ethernet/sun/niu.c niu_get_ip4fs_from_tcam_key(tp, fsp); fsp 7220 drivers/net/ethernet/sun/niu.c fsp->ring_cookie = RX_CLS_FLOW_DISC; fsp 7222 drivers/net/ethernet/sun/niu.c fsp->ring_cookie = (tp->assoc_data & TCAM_ASSOCDATA_OFFSET) >> fsp 7343 drivers/net/ethernet/sun/niu.c static void niu_get_tcamkey_from_ip4fs(struct ethtool_rx_flow_spec *fsp, fsp 7351 drivers/net/ethernet/sun/niu.c sip = be32_to_cpu(fsp->h_u.tcp_ip4_spec.ip4src); fsp 7352 drivers/net/ethernet/sun/niu.c sipm = be32_to_cpu(fsp->m_u.tcp_ip4_spec.ip4src); fsp 7353 drivers/net/ethernet/sun/niu.c dip = be32_to_cpu(fsp->h_u.tcp_ip4_spec.ip4dst); fsp 7354 drivers/net/ethernet/sun/niu.c dipm = be32_to_cpu(fsp->m_u.tcp_ip4_spec.ip4dst); fsp 7367 drivers/net/ethernet/sun/niu.c tp->key[2] |= ((u64)fsp->h_u.tcp_ip4_spec.tos << fsp 7369 drivers/net/ethernet/sun/niu.c tp->key_mask[2] |= ((u64)fsp->m_u.tcp_ip4_spec.tos << fsp 7371 drivers/net/ethernet/sun/niu.c switch (fsp->flow_type) { fsp 7375 drivers/net/ethernet/sun/niu.c sport = be16_to_cpu(fsp->h_u.tcp_ip4_spec.psrc); fsp 7376 drivers/net/ethernet/sun/niu.c spm = be16_to_cpu(fsp->m_u.tcp_ip4_spec.psrc); fsp 7377 drivers/net/ethernet/sun/niu.c dport = be16_to_cpu(fsp->h_u.tcp_ip4_spec.pdst); fsp 7378 drivers/net/ethernet/sun/niu.c dpm = be16_to_cpu(fsp->m_u.tcp_ip4_spec.pdst); fsp 7382 drivers/net/ethernet/sun/niu.c niu_ethflow_to_l3proto(fsp->flow_type, &pid); fsp 7386 drivers/net/ethernet/sun/niu.c spi = be32_to_cpu(fsp->h_u.ah_ip4_spec.spi); fsp 7387 drivers/net/ethernet/sun/niu.c spim = be32_to_cpu(fsp->m_u.ah_ip4_spec.spi); fsp 7391 drivers/net/ethernet/sun/niu.c niu_ethflow_to_l3proto(fsp->flow_type, &pid); fsp 7394 drivers/net/ethernet/sun/niu.c spi = be32_to_cpu(fsp->h_u.usr_ip4_spec.l4_4_bytes); fsp 7395 drivers/net/ethernet/sun/niu.c spim = be32_to_cpu(fsp->m_u.usr_ip4_spec.l4_4_bytes); fsp 7399 drivers/net/ethernet/sun/niu.c pid = fsp->h_u.usr_ip4_spec.proto; fsp 7416 drivers/net/ethernet/sun/niu.c struct ethtool_rx_flow_spec *fsp = &nfc->fs; fsp 7430 drivers/net/ethernet/sun/niu.c if (fsp->flow_type == IP_USER_FLOW) { fsp 7433 drivers/net/ethernet/sun/niu.c struct ethtool_usrip4_spec *uspec = &fsp->h_u.usr_ip4_spec; fsp 7434 drivers/net/ethernet/sun/niu.c struct ethtool_usrip4_spec *umask = &fsp->m_u.usr_ip4_spec; fsp 7493 drivers/net/ethernet/sun/niu.c if (!niu_ethflow_to_class(fsp->flow_type, &class)) { fsp 7506 drivers/net/ethernet/sun/niu.c switch (fsp->flow_type) { fsp 7512 drivers/net/ethernet/sun/niu.c niu_get_tcamkey_from_ip4fs(fsp, tp, l2_rdc_table, class); fsp 7521 drivers/net/ethernet/sun/niu.c parent->index, __func__, fsp->flow_type); fsp 7525 drivers/net/ethernet/sun/niu.c niu_get_tcamkey_from_ip4fs(fsp, tp, l2_rdc_table, class); fsp 7529 drivers/net/ethernet/sun/niu.c parent->index, __func__, fsp->flow_type); fsp 7535 drivers/net/ethernet/sun/niu.c if (fsp->ring_cookie == RX_CLS_FLOW_DISC) { fsp 7538 drivers/net/ethernet/sun/niu.c if (fsp->ring_cookie >= np->num_rx_rings) { fsp 7541 drivers/net/ethernet/sun/niu.c (long long)fsp->ring_cookie); fsp 7546 drivers/net/ethernet/sun/niu.c (fsp->ring_cookie << fsp 2170 drivers/scsi/libfc/fc_exch.c struct fc_fcp_pkt *fsp = NULL; fsp 2194 drivers/scsi/libfc/fc_exch.c fsp = fr_fsp(fp); fsp 2210 drivers/scsi/libfc/fc_exch.c if (fsp) fsp 2211 drivers/scsi/libfc/fc_exch.c fc_fcp_ddp_done(fsp); fsp 138 drivers/scsi/libfc/fc_fcp.c struct fc_fcp_pkt *fsp; fsp 140 drivers/scsi/libfc/fc_fcp.c fsp = mempool_alloc(si->scsi_pkt_pool, gfp); fsp 141 drivers/scsi/libfc/fc_fcp.c if (fsp) { fsp 142 drivers/scsi/libfc/fc_fcp.c memset(fsp, 0, sizeof(*fsp)); fsp 143 drivers/scsi/libfc/fc_fcp.c fsp->lp = lport; fsp 144 drivers/scsi/libfc/fc_fcp.c fsp->xfer_ddp = FC_XID_UNKNOWN; fsp 145 drivers/scsi/libfc/fc_fcp.c refcount_set(&fsp->ref_cnt, 1); fsp 146 drivers/scsi/libfc/fc_fcp.c timer_setup(&fsp->timer, NULL, 0); fsp 147 drivers/scsi/libfc/fc_fcp.c INIT_LIST_HEAD(&fsp->list); fsp 148 drivers/scsi/libfc/fc_fcp.c spin_lock_init(&fsp->scsi_pkt_lock); fsp 153 drivers/scsi/libfc/fc_fcp.c return fsp; fsp 163 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_pkt_release(struct fc_fcp_pkt *fsp) fsp 165 drivers/scsi/libfc/fc_fcp.c if (refcount_dec_and_test(&fsp->ref_cnt)) { fsp 166 drivers/scsi/libfc/fc_fcp.c struct fc_fcp_internal *si = fc_get_scsi_internal(fsp->lp); fsp 168 drivers/scsi/libfc/fc_fcp.c mempool_free(fsp, si->scsi_pkt_pool); fsp 176 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_pkt_hold(struct fc_fcp_pkt *fsp) fsp 178 drivers/scsi/libfc/fc_fcp.c refcount_inc(&fsp->ref_cnt); fsp 192 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_pkt_destroy(struct fc_seq *seq, void *fsp) fsp 194 drivers/scsi/libfc/fc_fcp.c fc_fcp_pkt_release(fsp); fsp 214 drivers/scsi/libfc/fc_fcp.c static inline int fc_fcp_lock_pkt(struct fc_fcp_pkt *fsp) fsp 216 drivers/scsi/libfc/fc_fcp.c spin_lock_bh(&fsp->scsi_pkt_lock); fsp 217 drivers/scsi/libfc/fc_fcp.c if (fsp->state & FC_SRB_COMPL) { fsp 218 drivers/scsi/libfc/fc_fcp.c spin_unlock_bh(&fsp->scsi_pkt_lock); fsp 222 drivers/scsi/libfc/fc_fcp.c fc_fcp_pkt_hold(fsp); fsp 231 drivers/scsi/libfc/fc_fcp.c static inline void fc_fcp_unlock_pkt(struct fc_fcp_pkt *fsp) fsp 233 drivers/scsi/libfc/fc_fcp.c spin_unlock_bh(&fsp->scsi_pkt_lock); fsp 234 drivers/scsi/libfc/fc_fcp.c fc_fcp_pkt_release(fsp); fsp 242 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_timer_set(struct fc_fcp_pkt *fsp, unsigned long delay) fsp 244 drivers/scsi/libfc/fc_fcp.c if (!(fsp->state & FC_SRB_COMPL)) { fsp 245 drivers/scsi/libfc/fc_fcp.c mod_timer(&fsp->timer, jiffies + delay); fsp 246 drivers/scsi/libfc/fc_fcp.c fsp->timer_delay = delay; fsp 250 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_abort_done(struct fc_fcp_pkt *fsp) fsp 252 drivers/scsi/libfc/fc_fcp.c fsp->state |= FC_SRB_ABORTED; fsp 253 drivers/scsi/libfc/fc_fcp.c fsp->state &= ~FC_SRB_ABORT_PENDING; fsp 255 drivers/scsi/libfc/fc_fcp.c if (fsp->wait_for_comp) fsp 256 drivers/scsi/libfc/fc_fcp.c complete(&fsp->tm_done); fsp 258 drivers/scsi/libfc/fc_fcp.c fc_fcp_complete_locked(fsp); fsp 266 drivers/scsi/libfc/fc_fcp.c static int fc_fcp_send_abort(struct fc_fcp_pkt *fsp) fsp 270 drivers/scsi/libfc/fc_fcp.c if (!fsp->seq_ptr) fsp 273 drivers/scsi/libfc/fc_fcp.c per_cpu_ptr(fsp->lp->stats, get_cpu())->FcpPktAborts++; fsp 276 drivers/scsi/libfc/fc_fcp.c fsp->state |= FC_SRB_ABORT_PENDING; fsp 277 drivers/scsi/libfc/fc_fcp.c rc = fc_seq_exch_abort(fsp->seq_ptr, 0); fsp 283 drivers/scsi/libfc/fc_fcp.c fc_fcp_abort_done(fsp); fsp 298 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_retry_cmd(struct fc_fcp_pkt *fsp, int status_code) fsp 300 drivers/scsi/libfc/fc_fcp.c if (fsp->seq_ptr) { fsp 301 drivers/scsi/libfc/fc_fcp.c fc_exch_done(fsp->seq_ptr); fsp 302 drivers/scsi/libfc/fc_fcp.c fsp->seq_ptr = NULL; fsp 305 drivers/scsi/libfc/fc_fcp.c fsp->state &= ~FC_SRB_ABORT_PENDING; fsp 306 drivers/scsi/libfc/fc_fcp.c fsp->io_status = 0; fsp 307 drivers/scsi/libfc/fc_fcp.c fsp->status_code = status_code; fsp 308 drivers/scsi/libfc/fc_fcp.c fc_fcp_complete_locked(fsp); fsp 316 drivers/scsi/libfc/fc_fcp.c void fc_fcp_ddp_setup(struct fc_fcp_pkt *fsp, u16 xid) fsp 320 drivers/scsi/libfc/fc_fcp.c lport = fsp->lp; fsp 321 drivers/scsi/libfc/fc_fcp.c if ((fsp->req_flags & FC_SRB_READ) && fsp 323 drivers/scsi/libfc/fc_fcp.c if (lport->tt.ddp_setup(lport, xid, scsi_sglist(fsp->cmd), fsp 324 drivers/scsi/libfc/fc_fcp.c scsi_sg_count(fsp->cmd))) fsp 325 drivers/scsi/libfc/fc_fcp.c fsp->xfer_ddp = xid; fsp 334 drivers/scsi/libfc/fc_fcp.c void fc_fcp_ddp_done(struct fc_fcp_pkt *fsp) fsp 338 drivers/scsi/libfc/fc_fcp.c if (!fsp) fsp 341 drivers/scsi/libfc/fc_fcp.c if (fsp->xfer_ddp == FC_XID_UNKNOWN) fsp 344 drivers/scsi/libfc/fc_fcp.c lport = fsp->lp; fsp 346 drivers/scsi/libfc/fc_fcp.c fsp->xfer_len = lport->tt.ddp_done(lport, fsp->xfer_ddp); fsp 347 drivers/scsi/libfc/fc_fcp.c fsp->xfer_ddp = FC_XID_UNKNOWN; fsp 458 drivers/scsi/libfc/fc_fcp.c static inline unsigned int get_fsp_rec_tov(struct fc_fcp_pkt *fsp) fsp 460 drivers/scsi/libfc/fc_fcp.c struct fc_rport_libfc_priv *rpriv = fsp->rport->dd_data; fsp 473 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_recv_data(struct fc_fcp_pkt *fsp, struct fc_frame *fp) fsp 475 drivers/scsi/libfc/fc_fcp.c struct scsi_cmnd *sc = fsp->cmd; fsp 476 drivers/scsi/libfc/fc_fcp.c struct fc_lport *lport = fsp->lp; fsp 502 drivers/scsi/libfc/fc_fcp.c if (fsp->xfer_ddp != FC_XID_UNKNOWN) { fsp 503 drivers/scsi/libfc/fc_fcp.c fc_fcp_ddp_done(fsp); fsp 504 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "DDP I/O in fc_fcp_recv_data set ERROR\n"); fsp 508 drivers/scsi/libfc/fc_fcp.c if (offset + len > fsp->data_len) { fsp 513 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "data received past end. len %zx offset %zx " fsp 514 drivers/scsi/libfc/fc_fcp.c "data_len %x\n", len, offset, fsp->data_len); fsp 520 drivers/scsi/libfc/fc_fcp.c if (offset != fsp->xfer_len) fsp 521 drivers/scsi/libfc/fc_fcp.c fsp->state |= FC_SRB_DISCONTIG; fsp 554 drivers/scsi/libfc/fc_fcp.c if (fsp->state & FC_SRB_DISCONTIG) { fsp 562 drivers/scsi/libfc/fc_fcp.c if (fsp->xfer_contig_end == start_offset) fsp 563 drivers/scsi/libfc/fc_fcp.c fsp->xfer_contig_end += copy_len; fsp 564 drivers/scsi/libfc/fc_fcp.c fsp->xfer_len += copy_len; fsp 570 drivers/scsi/libfc/fc_fcp.c if (unlikely(fsp->state & FC_SRB_RCV_STATUS) && fsp 571 drivers/scsi/libfc/fc_fcp.c fsp->xfer_len == fsp->data_len - fsp->scsi_resid) { fsp 572 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG( fsp, "complete out-of-order sequence\n" ); fsp 573 drivers/scsi/libfc/fc_fcp.c fc_fcp_complete_locked(fsp); fsp 577 drivers/scsi/libfc/fc_fcp.c fc_fcp_recovery(fsp, host_bcode); fsp 593 drivers/scsi/libfc/fc_fcp.c static int fc_fcp_send_data(struct fc_fcp_pkt *fsp, struct fc_seq *seq, fsp 600 drivers/scsi/libfc/fc_fcp.c struct fc_lport *lport = fsp->lp; fsp 615 drivers/scsi/libfc/fc_fcp.c if (unlikely(offset + seq_blen > fsp->data_len)) { fsp 617 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "xfer-ready past end. seq_blen %zx " fsp 619 drivers/scsi/libfc/fc_fcp.c fc_fcp_send_abort(fsp); fsp 621 drivers/scsi/libfc/fc_fcp.c } else if (offset != fsp->xfer_len) { fsp 623 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "xfer-ready non-contiguous. " fsp 632 drivers/scsi/libfc/fc_fcp.c t_blen = fsp->max_payload; fsp 635 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "fsp=%p:lso:blen=%zx lso_max=0x%x t_blen=%zx\n", fsp 636 drivers/scsi/libfc/fc_fcp.c fsp, seq_blen, lport->lso_max, t_blen); fsp 641 drivers/scsi/libfc/fc_fcp.c sc = fsp->cmd; fsp 674 drivers/scsi/libfc/fc_fcp.c fr_max_payload(fp) = fsp->max_payload; fsp 731 drivers/scsi/libfc/fc_fcp.c fsp->xfer_len += seq_blen; /* premature count? */ fsp 740 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_abts_resp(struct fc_fcp_pkt *fsp, struct fc_frame *fp) fsp 765 drivers/scsi/libfc/fc_fcp.c fc_fcp_abort_done(fsp); fsp 779 drivers/scsi/libfc/fc_fcp.c struct fc_fcp_pkt *fsp = (struct fc_fcp_pkt *)arg; fsp 780 drivers/scsi/libfc/fc_fcp.c struct fc_lport *lport = fsp->lp; fsp 787 drivers/scsi/libfc/fc_fcp.c fc_fcp_error(fsp, fp); fsp 795 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "lport state %d, ignoring r_ctl %x\n", fsp 799 drivers/scsi/libfc/fc_fcp.c if (fc_fcp_lock_pkt(fsp)) fsp 803 drivers/scsi/libfc/fc_fcp.c fc_fcp_abts_resp(fsp, fp); fsp 807 drivers/scsi/libfc/fc_fcp.c if (fsp->state & (FC_SRB_ABORTED | FC_SRB_ABORT_PENDING)) { fsp 808 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "command aborted, ignoring r_ctl %x\n", r_ctl); fsp 821 drivers/scsi/libfc/fc_fcp.c rc = fc_fcp_send_data(fsp, seq, fsp 825 drivers/scsi/libfc/fc_fcp.c seq->rec_data = fsp->xfer_len; fsp 832 drivers/scsi/libfc/fc_fcp.c fc_fcp_recv_data(fsp, fp); fsp 833 drivers/scsi/libfc/fc_fcp.c seq->rec_data = fsp->xfer_contig_end; fsp 837 drivers/scsi/libfc/fc_fcp.c fc_fcp_resp(fsp, fp); fsp 839 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "unexpected frame. r_ctl %x\n", r_ctl); fsp 842 drivers/scsi/libfc/fc_fcp.c fc_fcp_unlock_pkt(fsp); fsp 852 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_resp(struct fc_fcp_pkt *fsp, struct fc_frame *fp) fsp 870 drivers/scsi/libfc/fc_fcp.c fsp->cdb_status = fc_rp->fr_status; fsp 872 drivers/scsi/libfc/fc_fcp.c fsp->scsi_comp_flags = flags; fsp 873 drivers/scsi/libfc/fc_fcp.c expected_len = fsp->data_len; fsp 876 drivers/scsi/libfc/fc_fcp.c fc_fcp_ddp_done(fsp); fsp 889 drivers/scsi/libfc/fc_fcp.c if (fsp->wait_for_comp) { fsp 891 drivers/scsi/libfc/fc_fcp.c fsp->cdb_status = fc_rp_info->rsp_code; fsp 892 drivers/scsi/libfc/fc_fcp.c complete(&fsp->tm_done); fsp 904 drivers/scsi/libfc/fc_fcp.c memcpy(fsp->cmd->sense_buffer, fsp 912 drivers/scsi/libfc/fc_fcp.c fsp->scsi_resid = ntohl(rp_ex->fr_resid); fsp 923 drivers/scsi/libfc/fc_fcp.c (scsi_bufflen(fsp->cmd) - fsp 924 drivers/scsi/libfc/fc_fcp.c fsp->scsi_resid) < fsp->cmd->underflow) fsp 926 drivers/scsi/libfc/fc_fcp.c expected_len -= fsp->scsi_resid; fsp 928 drivers/scsi/libfc/fc_fcp.c fsp->status_code = FC_ERROR; fsp 932 drivers/scsi/libfc/fc_fcp.c fsp->state |= FC_SRB_RCV_STATUS; fsp 937 drivers/scsi/libfc/fc_fcp.c if (unlikely(fsp->cdb_status == SAM_STAT_GOOD && fsp 938 drivers/scsi/libfc/fc_fcp.c fsp->xfer_len != expected_len)) { fsp 939 drivers/scsi/libfc/fc_fcp.c if (fsp->xfer_len < expected_len) { fsp 945 drivers/scsi/libfc/fc_fcp.c if (fsp->lp->qfull) { fsp 946 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "tgt %6.6x queue busy retry\n", fsp 947 drivers/scsi/libfc/fc_fcp.c fsp->rport->port_id); fsp 950 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "tgt %6.6x xfer len %zx data underrun " fsp 952 drivers/scsi/libfc/fc_fcp.c fsp->rport->port_id, fsp 953 drivers/scsi/libfc/fc_fcp.c fsp->xfer_len, expected_len, fsp->data_len); fsp 954 drivers/scsi/libfc/fc_fcp.c fc_fcp_timer_set(fsp, get_fsp_rec_tov(fsp)); fsp 957 drivers/scsi/libfc/fc_fcp.c fsp->status_code = FC_DATA_OVRRUN; fsp 958 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "tgt %6.6x xfer len %zx greater than expected, " fsp 960 drivers/scsi/libfc/fc_fcp.c fsp->rport->port_id, fsp 961 drivers/scsi/libfc/fc_fcp.c fsp->xfer_len, expected_len, fsp->data_len); fsp 963 drivers/scsi/libfc/fc_fcp.c fc_fcp_complete_locked(fsp); fsp 967 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "short FCP response. flags 0x%x len %u respl %u " fsp 970 drivers/scsi/libfc/fc_fcp.c fsp->status_code = FC_ERROR; fsp 971 drivers/scsi/libfc/fc_fcp.c fc_fcp_complete_locked(fsp); fsp 982 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_complete_locked(struct fc_fcp_pkt *fsp) fsp 984 drivers/scsi/libfc/fc_fcp.c struct fc_lport *lport = fsp->lp; fsp 989 drivers/scsi/libfc/fc_fcp.c if (fsp->state & FC_SRB_ABORT_PENDING) fsp 992 drivers/scsi/libfc/fc_fcp.c if (fsp->state & FC_SRB_ABORTED) { fsp 993 drivers/scsi/libfc/fc_fcp.c if (!fsp->status_code) fsp 994 drivers/scsi/libfc/fc_fcp.c fsp->status_code = FC_CMD_ABORTED; fsp 1000 drivers/scsi/libfc/fc_fcp.c if (fsp->cdb_status == SAM_STAT_GOOD && fsp 1001 drivers/scsi/libfc/fc_fcp.c fsp->xfer_len < fsp->data_len && !fsp->io_status && fsp 1002 drivers/scsi/libfc/fc_fcp.c (!(fsp->scsi_comp_flags & FCP_RESID_UNDER) || fsp 1003 drivers/scsi/libfc/fc_fcp.c fsp->xfer_len < fsp->data_len - fsp->scsi_resid)) { fsp 1004 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "data underrun, xfer %zx data %x\n", fsp 1005 drivers/scsi/libfc/fc_fcp.c fsp->xfer_len, fsp->data_len); fsp 1006 drivers/scsi/libfc/fc_fcp.c fsp->status_code = FC_DATA_UNDRUN; fsp 1010 drivers/scsi/libfc/fc_fcp.c seq = fsp->seq_ptr; fsp 1012 drivers/scsi/libfc/fc_fcp.c fsp->seq_ptr = NULL; fsp 1013 drivers/scsi/libfc/fc_fcp.c if (unlikely(fsp->scsi_comp_flags & FCP_CONF_REQ)) { fsp 1018 drivers/scsi/libfc/fc_fcp.c conf_frame = fc_fcp_frame_alloc(fsp->lp, 0); fsp 1036 drivers/scsi/libfc/fc_fcp.c if (fsp->cmd) fsp 1037 drivers/scsi/libfc/fc_fcp.c fc_io_compl(fsp); fsp 1045 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_cleanup_cmd(struct fc_fcp_pkt *fsp, int error) fsp 1047 drivers/scsi/libfc/fc_fcp.c if (fsp->seq_ptr) { fsp 1048 drivers/scsi/libfc/fc_fcp.c fc_exch_done(fsp->seq_ptr); fsp 1049 drivers/scsi/libfc/fc_fcp.c fsp->seq_ptr = NULL; fsp 1051 drivers/scsi/libfc/fc_fcp.c fsp->status_code = error; fsp 1067 drivers/scsi/libfc/fc_fcp.c struct fc_fcp_pkt *fsp; fsp 1073 drivers/scsi/libfc/fc_fcp.c list_for_each_entry(fsp, &si->scsi_pkt_queue, list) { fsp 1074 drivers/scsi/libfc/fc_fcp.c sc_cmd = fsp->cmd; fsp 1081 drivers/scsi/libfc/fc_fcp.c fc_fcp_pkt_hold(fsp); fsp 1084 drivers/scsi/libfc/fc_fcp.c spin_lock_bh(&fsp->scsi_pkt_lock); fsp 1085 drivers/scsi/libfc/fc_fcp.c if (!(fsp->state & FC_SRB_COMPL)) { fsp 1086 drivers/scsi/libfc/fc_fcp.c fsp->state |= FC_SRB_COMPL; fsp 1096 drivers/scsi/libfc/fc_fcp.c spin_unlock_bh(&fsp->scsi_pkt_lock); fsp 1098 drivers/scsi/libfc/fc_fcp.c fc_fcp_cleanup_cmd(fsp, error); fsp 1100 drivers/scsi/libfc/fc_fcp.c spin_lock_bh(&fsp->scsi_pkt_lock); fsp 1101 drivers/scsi/libfc/fc_fcp.c fc_io_compl(fsp); fsp 1103 drivers/scsi/libfc/fc_fcp.c spin_unlock_bh(&fsp->scsi_pkt_lock); fsp 1105 drivers/scsi/libfc/fc_fcp.c fc_fcp_pkt_release(fsp); fsp 1133 drivers/scsi/libfc/fc_fcp.c static int fc_fcp_pkt_send(struct fc_lport *lport, struct fc_fcp_pkt *fsp) fsp 1139 drivers/scsi/libfc/fc_fcp.c fsp->cmd->SCp.ptr = (char *)fsp; fsp 1140 drivers/scsi/libfc/fc_fcp.c fsp->cdb_cmd.fc_dl = htonl(fsp->data_len); fsp 1141 drivers/scsi/libfc/fc_fcp.c fsp->cdb_cmd.fc_flags = fsp->req_flags & ~FCP_CFL_LEN_MASK; fsp 1143 drivers/scsi/libfc/fc_fcp.c int_to_scsilun(fsp->cmd->device->lun, &fsp->cdb_cmd.fc_lun); fsp 1144 drivers/scsi/libfc/fc_fcp.c memcpy(fsp->cdb_cmd.fc_cdb, fsp->cmd->cmnd, fsp->cmd->cmd_len); fsp 1147 drivers/scsi/libfc/fc_fcp.c list_add_tail(&fsp->list, &si->scsi_pkt_queue); fsp 1149 drivers/scsi/libfc/fc_fcp.c rc = lport->tt.fcp_cmd_send(lport, fsp, fc_fcp_recv); fsp 1152 drivers/scsi/libfc/fc_fcp.c fsp->cmd->SCp.ptr = NULL; fsp 1153 drivers/scsi/libfc/fc_fcp.c list_del(&fsp->list); fsp 1166 drivers/scsi/libfc/fc_fcp.c static int fc_fcp_cmd_send(struct fc_lport *lport, struct fc_fcp_pkt *fsp, fsp 1175 drivers/scsi/libfc/fc_fcp.c const size_t len = sizeof(fsp->cdb_cmd); fsp 1178 drivers/scsi/libfc/fc_fcp.c if (fc_fcp_lock_pkt(fsp)) fsp 1181 drivers/scsi/libfc/fc_fcp.c fp = fc_fcp_frame_alloc(lport, sizeof(fsp->cdb_cmd)); fsp 1187 drivers/scsi/libfc/fc_fcp.c memcpy(fc_frame_payload_get(fp, len), &fsp->cdb_cmd, len); fsp 1188 drivers/scsi/libfc/fc_fcp.c fr_fsp(fp) = fsp; fsp 1189 drivers/scsi/libfc/fc_fcp.c rport = fsp->rport; fsp 1190 drivers/scsi/libfc/fc_fcp.c fsp->max_payload = rport->maxframe_size; fsp 1197 drivers/scsi/libfc/fc_fcp.c seq = fc_exch_seq_send(lport, fp, resp, fc_fcp_pkt_destroy, fsp, 0); fsp 1202 drivers/scsi/libfc/fc_fcp.c fsp->seq_ptr = seq; fsp 1203 drivers/scsi/libfc/fc_fcp.c fc_fcp_pkt_hold(fsp); /* hold for fc_fcp_pkt_destroy */ fsp 1205 drivers/scsi/libfc/fc_fcp.c fsp->timer.function = fc_fcp_timeout; fsp 1207 drivers/scsi/libfc/fc_fcp.c fc_fcp_timer_set(fsp, get_fsp_rec_tov(fsp)); fsp 1210 drivers/scsi/libfc/fc_fcp.c fc_fcp_unlock_pkt(fsp); fsp 1219 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_error(struct fc_fcp_pkt *fsp, struct fc_frame *fp) fsp 1223 drivers/scsi/libfc/fc_fcp.c if (fc_fcp_lock_pkt(fsp)) fsp 1227 drivers/scsi/libfc/fc_fcp.c fc_fcp_retry_cmd(fsp, FC_ERROR); fsp 1235 drivers/scsi/libfc/fc_fcp.c fsp->state &= ~FC_SRB_ABORT_PENDING; fsp 1236 drivers/scsi/libfc/fc_fcp.c fsp->status_code = FC_CMD_PLOGO; fsp 1237 drivers/scsi/libfc/fc_fcp.c fc_fcp_complete_locked(fsp); fsp 1239 drivers/scsi/libfc/fc_fcp.c fc_fcp_unlock_pkt(fsp); fsp 1248 drivers/scsi/libfc/fc_fcp.c static int fc_fcp_pkt_abort(struct fc_fcp_pkt *fsp) fsp 1253 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "pkt abort state %x\n", fsp->state); fsp 1254 drivers/scsi/libfc/fc_fcp.c if (fc_fcp_send_abort(fsp)) { fsp 1255 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "failed to send abort\n"); fsp 1259 drivers/scsi/libfc/fc_fcp.c if (fsp->state & FC_SRB_ABORTED) { fsp 1260 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "target abort cmd completed\n"); fsp 1264 drivers/scsi/libfc/fc_fcp.c init_completion(&fsp->tm_done); fsp 1265 drivers/scsi/libfc/fc_fcp.c fsp->wait_for_comp = 1; fsp 1267 drivers/scsi/libfc/fc_fcp.c spin_unlock_bh(&fsp->scsi_pkt_lock); fsp 1268 drivers/scsi/libfc/fc_fcp.c ticks_left = wait_for_completion_timeout(&fsp->tm_done, fsp 1270 drivers/scsi/libfc/fc_fcp.c spin_lock_bh(&fsp->scsi_pkt_lock); fsp 1271 drivers/scsi/libfc/fc_fcp.c fsp->wait_for_comp = 0; fsp 1274 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "target abort cmd failed\n"); fsp 1275 drivers/scsi/libfc/fc_fcp.c } else if (fsp->state & FC_SRB_ABORTED) { fsp 1276 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "target abort cmd passed\n"); fsp 1278 drivers/scsi/libfc/fc_fcp.c fc_fcp_complete_locked(fsp); fsp 1290 drivers/scsi/libfc/fc_fcp.c struct fc_fcp_pkt *fsp = from_timer(fsp, t, timer); fsp 1291 drivers/scsi/libfc/fc_fcp.c struct fc_lport *lport = fsp->lp; fsp 1293 drivers/scsi/libfc/fc_fcp.c if (lport->tt.fcp_cmd_send(lport, fsp, fc_tm_done)) { fsp 1294 drivers/scsi/libfc/fc_fcp.c if (fsp->recov_retry++ >= FC_MAX_RECOV_RETRY) fsp 1296 drivers/scsi/libfc/fc_fcp.c if (fc_fcp_lock_pkt(fsp)) fsp 1298 drivers/scsi/libfc/fc_fcp.c fsp->timer.function = fc_lun_reset_send; fsp 1299 drivers/scsi/libfc/fc_fcp.c fc_fcp_timer_set(fsp, get_fsp_rec_tov(fsp)); fsp 1300 drivers/scsi/libfc/fc_fcp.c fc_fcp_unlock_pkt(fsp); fsp 1312 drivers/scsi/libfc/fc_fcp.c static int fc_lun_reset(struct fc_lport *lport, struct fc_fcp_pkt *fsp, fsp 1317 drivers/scsi/libfc/fc_fcp.c fsp->cdb_cmd.fc_dl = htonl(fsp->data_len); fsp 1318 drivers/scsi/libfc/fc_fcp.c fsp->cdb_cmd.fc_tm_flags = FCP_TMF_LUN_RESET; fsp 1319 drivers/scsi/libfc/fc_fcp.c int_to_scsilun(lun, &fsp->cdb_cmd.fc_lun); fsp 1321 drivers/scsi/libfc/fc_fcp.c fsp->wait_for_comp = 1; fsp 1322 drivers/scsi/libfc/fc_fcp.c init_completion(&fsp->tm_done); fsp 1324 drivers/scsi/libfc/fc_fcp.c fc_lun_reset_send(&fsp->timer); fsp 1330 drivers/scsi/libfc/fc_fcp.c rc = wait_for_completion_timeout(&fsp->tm_done, FC_SCSI_TM_TOV); fsp 1332 drivers/scsi/libfc/fc_fcp.c spin_lock_bh(&fsp->scsi_pkt_lock); fsp 1333 drivers/scsi/libfc/fc_fcp.c fsp->state |= FC_SRB_COMPL; fsp 1334 drivers/scsi/libfc/fc_fcp.c spin_unlock_bh(&fsp->scsi_pkt_lock); fsp 1336 drivers/scsi/libfc/fc_fcp.c del_timer_sync(&fsp->timer); fsp 1338 drivers/scsi/libfc/fc_fcp.c spin_lock_bh(&fsp->scsi_pkt_lock); fsp 1339 drivers/scsi/libfc/fc_fcp.c if (fsp->seq_ptr) { fsp 1340 drivers/scsi/libfc/fc_fcp.c fc_exch_done(fsp->seq_ptr); fsp 1341 drivers/scsi/libfc/fc_fcp.c fsp->seq_ptr = NULL; fsp 1343 drivers/scsi/libfc/fc_fcp.c fsp->wait_for_comp = 0; fsp 1344 drivers/scsi/libfc/fc_fcp.c spin_unlock_bh(&fsp->scsi_pkt_lock); fsp 1352 drivers/scsi/libfc/fc_fcp.c if (fsp->cdb_status != FCP_TMF_CMPL) fsp 1368 drivers/scsi/libfc/fc_fcp.c struct fc_fcp_pkt *fsp = arg; fsp 1381 drivers/scsi/libfc/fc_fcp.c if (fc_fcp_lock_pkt(fsp)) fsp 1387 drivers/scsi/libfc/fc_fcp.c if (!fsp->seq_ptr || !fsp->wait_for_comp) fsp 1392 drivers/scsi/libfc/fc_fcp.c fc_fcp_resp(fsp, fp); fsp 1393 drivers/scsi/libfc/fc_fcp.c fsp->seq_ptr = NULL; fsp 1396 drivers/scsi/libfc/fc_fcp.c fc_fcp_unlock_pkt(fsp); fsp 1423 drivers/scsi/libfc/fc_fcp.c struct fc_fcp_pkt *fsp = from_timer(fsp, t, timer); fsp 1424 drivers/scsi/libfc/fc_fcp.c struct fc_rport *rport = fsp->rport; fsp 1427 drivers/scsi/libfc/fc_fcp.c if (fc_fcp_lock_pkt(fsp)) fsp 1430 drivers/scsi/libfc/fc_fcp.c if (fsp->cdb_cmd.fc_tm_flags) fsp 1433 drivers/scsi/libfc/fc_fcp.c if (fsp->lp->qfull) { fsp 1434 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "fcp timeout, resetting timer delay %d\n", fsp 1435 drivers/scsi/libfc/fc_fcp.c fsp->timer_delay); fsp 1436 drivers/scsi/libfc/fc_fcp.c fsp->timer.function = fc_fcp_timeout; fsp 1437 drivers/scsi/libfc/fc_fcp.c fc_fcp_timer_set(fsp, fsp->timer_delay); fsp 1440 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "fcp timeout, delay %d flags %x state %x\n", fsp 1441 drivers/scsi/libfc/fc_fcp.c fsp->timer_delay, rpriv->flags, fsp->state); fsp 1442 drivers/scsi/libfc/fc_fcp.c fsp->state |= FC_SRB_FCP_PROCESSING_TMO; fsp 1445 drivers/scsi/libfc/fc_fcp.c fc_fcp_rec(fsp); fsp 1446 drivers/scsi/libfc/fc_fcp.c else if (fsp->state & FC_SRB_RCV_STATUS) fsp 1447 drivers/scsi/libfc/fc_fcp.c fc_fcp_complete_locked(fsp); fsp 1449 drivers/scsi/libfc/fc_fcp.c fc_fcp_recovery(fsp, FC_TIMED_OUT); fsp 1450 drivers/scsi/libfc/fc_fcp.c fsp->state &= ~FC_SRB_FCP_PROCESSING_TMO; fsp 1452 drivers/scsi/libfc/fc_fcp.c fc_fcp_unlock_pkt(fsp); fsp 1459 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_rec(struct fc_fcp_pkt *fsp) fsp 1466 drivers/scsi/libfc/fc_fcp.c lport = fsp->lp; fsp 1467 drivers/scsi/libfc/fc_fcp.c rport = fsp->rport; fsp 1469 drivers/scsi/libfc/fc_fcp.c if (!fsp->seq_ptr || rpriv->rp_state != RPORT_ST_READY) { fsp 1470 drivers/scsi/libfc/fc_fcp.c fsp->status_code = FC_HRD_ERROR; fsp 1471 drivers/scsi/libfc/fc_fcp.c fsp->io_status = 0; fsp 1472 drivers/scsi/libfc/fc_fcp.c fc_fcp_complete_locked(fsp); fsp 1480 drivers/scsi/libfc/fc_fcp.c fr_seq(fp) = fsp->seq_ptr; fsp 1485 drivers/scsi/libfc/fc_fcp.c fc_fcp_rec_resp, fsp, fsp 1487 drivers/scsi/libfc/fc_fcp.c fc_fcp_pkt_hold(fsp); /* hold while REC outstanding */ fsp 1491 drivers/scsi/libfc/fc_fcp.c if (fsp->recov_retry++ < FC_MAX_RECOV_RETRY) fsp 1492 drivers/scsi/libfc/fc_fcp.c fc_fcp_timer_set(fsp, get_fsp_rec_tov(fsp)); fsp 1494 drivers/scsi/libfc/fc_fcp.c fc_fcp_recovery(fsp, FC_TIMED_OUT); fsp 1510 drivers/scsi/libfc/fc_fcp.c struct fc_fcp_pkt *fsp = (struct fc_fcp_pkt *)arg; fsp 1521 drivers/scsi/libfc/fc_fcp.c fc_fcp_rec_error(fsp, fp); fsp 1525 drivers/scsi/libfc/fc_fcp.c if (fc_fcp_lock_pkt(fsp)) fsp 1528 drivers/scsi/libfc/fc_fcp.c fsp->recov_retry = 0; fsp 1534 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, fsp 1536 drivers/scsi/libfc/fc_fcp.c fsp->rport->port_id, rjt->er_reason, fsp 1540 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "device does not support REC\n"); fsp 1541 drivers/scsi/libfc/fc_fcp.c rpriv = fsp->rport->dd_data; fsp 1551 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "device %x REC reject %d/%d\n", fsp 1552 drivers/scsi/libfc/fc_fcp.c fsp->rport->port_id, rjt->er_reason, fsp 1561 drivers/scsi/libfc/fc_fcp.c struct fc_exch *ep = fc_seq_exch(fsp->seq_ptr); fsp 1563 drivers/scsi/libfc/fc_fcp.c fsp->state |= FC_SRB_ABORTED; fsp 1564 drivers/scsi/libfc/fc_fcp.c fc_fcp_retry_cmd(fsp, FC_TRANS_RESET); fsp 1567 drivers/scsi/libfc/fc_fcp.c fc_fcp_recovery(fsp, FC_TRANS_RESET); fsp 1571 drivers/scsi/libfc/fc_fcp.c if (fsp->state & FC_SRB_ABORTED) fsp 1574 drivers/scsi/libfc/fc_fcp.c data_dir = fsp->cmd->sc_data_direction; fsp 1597 drivers/scsi/libfc/fc_fcp.c } else if (fsp->xfer_contig_end == offset) { fsp 1600 drivers/scsi/libfc/fc_fcp.c offset = fsp->xfer_contig_end; fsp 1603 drivers/scsi/libfc/fc_fcp.c fc_fcp_srr(fsp, r_ctl, offset); fsp 1609 drivers/scsi/libfc/fc_fcp.c fc_fcp_timer_set(fsp, get_fsp_rec_tov(fsp)); fsp 1630 drivers/scsi/libfc/fc_fcp.c if (offset < fsp->data_len) fsp 1632 drivers/scsi/libfc/fc_fcp.c } else if (offset == fsp->xfer_contig_end) { fsp 1634 drivers/scsi/libfc/fc_fcp.c } else if (fsp->xfer_contig_end < offset) { fsp 1635 drivers/scsi/libfc/fc_fcp.c offset = fsp->xfer_contig_end; fsp 1637 drivers/scsi/libfc/fc_fcp.c fc_fcp_srr(fsp, r_ctl, offset); fsp 1641 drivers/scsi/libfc/fc_fcp.c fc_fcp_unlock_pkt(fsp); fsp 1643 drivers/scsi/libfc/fc_fcp.c fc_fcp_pkt_release(fsp); /* drop hold for outstanding REC */ fsp 1652 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_rec_error(struct fc_fcp_pkt *fsp, struct fc_frame *fp) fsp 1656 drivers/scsi/libfc/fc_fcp.c if (fc_fcp_lock_pkt(fsp)) fsp 1661 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "REC %p fid %6.6x exchange closed\n", fsp 1662 drivers/scsi/libfc/fc_fcp.c fsp, fsp->rport->port_id); fsp 1663 drivers/scsi/libfc/fc_fcp.c fc_fcp_retry_cmd(fsp, FC_ERROR); fsp 1667 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "REC %p fid %6.6x error unexpected error %d\n", fsp 1668 drivers/scsi/libfc/fc_fcp.c fsp, fsp->rport->port_id, error); fsp 1669 drivers/scsi/libfc/fc_fcp.c fsp->status_code = FC_CMD_PLOGO; fsp 1677 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "REC %p fid %6.6x exchange timeout retry %d/%d\n", fsp 1678 drivers/scsi/libfc/fc_fcp.c fsp, fsp->rport->port_id, fsp->recov_retry, fsp 1680 drivers/scsi/libfc/fc_fcp.c if (fsp->recov_retry++ < FC_MAX_RECOV_RETRY) fsp 1681 drivers/scsi/libfc/fc_fcp.c fc_fcp_rec(fsp); fsp 1683 drivers/scsi/libfc/fc_fcp.c fc_fcp_recovery(fsp, FC_ERROR); fsp 1686 drivers/scsi/libfc/fc_fcp.c fc_fcp_unlock_pkt(fsp); fsp 1688 drivers/scsi/libfc/fc_fcp.c fc_fcp_pkt_release(fsp); /* drop hold for outstanding REC */ fsp 1695 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_recovery(struct fc_fcp_pkt *fsp, u8 code) fsp 1697 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "start recovery code %x\n", code); fsp 1698 drivers/scsi/libfc/fc_fcp.c fsp->status_code = code; fsp 1699 drivers/scsi/libfc/fc_fcp.c fsp->cdb_status = 0; fsp 1700 drivers/scsi/libfc/fc_fcp.c fsp->io_status = 0; fsp 1705 drivers/scsi/libfc/fc_fcp.c fc_fcp_send_abort(fsp); fsp 1715 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_srr(struct fc_fcp_pkt *fsp, enum fc_rctl r_ctl, u32 offset) fsp 1717 drivers/scsi/libfc/fc_fcp.c struct fc_lport *lport = fsp->lp; fsp 1720 drivers/scsi/libfc/fc_fcp.c struct fc_exch *ep = fc_seq_exch(fsp->seq_ptr); fsp 1725 drivers/scsi/libfc/fc_fcp.c rport = fsp->rport; fsp 1749 drivers/scsi/libfc/fc_fcp.c fsp, get_fsp_rec_tov(fsp)); fsp 1753 drivers/scsi/libfc/fc_fcp.c fsp->recov_seq = seq; fsp 1754 drivers/scsi/libfc/fc_fcp.c fsp->xfer_len = offset; fsp 1755 drivers/scsi/libfc/fc_fcp.c fsp->xfer_contig_end = offset; fsp 1756 drivers/scsi/libfc/fc_fcp.c fsp->state &= ~FC_SRB_RCV_STATUS; fsp 1757 drivers/scsi/libfc/fc_fcp.c fc_fcp_pkt_hold(fsp); /* hold for outstanding SRR */ fsp 1760 drivers/scsi/libfc/fc_fcp.c fc_fcp_retry_cmd(fsp, FC_TRANS_RESET); fsp 1771 drivers/scsi/libfc/fc_fcp.c struct fc_fcp_pkt *fsp = arg; fsp 1775 drivers/scsi/libfc/fc_fcp.c fc_fcp_srr_error(fsp, fp); fsp 1779 drivers/scsi/libfc/fc_fcp.c if (fc_fcp_lock_pkt(fsp)) fsp 1791 drivers/scsi/libfc/fc_fcp.c fc_fcp_unlock_pkt(fsp); fsp 1797 drivers/scsi/libfc/fc_fcp.c fsp->recov_retry = 0; fsp 1798 drivers/scsi/libfc/fc_fcp.c fc_fcp_timer_set(fsp, get_fsp_rec_tov(fsp)); fsp 1802 drivers/scsi/libfc/fc_fcp.c fc_fcp_recovery(fsp, FC_ERROR); fsp 1805 drivers/scsi/libfc/fc_fcp.c fc_fcp_unlock_pkt(fsp); fsp 1816 drivers/scsi/libfc/fc_fcp.c static void fc_fcp_srr_error(struct fc_fcp_pkt *fsp, struct fc_frame *fp) fsp 1818 drivers/scsi/libfc/fc_fcp.c if (fc_fcp_lock_pkt(fsp)) fsp 1822 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "SRR timeout, retries %d\n", fsp->recov_retry); fsp 1823 drivers/scsi/libfc/fc_fcp.c if (fsp->recov_retry++ < FC_MAX_RECOV_RETRY) fsp 1824 drivers/scsi/libfc/fc_fcp.c fc_fcp_rec(fsp); fsp 1826 drivers/scsi/libfc/fc_fcp.c fc_fcp_recovery(fsp, FC_TIMED_OUT); fsp 1829 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "SRR error, exchange closed\n"); fsp 1832 drivers/scsi/libfc/fc_fcp.c fc_fcp_retry_cmd(fsp, FC_ERROR); fsp 1835 drivers/scsi/libfc/fc_fcp.c fc_fcp_unlock_pkt(fsp); fsp 1837 drivers/scsi/libfc/fc_fcp.c fc_exch_done(fsp->recov_seq); fsp 1862 drivers/scsi/libfc/fc_fcp.c struct fc_fcp_pkt *fsp; fsp 1896 drivers/scsi/libfc/fc_fcp.c fsp = fc_fcp_pkt_alloc(lport, GFP_ATOMIC); fsp 1897 drivers/scsi/libfc/fc_fcp.c if (fsp == NULL) { fsp 1905 drivers/scsi/libfc/fc_fcp.c fsp->cmd = sc_cmd; /* save the cmd */ fsp 1906 drivers/scsi/libfc/fc_fcp.c fsp->rport = rport; /* set the remote port ptr */ fsp 1911 drivers/scsi/libfc/fc_fcp.c fsp->data_len = scsi_bufflen(sc_cmd); fsp 1912 drivers/scsi/libfc/fc_fcp.c fsp->xfer_len = 0; fsp 1919 drivers/scsi/libfc/fc_fcp.c fsp->req_flags = FC_SRB_READ; fsp 1921 drivers/scsi/libfc/fc_fcp.c stats->InputBytes += fsp->data_len; fsp 1923 drivers/scsi/libfc/fc_fcp.c fsp->req_flags = FC_SRB_WRITE; fsp 1925 drivers/scsi/libfc/fc_fcp.c stats->OutputBytes += fsp->data_len; fsp 1927 drivers/scsi/libfc/fc_fcp.c fsp->req_flags = 0; fsp 1937 drivers/scsi/libfc/fc_fcp.c rval = fc_fcp_pkt_send(lport, fsp); fsp 1939 drivers/scsi/libfc/fc_fcp.c fsp->state = FC_SRB_FREE; fsp 1940 drivers/scsi/libfc/fc_fcp.c fc_fcp_pkt_release(fsp); fsp 1955 drivers/scsi/libfc/fc_fcp.c static void fc_io_compl(struct fc_fcp_pkt *fsp) fsp 1963 drivers/scsi/libfc/fc_fcp.c fc_fcp_ddp_done(fsp); fsp 1965 drivers/scsi/libfc/fc_fcp.c fsp->state |= FC_SRB_COMPL; fsp 1966 drivers/scsi/libfc/fc_fcp.c if (!(fsp->state & FC_SRB_FCP_PROCESSING_TMO)) { fsp 1967 drivers/scsi/libfc/fc_fcp.c spin_unlock_bh(&fsp->scsi_pkt_lock); fsp 1968 drivers/scsi/libfc/fc_fcp.c del_timer_sync(&fsp->timer); fsp 1969 drivers/scsi/libfc/fc_fcp.c spin_lock_bh(&fsp->scsi_pkt_lock); fsp 1972 drivers/scsi/libfc/fc_fcp.c lport = fsp->lp; fsp 1982 drivers/scsi/libfc/fc_fcp.c sc_cmd = fsp->cmd; fsp 1983 drivers/scsi/libfc/fc_fcp.c CMD_SCSI_STATUS(sc_cmd) = fsp->cdb_status; fsp 1984 drivers/scsi/libfc/fc_fcp.c switch (fsp->status_code) { fsp 1986 drivers/scsi/libfc/fc_fcp.c if (fsp->cdb_status == 0) { fsp 1991 drivers/scsi/libfc/fc_fcp.c if (fsp->scsi_resid) fsp 1992 drivers/scsi/libfc/fc_fcp.c CMD_RESID_LEN(sc_cmd) = fsp->scsi_resid; fsp 1998 drivers/scsi/libfc/fc_fcp.c sc_cmd->result = (DID_OK << 16) | fsp->cdb_status; fsp 2002 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "Returning DID_ERROR to scsi-ml " fsp 2007 drivers/scsi/libfc/fc_fcp.c if ((fsp->cdb_status == 0) && !(fsp->req_flags & FC_SRB_READ)) { fsp 2012 drivers/scsi/libfc/fc_fcp.c if (fsp->state & FC_SRB_RCV_STATUS) { fsp 2015 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "Returning DID_ERROR to scsi-ml" fsp 2023 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "Returning DID_ERROR to scsi-ml " fsp 2025 drivers/scsi/libfc/fc_fcp.c CMD_RESID_LEN(sc_cmd) = fsp->scsi_resid; fsp 2026 drivers/scsi/libfc/fc_fcp.c sc_cmd->result = (DID_ERROR << 16) | fsp->cdb_status; fsp 2033 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "Returning DID_ERROR to scsi-ml " fsp 2035 drivers/scsi/libfc/fc_fcp.c sc_cmd->result = (DID_ERROR << 16) | fsp->cdb_status; fsp 2039 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "Returning DID_TIME_OUT to scsi-ml " fsp 2042 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "Returning DID_ERROR to scsi-ml " fsp 2046 drivers/scsi/libfc/fc_fcp.c sc_cmd->result |= fsp->io_status; fsp 2049 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "Returning DID_RESET to scsi-ml " fsp 2054 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "Returning DID_SOFT_ERROR to scsi-ml " fsp 2059 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "Returning DID_NO_CONNECT to scsi-ml " fsp 2064 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "Returning DID_PARITY to scsi-ml " fsp 2069 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "Returning DID_BUS_BUSY to scsi-ml " fsp 2071 drivers/scsi/libfc/fc_fcp.c sc_cmd->result = (DID_BUS_BUSY << 16) | fsp->io_status; fsp 2074 drivers/scsi/libfc/fc_fcp.c FC_FCP_DBG(fsp, "Returning DID_ERROR to scsi-ml " fsp 2080 drivers/scsi/libfc/fc_fcp.c if (lport->state != LPORT_ST_READY && fsp->status_code != FC_COMPLETE) fsp 2084 drivers/scsi/libfc/fc_fcp.c list_del(&fsp->list); fsp 2090 drivers/scsi/libfc/fc_fcp.c fc_fcp_pkt_release(fsp); fsp 2102 drivers/scsi/libfc/fc_fcp.c struct fc_fcp_pkt *fsp; fsp 2121 drivers/scsi/libfc/fc_fcp.c fsp = CMD_SP(sc_cmd); fsp 2122 drivers/scsi/libfc/fc_fcp.c if (!fsp) { fsp 2128 drivers/scsi/libfc/fc_fcp.c fc_fcp_pkt_hold(fsp); fsp 2131 drivers/scsi/libfc/fc_fcp.c if (fc_fcp_lock_pkt(fsp)) { fsp 2137 drivers/scsi/libfc/fc_fcp.c rc = fc_fcp_pkt_abort(fsp); fsp 2138 drivers/scsi/libfc/fc_fcp.c fc_fcp_unlock_pkt(fsp); fsp 2141 drivers/scsi/libfc/fc_fcp.c fc_fcp_pkt_release(fsp); fsp 2156 drivers/scsi/libfc/fc_fcp.c struct fc_fcp_pkt *fsp; fsp 2172 drivers/scsi/libfc/fc_fcp.c fsp = fc_fcp_pkt_alloc(lport, GFP_NOIO); fsp 2173 drivers/scsi/libfc/fc_fcp.c if (fsp == NULL) { fsp 2183 drivers/scsi/libfc/fc_fcp.c fsp->rport = rport; /* set the remote port ptr */ fsp 2188 drivers/scsi/libfc/fc_fcp.c rc = fc_lun_reset(lport, fsp, scmd_id(sc_cmd), sc_cmd->device->lun); fsp 2189 drivers/scsi/libfc/fc_fcp.c fsp->state = FC_SRB_FREE; fsp 2190 drivers/scsi/libfc/fc_fcp.c fc_fcp_pkt_release(fsp); fsp 98 drivers/scsi/libfc/fc_libfc.h void fc_fcp_ddp_setup(struct fc_fcp_pkt *fsp, u16 xid); fsp 99 drivers/scsi/libfc/fc_libfc.h void fc_fcp_ddp_done(struct fc_fcp_pkt *fsp); fsp 878 include/scsi/libfc.h static inline bool fc_fcp_is_read(const struct fc_fcp_pkt *fsp) fsp 880 include/scsi/libfc.h if (fsp && fsp->cmd) fsp 881 include/scsi/libfc.h return fsp->cmd->sc_data_direction == DMA_FROM_DEVICE; fsp 722 tools/perf/util/probe-finder.c struct find_scope_param *fsp = data; fsp 727 tools/perf/util/probe-finder.c if (fsp->file) { fsp 729 tools/perf/util/probe-finder.c if (!file || strcmp(fsp->file, file) != 0) fsp 733 tools/perf/util/probe-finder.c if (fsp->function) { fsp 734 tools/perf/util/probe-finder.c if (die_match_name(fn_die, fsp->function)) { fsp 735 tools/perf/util/probe-finder.c memcpy(fsp->die_mem, fn_die, sizeof(Dwarf_Die)); fsp 736 tools/perf/util/probe-finder.c fsp->found = true; fsp 742 tools/perf/util/probe-finder.c if (lno < fsp->line && fsp->diff > fsp->line - lno) { fsp 744 tools/perf/util/probe-finder.c fsp->diff = fsp->line - lno; fsp 745 tools/perf/util/probe-finder.c memcpy(fsp->die_mem, fn_die, sizeof(Dwarf_Die)); fsp 746 tools/perf/util/probe-finder.c fsp->found = true; fsp 755 tools/perf/util/probe-finder.c struct find_scope_param *fsp = data; fsp 757 tools/perf/util/probe-finder.c memcpy(fsp->die_mem, fn_die, sizeof(Dwarf_Die)); fsp 758 tools/perf/util/probe-finder.c fsp->found = true; fsp 765 tools/perf/util/probe-finder.c struct find_scope_param fsp = { fsp 776 tools/perf/util/probe-finder.c &fsp); fsp 777 tools/perf/util/probe-finder.c if (!ret && !fsp.found) fsp 779 tools/perf/util/probe-finder.c find_inner_scope_cb, &fsp); fsp 781 tools/perf/util/probe-finder.c return fsp.found ? die_mem : NULL;