[commits] batman-adv; branch, master, updated. v2010.1.0-162-g0893b89

postmaster at open-mesh.org postmaster at open-mesh.org
Sat Sep 18 13:11:58 CEST 2010


The following commit has been merged in the master branch:
commit 0893b89b1bc3640609d572b99201228cd99ad80b
Author: Sven Eckelmann <sven.eckelmann at gmx.de>
Date:   Sat Sep 18 11:11:40 2010 +0000

    batman-adv: wait for call_rcu before unloading module
    
    synchronize_rcu respective synchronize_net only waits for the rcu grace
    period to elapse and we may fail to finish the calls which were made to
    call_rcu in that time. In result the module could be unloaded during the
    execution of the RCU callbacks.
    
    rcu_barrier[1] will now wait for all outstanding RCU callbacks to finish
    before continuing.
    
    [1] Documentation/RCU/rcubarrier.txt
    
    Signed-off-by: Sven Eckelmann <sven.eckelmann at gmx.de>

diff --git a/main.c b/main.c
index e8acb46..a067f75 100644
--- a/main.c
+++ b/main.c
@@ -74,7 +74,7 @@ static void __exit batman_exit(void)
 	destroy_workqueue(bat_event_workqueue);
 	bat_event_workqueue = NULL;
 
-	synchronize_net();
+	rcu_barrier();
 }
 
 int mesh_init(struct net_device *soft_iface)

-- 
batman-adv


More information about the commits mailing list