Lines Matching refs:found
744 struct ofdpa_flow_tbl_entry *found;
745 size_t key_len = match->key_len ? match->key_len : sizeof(found->key);
747 hash_for_each_possible(ofdpa->flow_tbl, found,
749 if (memcmp(&found->key, &match->key, key_len) == 0)
750 return found;
760 struct ofdpa_flow_tbl_entry *found;
761 size_t key_len = match->key_len ? match->key_len : sizeof(found->key);
768 found = ofdpa_flow_tbl_find(ofdpa, match);
770 if (found) {
771 match->cookie = found->cookie;
772 hash_del(&found->entry);
773 kfree(found);
774 found = match;
775 found->cmd = ROCKER_TLV_CMD_TYPE_OF_DPA_FLOW_MOD;
777 found = match;
778 found->cookie = ofdpa->flow_tbl_next_cookie++;
779 found->cmd = ROCKER_TLV_CMD_TYPE_OF_DPA_FLOW_ADD;
782 hash_add(ofdpa->flow_tbl, &found->entry, found->key_crc32);
788 found, NULL, NULL);
795 struct ofdpa_flow_tbl_entry *found;
796 size_t key_len = match->key_len ? match->key_len : sizeof(found->key);
804 found = ofdpa_flow_tbl_find(ofdpa, match);
806 if (found) {
807 hash_del(&found->entry);
808 found->cmd = ROCKER_TLV_CMD_TYPE_OF_DPA_FLOW_DEL;
815 if (found) {
819 found, NULL, NULL);
820 kfree(found);
1051 struct ofdpa_group_tbl_entry *found;
1053 hash_for_each_possible(ofdpa->group_tbl, found,
1055 if (found->group_id == match->group_id)
1056 return found;
1079 struct ofdpa_group_tbl_entry *found;
1084 found = ofdpa_group_tbl_find(ofdpa, match);
1086 if (found) {
1087 hash_del(&found->entry);
1088 ofdpa_group_tbl_entry_free(found);
1089 found = match;
1090 found->cmd = ROCKER_TLV_CMD_TYPE_OF_DPA_GROUP_MOD;
1092 found = match;
1093 found->cmd = ROCKER_TLV_CMD_TYPE_OF_DPA_GROUP_ADD;
1096 hash_add(ofdpa->group_tbl, &found->entry, found->group_id);
1103 found, NULL, NULL);
1110 struct ofdpa_group_tbl_entry *found;
1116 found = ofdpa_group_tbl_find(ofdpa, match);
1118 if (found) {
1119 hash_del(&found->entry);
1120 found->cmd = ROCKER_TLV_CMD_TYPE_OF_DPA_GROUP_DEL;
1127 if (found) {
1131 found, NULL, NULL);
1132 ofdpa_group_tbl_entry_free(found);
1221 struct ofdpa_neigh_tbl_entry *found;
1223 hash_for_each_possible(ofdpa->neigh_tbl, found,
1225 if (found->ip_addr == ip_addr)
1226 return found;
1264 struct ofdpa_neigh_tbl_entry *found;
1282 found = ofdpa_neigh_tbl_find(ofdpa, ip_addr);
1284 updating = found && adding;
1285 removing = found && !adding;
1286 adding = !found && adding;
1295 memcpy(entry, found, sizeof(*entry));
1296 ofdpa_neigh_del(found);
1298 ofdpa_neigh_update(found, eth_dst, true);
1299 memcpy(entry, found, sizeof(*entry));
1381 struct ofdpa_neigh_tbl_entry *found;
1395 found = ofdpa_neigh_tbl_find(ofdpa, ip_addr);
1397 updating = found && adding;
1398 removing = found && !adding;
1399 adding = !found && adding;
1408 *index = found->index;
1409 ofdpa_neigh_del(found);
1411 ofdpa_neigh_update(found, NULL, false);
1412 resolved = !is_zero_ether_addr(found->eth_dst);
1413 *index = found->index;
1888 struct ofdpa_fdb_tbl_entry *found;
1890 hash_for_each_possible(ofdpa->fdb_tbl, found, entry, match->key_crc32)
1891 if (memcmp(&found->key, &match->key, sizeof(found->key)) == 0)
1892 return found;
1903 struct ofdpa_fdb_tbl_entry *found;
1920 found = ofdpa_fdb_tbl_find(ofdpa, fdb);
1922 if (found) {
1923 found->touched = jiffies;
1926 hash_del(&found->entry);
1936 if (!found != !removing) {
1938 if (!found && removing)
1950 struct ofdpa_fdb_tbl_entry *found;
1964 hash_for_each_safe(ofdpa->fdb_tbl, bkt, tmp, found, entry) {
1965 if (found->key.ofdpa_port != ofdpa_port)
1967 if (!found->learned)
1970 found->key.addr,
1971 found->key.vlan_id);
1974 hash_del(&found->entry);
2215 struct ofdpa_internal_vlan_tbl_entry *found;
2217 hash_for_each_possible(ofdpa->internal_vlan_tbl, found,
2219 if (found->ifindex == ifindex)
2220 return found;
2231 struct ofdpa_internal_vlan_tbl_entry *found;
2243 found = ofdpa_internal_vlan_tbl_find(ofdpa, ifindex);
2244 if (found) {
2246 goto found;
2249 found = entry;
2250 hash_add(ofdpa->internal_vlan_tbl, &found->entry, found->ifindex);
2255 found->vlan_id = htons(OFDPA_INTERNAL_VLAN_ID_BASE + i);
2256 goto found;
2261 found:
2262 found->ref_count++;
2265 return found->vlan_id;
2318 struct ofdpa_internal_vlan_tbl_entry *found;
2324 found = ofdpa_internal_vlan_tbl_find(ofdpa, ifindex);
2325 if (!found) {
2327 "ifindex (%d) not found in internal VLAN tbl\n",
2332 if (--found->ref_count <= 0) {
2333 bit = ntohs(found->vlan_id) - OFDPA_INTERNAL_VLAN_ID_BASE;
2335 hash_del(&found->entry);
2336 kfree(found);