|
@@ -619,7 +619,13 @@ out:
|
|
|
int bpf_percpu_hash_update(struct bpf_map *map, void *key, void *value,
|
|
|
u64 map_flags)
|
|
|
{
|
|
|
- return __htab_percpu_map_update_elem(map, key, value, map_flags, true);
|
|
|
+ int ret;
|
|
|
+
|
|
|
+ rcu_read_lock();
|
|
|
+ ret = __htab_percpu_map_update_elem(map, key, value, map_flags, true);
|
|
|
+ rcu_read_unlock();
|
|
|
+
|
|
|
+ return ret;
|
|
|
}
|
|
|
|
|
|
static const struct bpf_map_ops htab_percpu_ops = {
|