diff --git a/doc/changelog.txt b/doc/changelog.txt index 1c52c45..547bddd 100644 --- a/doc/changelog.txt +++ b/doc/changelog.txt @@ -2,7 +2,7 @@ HEAD ==== Changes: -- remove support for Linux 2.6.17--2.6.23 +- remove support for Linux 2.6.17--2.6.24 v1.47.1 (2010-10-15) diff --git a/extensions/compat_xtables.c b/extensions/compat_xtables.c index c1f4d83..0177d62 100644 --- a/extensions/compat_xtables.c +++ b/extensions/compat_xtables.c @@ -425,57 +425,6 @@ int xtnu_skb_make_writable(struct sk_buff **pskb, unsigned int len) } EXPORT_SYMBOL_GPL(xtnu_skb_make_writable); -#if LINUX_VERSION_CODE == KERNEL_VERSION(2, 6, 24) -static int __xtnu_ip_local_out(struct sk_buff *skb) -{ - struct iphdr *iph = ip_hdr(skb); - - iph->tot_len = htons(skb->len); - ip_send_check(iph); - return nf_hook(PF_INET, NF_IP_LOCAL_OUT, skb, NULL, - skb->dst->dev, dst_output); -} - -int xtnu_ip_local_out(struct sk_buff *skb) -{ - int err; - - err = __xtnu_ip_local_out(skb); - if (likely(err == 1)) - err = dst_output(skb); - - return err; -} -EXPORT_SYMBOL_GPL(xtnu_ip_local_out); -#endif - -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 24) -int xtnu_ip_route_output_key(void *net, struct rtable **rp, struct flowi *flp) -{ - return ip_route_output_flow(rp, flp, NULL, 0); -} -EXPORT_SYMBOL_GPL(xtnu_ip_route_output_key); - -void xtnu_proto_csum_replace4(__sum16 *sum, struct sk_buff *skb, - __be32 from, __be32 to, bool pseudohdr) -{ - __be32 diff[] = {~from, to}; - const void *dv = diff; /* kludge for < v2.6.19-555-g72685fc */ - - if (skb->ip_summed != CHECKSUM_PARTIAL) { - *sum = csum_fold(csum_partial(dv, sizeof(diff), - ~csum_unfold(*sum))); - if (skb->ip_summed == CHECKSUM_COMPLETE && pseudohdr) - skb->csum = ~csum_partial(dv, sizeof(diff), - ~skb->csum); - } else if (pseudohdr) { - *sum = ~csum_fold(csum_partial(dv, sizeof(diff), - csum_unfold(*sum))); - } -} -EXPORT_SYMBOL_GPL(xtnu_proto_csum_replace4); -#endif - void *HX_memmem(const void *space, size_t spacesize, const void *point, size_t pointsize) { diff --git a/extensions/compat_xtables.h b/extensions/compat_xtables.h index 142b0b0..676a6c8 100644 --- a/extensions/compat_xtables.h +++ b/extensions/compat_xtables.h @@ -8,8 +8,8 @@ #define DEBUGP Use__pr_debug__instead -#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 24) -# warning Kernels below 2.6.24 not supported. +#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 25) +# warning Kernels below 2.6.25 not supported. #endif #if defined(CONFIG_NF_CONNTRACK) || defined(CONFIG_NF_CONNTRACK_MODULE) @@ -21,17 +21,6 @@ # warning You need CONFIG_NF_CONNTRACK. #endif -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 24) -# define NF_INET_PRE_ROUTING NF_IP_PRE_ROUTING -# define NF_INET_LOCAL_IN NF_IP_LOCAL_IN -# define NF_INET_FORWARD NF_IP_FORWARD -# define NF_INET_LOCAL_OUT NF_IP_LOCAL_OUT -# define NF_INET_POST_ROUTING NF_IP_POST_ROUTING -# define ip_local_out xtnu_ip_local_out -# define ip_route_output_key xtnu_ip_route_output_key -# include "compat_nfinetaddr.h" -#endif - #if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 34) # define xt_match xtnu_match # define xt_register_match xtnu_register_match @@ -40,12 +29,6 @@ # define xt_unregister_matches xtnu_unregister_matches #endif -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 24) -# define csum_replace2 nf_csum_replace2 -# define csum_replace4 nf_csum_replace4 -# define inet_proto_csum_replace4 xtnu_proto_csum_replace4 -#endif - #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 34) # define ipt_unregister_table(tbl) ipt_unregister_table(&init_net, (tbl)) # define ip6t_unregister_table(tbl) ip6t_unregister_table(&init_net, (tbl)) diff --git a/extensions/ip6table_rawpost.c b/extensions/ip6table_rawpost.c index abc16bb..2159876 100644 --- a/extensions/ip6table_rawpost.c +++ b/extensions/ip6table_rawpost.c @@ -68,17 +68,10 @@ static int __init rawpost6_table_init(void) #if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 29) rwlock_init(&rawpost6_itable.lock); #endif -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 25) rawpost6_ptable = ip6t_register_table(&init_net, &rawpost6_itable, &rawpost6_initial.repl); if (IS_ERR(rawpost6_ptable)) return PTR_ERR(rawpost6_ptable); -#else - ret = ip6t_register_table(&rawpost6_itable, &rawpost6_initial.repl); - if (ret < 0) - return ret; - rawpost6_ptable = &rawpost6_itable; -#endif ret = nf_register_hook(&rawpost6_hook_ops); if (ret < 0) diff --git a/extensions/iptable_rawpost.c b/extensions/iptable_rawpost.c index 50a45c4..9abea27 100644 --- a/extensions/iptable_rawpost.c +++ b/extensions/iptable_rawpost.c @@ -69,17 +69,10 @@ static int __init rawpost4_table_init(void) #if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 29) rwlock_init(&rawpost4_itable.lock); #endif -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 25) rawpost4_ptable = ipt_register_table(&init_net, &rawpost4_itable, &rawpost4_initial.repl); if (IS_ERR(rawpost4_ptable)) return PTR_ERR(rawpost4_ptable); -#else - ret = ipt_register_table(&rawpost4_itable, &rawpost4_initial.repl); - if (ret < 0) - return ret; - rawpost4_ptable = &rawpost4_itable; -#endif ret = nf_register_hook(&rawpost4_hook_ops); if (ret < 0)