[PATCH] ip_vs: fixed compile warning by repl. skb_linearize with __skb_linearize [2.6.0-test2]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



make output:
....
net/ipv4/ipvs/ip_vs_core.c: In function `ip_vs_out_icmp':
net/ipv4/ipvs/ip_vs_core.c:528: warning: `skb_linearize' is deprecated (declared at include/linux/skbuff.h:1129)
net/ipv4/ipvs/ip_vs_core.c: In function `ip_vs_out':
net/ipv4/ipvs/ip_vs_core.c:728: warning: `skb_linearize' is deprecated (declared at include/linux/skbuff.h:1129)
net/ipv4/ipvs/ip_vs_core.c: In function `ip_vs_in_icmp':
net/ipv4/ipvs/ip_vs_core.c:818: warning: `skb_linearize' is deprecated (declared at include/linux/skbuff.h:1129)
net/ipv4/ipvs/ip_vs_xmit.c: In function `ip_vs_nat_xmit':
net/ipv4/ipvs/ip_vs_xmit.c:269: warning: `skb_linearize' is deprecated (declared at include/linux/skbuff.h:1129)
....


The following fix compile warning and should works fine too (skb_linearize is an "alias" of __skb_linearize)
Please tellme if i'm wrong or not.

Tnx.



diff -urN 1.0/net/ipv4/ipvs/ip_vs_core.c 1.1/net/ipv4/ipvs/ip_vs_core.c
--- 1.0/net/ipv4/ipvs/ip_vs_core.c	2003-07-28 19:22:15.000000000 +0200
+++ 1.1/net/ipv4/ipvs/ip_vs_core.c	2003-07-28 19:27:41.000000000 +0200
@@ -22,6 +22,9 @@
  *
  * Changes:
  *
+ * 28 Jul. 2003       Daniele Bellucci <bellucda@tiscali.it>
+ *                    Replaced skb_linearize in __skb_linearize.
+ *
  */
 
 #include <linux/config.h>
@@ -525,7 +528,7 @@
 	}
 
 	if (skb_is_nonlinear(skb)) {
-		if (skb_linearize(skb, GFP_ATOMIC) != 0)
+		if (__skb_linearize(skb, GFP_ATOMIC) != 0)
 			return NF_DROP;
 		ip_send_check(skb->nh.iph);
 	}
@@ -725,7 +728,7 @@
 	 */
 
 	if (unlikely(cp->app && !pp->slave && skb_is_nonlinear(skb))) {
-		if (skb_linearize(skb, GFP_ATOMIC) != 0) {
+		if (__skb_linearize(skb, GFP_ATOMIC) != 0) {
 			ip_vs_conn_put(cp);
 			return NF_DROP;
 		}
@@ -815,7 +818,7 @@
 
 	*related = 1;
 	if (skb_is_nonlinear(skb)) {
-		if (skb_linearize(skb, GFP_ATOMIC) != 0)
+		if (__skb_linearize(skb, GFP_ATOMIC) != 0)
 			return NF_DROP;
 		ip_send_check(skb->nh.iph);
 	}
diff -urN 1.0/net/ipv4/ipvs/ip_vs_xmit.c 1.1/net/ipv4/ipvs/ip_vs_xmit.c
--- 1.0/net/ipv4/ipvs/ip_vs_xmit.c	2003-07-28 19:22:26.000000000 +0200
+++ 1.1/net/ipv4/ipvs/ip_vs_xmit.c	2003-07-28 19:27:45.000000000 +0200
@@ -13,6 +13,9 @@
  *
  * Changes:
  *
+ * 28 Jul. 2003       Daniele Bellucci <bellucda@tiscali.it>
+ *                    Replaced skb_linearize in __skb_linearize
+ *                   
  */
 
 #include <linux/config.h>
@@ -266,7 +269,7 @@
 
 	if (unlikely(cp->app && !pp->slave)) {
 		if (skb_is_nonlinear(skb) &&
-		    skb_linearize(skb, GFP_ATOMIC) != 0)
+		    __skb_linearize(skb, GFP_ATOMIC) != 0)
 			return NF_DROP;
 	}
 


.... now give me a feedback please 8)




Daniele.





-
: send the line "unsubscribe linux-net" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux 802.1Q VLAN]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Git]     [Bugtraq]     [Yosemite News and Information]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux PCI]     [Linux Admin]     [Samba]

  Powered by Linux