bpf: Switch bpf_map ref counter to atomic64_t so bpf_map_inc() never fails
[linux-2.6-microblaze.git] / drivers / net / ethernet / netronome / nfp / bpf / offload.c
index 88fab6a..06927ba 100644 (file)
@@ -46,9 +46,7 @@ nfp_map_ptr_record(struct nfp_app_bpf *bpf, struct nfp_prog *nfp_prog,
        /* Grab a single ref to the map for our record.  The prog destroy ndo
         * happens after free_used_maps().
         */
-       map = bpf_map_inc(map, false);
-       if (IS_ERR(map))
-               return PTR_ERR(map);
+       bpf_map_inc(map);
 
        record = kmalloc(sizeof(*record), GFP_KERNEL);
        if (!record) {