Lines Matching refs:rid

689 	struct efx_tc_recirc_id *rid, *old;
692 rid = kzalloc(sizeof(*rid), GFP_USER);
693 if (!rid)
695 rid->chain_index = chain_index;
700 rid->net_dev = net_dev;
702 &rid->linkage,
706 kfree(rid);
712 rid = old;
717 &rid->linkage,
719 kfree(rid);
722 rid->fw_id = rc;
723 refcount_set(&rid->ref, 1);
725 return rid;
728 static void efx_tc_put_recirc_id(struct efx_nic *efx, struct efx_tc_recirc_id *rid)
730 if (!refcount_dec_and_test(&rid->ref))
732 rhashtable_remove_fast(&efx->tc->recirc_ht, &rid->linkage,
734 ida_free(&efx->tc->recirc_ida, rid->fw_id);
735 kfree(rid);
744 if (rule->match.rid)
745 efx_tc_put_recirc_id(efx, rule->match.rid);
890 struct efx_tc_recirc_id *rid;
903 rid = efx_tc_get_recirc_id(efx, fa->chain_index,
905 if (IS_ERR(rid)) {
907 return PTR_ERR(rid);
909 act->rid = rid;
980 if (act->rid)
981 efx_tc_put_recirc_id(efx, act->rid);
1391 struct efx_tc_recirc_id *rid;
1393 rid = efx_tc_get_recirc_id(efx, tc->common.chain_index, net_dev);
1394 if (IS_ERR(rid)) {
1398 return PTR_ERR(rid);
1400 match.rid = rid;
1401 match.value.recirc_id = rid->fw_id;
1657 if (match.rid)
1658 efx_tc_put_recirc_id(efx, match.rid);
1810 * Conveniently, match.rid == NULL and match.value.recirc_id == 0 owing
1814 struct efx_tc_recirc_id *rid;
1826 rid = efx_tc_get_recirc_id(efx, tc->common.chain_index,
1828 if (IS_ERR(rid)) {
1832 return PTR_ERR(rid);
1834 match.rid = rid;
1835 match.value.recirc_id = rid->fw_id;
2212 if (match.rid)
2213 efx_tc_put_recirc_id(efx, match.rid);
2610 struct efx_tc_recirc_id *rid = ptr;
2613 WARN_ON(refcount_read(&rid->ref));
2614 ida_free(&efx->tc->recirc_ida, rid->fw_id);
2615 kfree(rid);