diff --git a/kernel/bpf/devmap.c b/kernel/bpf/devmap.c index 1defea4b27553c6c5733b0a2ce531cac671b5fad..f736a9ba4567edf76a6eed94388901496f5683ee 100644 --- a/kernel/bpf/devmap.c +++ b/kernel/bpf/devmap.c @@ -147,7 +147,8 @@ static struct bpf_map *dev_map_alloc(union bpf_attr *attr) static void dev_map_free(struct bpf_map *map) { struct bpf_dtab *dtab = container_of(map, struct bpf_dtab, map); - int i, cpu; + int cpu; + u32 i; /* At this point bpf_prog->aux->refcnt == 0 and this map->refcnt == 0, * so the programs (can be more than one that used this map) were @@ -418,7 +419,7 @@ static int dev_map_delete_elem(struct bpf_map *map, void *key) { struct bpf_dtab *dtab = container_of(map, struct bpf_dtab, map); struct bpf_dtab_netdev *old_dev; - int k = *(u32 *)key; + u32 k = *(u32 *)key; if (k >= map->max_entries) return -EINVAL;