Provide a LRU version of the existing BPF_MAP_TYPE_PERCPU_HASH
Showing the changes to include/uapi/linux (1 of 3 files). Show all
Unified · Split
| @@ -86,6 +86,7 @@ enum bpf_map_type { · 85 unmodified lines | ||
| 86 | 86 | BPF_MAP_TYPE_STACK_TRACE, |
| 87 | 87 | BPF_MAP_TYPE_CGROUP_ARRAY, |
| 88 | 88 | BPF_MAP_TYPE_LRU_HASH, |
| 89 | + BPF_MAP_TYPE_LRU_PERCPU_HASH, | |
| 89 | 90 | }; |
| 90 | 91 | |
| 91 | 92 | enum bpf_prog_type { |
| @@ -108,7 +109,7 @@ enum bpf_prog_type { · 16 unmodified lines | ||
| 108 | 109 | |
| 109 | 110 | #define BPF_F_NO_PREALLOC (1U << 0) |
| 110 | 111 | /* Instead of having one common LRU list in the |
| 111 | − * BPF_MAP_TYPE_LRU_HASH map, use a percpu LRU list | |
| 112 | + * BPF_MAP_TYPE_LRU_[PERCPU_]HASH map, use a percpu LRU list | |
| 112 | 113 | * which can scale and perform better. |
| 113 | 114 | * Note, the LRU nodes (including free nodes) cannot be moved |
| 114 | 115 | * across different LRU lists. |