patch-2.4.22 linux-2.4.22/net/ipv4/fib_frontend.c

Next file: linux-2.4.22/net/ipv4/fib_hash.c
Previous file: linux-2.4.22/net/ipv4/arp.c
Back to the patch index
Back to the overall index

diff -urN linux-2.4.21/net/ipv4/fib_frontend.c linux-2.4.22/net/ipv4/fib_frontend.c
@@ -160,9 +160,9 @@
 	if (res.type != RTN_LOCAL)
 		goto out;
 	dev = FIB_RES_DEV(res);
-	if (dev)
-		atomic_inc(&dev->refcnt);
 
+	if (dev)
+		dev_hold(dev);
 out:
 	fib_res_put(&res);
 	return dev;

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)