]> git.ipfire.org Git - thirdparty/xtables-addons.git/commitdiff
build: remove support for Linux 2.6.17
authorJan Engelhardt <jengelh@inai.de>
Mon, 15 Oct 2012 18:37:54 +0000 (20:37 +0200)
committerJan Engelhardt <jengelh@inai.de>
Tue, 16 Oct 2012 00:35:57 +0000 (02:35 +0200)
doc/changelog.txt
extensions/compat_xtables.c
extensions/compat_xtables.h
extensions/compat_xtnu.h
extensions/xt_TARPIT.c

index 2faa884f0514ab2afef1f9d39d5e9882bbd1687e..1f1f6a00e25ce7dfd5205fd974e433169d7f80ad 100644 (file)
@@ -1,6 +1,8 @@
 
 HEAD
 ====
+Changes:
+- remove support for Linux 2.6.17
 
 
 v1.47.1 (2010-10-15)
index e3b3b37326a6518adcd28fae952fd60ad7076cda..00b3e413b20f0b72cc8332920782918fb1919c5c 100644 (file)
@@ -463,10 +463,7 @@ EXPORT_SYMBOL_GPL(xtnu_request_find_match);
 
 int xtnu_ip_route_me_harder(struct sk_buff **pskb, unsigned int addr_type)
 {
-#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 17)
-       /* Actually this one is valid up to 2.6.18.4, but changed in 2.6.18.5 */
-       return ip_route_me_harder(pskb);
-#elif LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 23)
+#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 23)
        return ip_route_me_harder(pskb, addr_type);
 #else
        return ip_route_me_harder(*pskb, addr_type);
@@ -595,14 +592,6 @@ void xtnu_csum_replace2(__sum16 *sum, __be16 from, __be16 to)
 EXPORT_SYMBOL_GPL(xtnu_csum_replace2);
 #endif
 
-#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 17)
-int xtnu_skb_linearize(struct sk_buff *skb)
-{
-       return skb_linearize(skb, GFP_ATOMIC);
-}
-EXPORT_SYMBOL_GPL(xtnu_skb_linearize);
-#endif
-
 void *HX_memmem(const void *space, size_t spacesize,
     const void *point, size_t pointsize)
 {
index a1caa51dd897f860add7392fdc68857c82b71b39..45a9a022865f1335d5acd9b3188743f67f3829d5 100644 (file)
@@ -8,8 +8,8 @@
 
 #define DEBUGP Use__pr_debug__instead
 
-#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 17)
-#      warning Kernels below 2.6.17 not supported.
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 18)
+#      warning Kernels below 2.6.18 not supported.
 #endif
 
 #if defined(CONFIG_NF_CONNTRACK) || defined(CONFIG_NF_CONNTRACK_MODULE)
 #      warning You need either CONFIG_NF_CONNTRACK or CONFIG_IP_NF_CONNTRACK.
 #endif
 
-#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 17)
-#      define skb_init_secmark(skb)
-#      define skb_linearize    xtnu_skb_linearize
-#endif
-
 #if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 19)
 #      define neigh_hh_output xtnu_neigh_hh_output
 #      define IPPROTO_UDPLITE 136
index 35819b02d1a43acfc4171b9babae9061655e0ee4..98e8eaf36d35904b9a3fb1855ee37f757b0ba194 100644 (file)
@@ -161,7 +161,6 @@ extern void xtnu_csum_replace2(__u16 __bitwise *, __be16, __be16);
 extern void xtnu_csum_replace4(__u16 __bitwise *, __be32, __be32);
 extern void xtnu_proto_csum_replace4(__u16 __bitwise *, struct sk_buff *,
        __be32, __be32, bool);
-extern int xtnu_skb_linearize(struct sk_buff *);
 extern int xtnu_ipv6_skip_exthdr(const struct sk_buff *, int,
        uint8_t *, __be16 *);
 extern int xtnu_ipv6_find_hdr(const struct sk_buff *, unsigned int *,
index 0e66279ca61b1491bae8ee6ca1f9ac0c8dbcde42..b5e88d81013ae1c7b5f3efebf43e074502caa7ee 100644 (file)
@@ -208,13 +208,9 @@ static void tarpit_tcp4(struct sk_buff *oldskb, unsigned int hook,
        nf_reset(nskb);
        skb_nfmark(nskb) = 0;
        skb_init_secmark(nskb);
-
-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 18)
        skb_shinfo(nskb)->gso_size = 0;
        skb_shinfo(nskb)->gso_segs = 0;
        skb_shinfo(nskb)->gso_type = 0;
-#endif
-
        oldhdr = ip_hdr(oldskb);
        tcph = (struct tcphdr *)(skb_network_header(nskb) + ip_hdrlen(nskb));
 
@@ -359,13 +355,9 @@ static void tarpit_tcp6(struct sk_buff *oldskb, unsigned int hook,
        nf_reset(nskb);
        skb_nfmark(nskb) = 0;
        skb_init_secmark(nskb);
-
-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 18)
        skb_shinfo(nskb)->gso_size = 0;
        skb_shinfo(nskb)->gso_segs = 0;
        skb_shinfo(nskb)->gso_type = 0;
-#endif
-
        skb_put(nskb, sizeof(struct ipv6hdr));
        ip6h = ipv6_hdr(nskb);
        *(__be32 *)ip6h =  htonl(0x60000000 | (tclass << 20));