Skip to content

Commit

Permalink
Recheck state after acquiring lock (#2776)
Browse files Browse the repository at this point in the history
Signed-off-by: Alan Jowett <[email protected]>
Co-authored-by: Alan Jowett <[email protected]>
  • Loading branch information
Alan-Jowett and Alan Jowett authored Aug 21, 2023
1 parent 08a1d92 commit 7e1f0aa
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions libs/execution_context/ebpf_maps.c
Original file line number Diff line number Diff line change
Expand Up @@ -1055,6 +1055,7 @@ _insert_into_hot_list(_Inout_ ebpf_core_lru_map_t* map, _Inout_ ebpf_lru_entry_t
state = ebpf_lock_lock(&map->lock);
lock_held = true;

key_state = _get_key_state(map, entry);
if (key_state != EBPF_LRU_KEY_COLD) {
goto Exit;
}
Expand Down

0 comments on commit 7e1f0aa

Please sign in to comment.