| 226 | } |
| 227 | |
| 228 | static int |
| 229 | sfc_ft_ctx_detach(struct sfc_adapter *sa, uint32_t flow_mark) |
| 230 | { |
| 231 | struct sfc_ft_ctx *ft_ctx; |
| 232 | |
| 233 | SFC_ASSERT(sfc_adapter_is_locked(sa)); |
| 234 | |
| 235 | ft_ctx = sfc_ft_ctx_pick(sa, flow_mark); |
| 236 | if (ft_ctx == NULL) { |
| 237 | sfc_err(sa, "FT: invalid context"); |
| 238 | return EINVAL; |
| 239 | } |
| 240 | |
| 241 | if (ft_ctx->refcnt == 0) { |
| 242 | sfc_err(sa, "FT: inactive context (ID=%u)", ft_ctx->id); |
| 243 | return ENOENT; |
| 244 | } |
| 245 | |
| 246 | --(ft_ctx->refcnt); |
| 247 | |
| 248 | return 0; |
| 249 | } |
| 250 | |
| 251 | int |
| 252 | sfc_ft_decap_set(struct rte_eth_dev *dev, struct rte_flow_tunnel *tunnel, |
no test coverage detected