From 8faf701446a7542627b847dc04f83e3f72b15f5d Mon Sep 17 00:00:00 2001 From: Christian Deacon Date: Thu, 4 Jun 2020 17:06:50 +0000 Subject: [PATCH] Switch to single LRU maps since we can't reliably read per CPU maps within BPF program. --- src/xdpfw_kern.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/xdpfw_kern.c b/src/xdpfw_kern.c index 1d413cf..aa77fbd 100644 --- a/src/xdpfw_kern.c +++ b/src/xdpfw_kern.c @@ -60,7 +60,7 @@ struct bpf_map_def SEC("maps") stats_map = struct bpf_map_def SEC("maps") ip_stats_map = { - .type = BPF_MAP_TYPE_LRU_PERCPU_HASH, + .type = BPF_MAP_TYPE_LRU_HASH, .key_size = sizeof(uint32_t), .value_size = sizeof(struct xdpfw_ip_stats), .max_entries = MAX_TRACK_IPS @@ -68,7 +68,7 @@ struct bpf_map_def SEC("maps") ip_stats_map = struct bpf_map_def SEC("maps") ip_blacklist_map = { - .type = BPF_MAP_TYPE_LRU_PERCPU_HASH, + .type = BPF_MAP_TYPE_LRU_HASH, .key_size = sizeof(uint32_t), .value_size = sizeof(uint64_t), .max_entries = MAX_TRACK_IPS