Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
[firefly-linux-kernel-4.4.55.git] / net / core / flow.c
index 7fae13537b6b4d9e1da908a0b9c2448984850904..7102f166482d326f4135556bb8000f75fadf8b21 100644 (file)
@@ -334,7 +334,7 @@ static int flow_cache_percpu_empty(struct flow_cache *fc, int cpu)
        struct flow_cache_percpu *fcp;
        int i;
 
-       fcp = &per_cpu(*fc->percpu, cpu);
+       fcp = per_cpu_ptr(fc->percpu, cpu);
        for (i = 0; i < flow_cache_hash_size(fc); i++)
                if (!hlist_empty(&fcp->hash_table[i]))
                        return 0;
@@ -346,7 +346,7 @@ static void flow_cache_flush_per_cpu(void *data)
        struct flow_flush_info *info = data;
        struct tasklet_struct *tasklet;
 
-       tasklet = this_cpu_ptr(&info->cache->percpu->flush_tasklet);
+       tasklet = &this_cpu_ptr(info->cache->percpu)->flush_tasklet;
        tasklet->data = (unsigned long)info;
        tasklet_schedule(tasklet);
 }