]> err.no Git - linux-2.6/blobdiff - net/core/flow.c
[NET]: Introducing socket mark socket option.
[linux-2.6] / net / core / flow.c
index 3ed2b4b1d6d4f1c05b557f14d1dacaedaabbd473..46b38e06e0d75601bde3fbef5dbf3048008bc263 100644 (file)
@@ -293,7 +293,7 @@ void flow_cache_flush(void)
        static DEFINE_MUTEX(flow_flush_sem);
 
        /* Don't want cpus going down or up during this. */
-       lock_cpu_hotplug();
+       get_online_cpus();
        mutex_lock(&flow_flush_sem);
        atomic_set(&info.cpuleft, num_online_cpus());
        init_completion(&info.completion);
@@ -305,7 +305,7 @@ void flow_cache_flush(void)
 
        wait_for_completion(&info.completion);
        mutex_unlock(&flow_flush_sem);
-       unlock_cpu_hotplug();
+       put_online_cpus();
 }
 
 static void __devinit flow_cache_cpu_prepare(int cpu)
@@ -352,8 +352,7 @@ static int __init flow_cache_init(void)
        flow_lwm = 2 * flow_hash_size;
        flow_hwm = 4 * flow_hash_size;
 
-       init_timer(&flow_hash_rnd_timer);
-       flow_hash_rnd_timer.function = flow_cache_new_hashrnd;
+       setup_timer(&flow_hash_rnd_timer, flow_cache_new_hashrnd, 0);
        flow_hash_rnd_timer.expires = jiffies + FLOW_HASH_RND_PERIOD;
        add_timer(&flow_hash_rnd_timer);