diff options
Diffstat (limited to 'package/iproute2/patches')
6 files changed, 17 insertions, 154 deletions
diff --git a/package/iproute2/patches/000-debian_patches_3.patch b/package/iproute2/patches/000-debian_patches_3.patch index e8adf1dc13..68954f6657 100644 --- a/package/iproute2/patches/000-debian_patches_3.patch +++ b/package/iproute2/patches/000-debian_patches_3.patch @@ -1,8 +1,8 @@ --- a/doc/ip-cref.tex +++ b/doc/ip-cref.tex -@@ -1324,6 +1324,19 @@ peers are allowed to send to us. - If it is not given, Linux uses the value selected with \verb|sysctl| - variable \verb|net/ipv4/tcp_reordering|. +@@ -1307,6 +1307,19 @@ peers are allowed to send to us. + --- \threeonly the clamp for congestion window. It is ignored if the \verb|lock| + flag is not used. +\item \verb|hoplimit NUMBER| + @@ -18,11 +18,11 @@ + window size. If it is not given (or set to zero), Linux uses the + values specified in~\cite{RFC2414}. + \item \verb|advmss NUMBER| - \item \verb|nexthop NEXTHOP| -@@ -2653,6 +2666,9 @@ http://www.cisco.com/univercd/cc/td/doc/ - \bibitem{RFC-DHCP} R.~Droms. - ``Dynamic Host Configuration Protocol.'', RFC-2131 +@@ -2666,6 +2679,9 @@ http://www.cisco.com/univercd/cc/td/doc/ + \bibitem{RFC2414} M.~Allman, S.~Floyd, C.~Partridge. + ``Increasing TCP's Initial Window'', RFC-2414. +\bibitem{RFC2414} M.~Allman, S.~Floyd, C.~Partridge. +``Increasing TCP's Initial Window'', RFC-2414. @@ -592,51 +592,9 @@ +}; + #endif ---- a/ip/iproute.c -+++ b/ip/iproute.c -@@ -73,7 +73,7 @@ static void usage(void) - fprintf(stderr, " [ rtt TIME ] [ rttvar TIME ]\n"); - fprintf(stderr, " [ window NUMBER] [ cwnd NUMBER ] [ initcwnd NUMBER ]\n"); - fprintf(stderr, " [ ssthresh NUMBER ] [ realms REALM ] [ src ADDRESS ]\n"); -- fprintf(stderr, " [ rto_min TIME ]\n"); -+ fprintf(stderr, " [ rto_min TIME ] [ hoplimit NUMBER ]\n"); - fprintf(stderr, "TYPE := [ unicast | local | broadcast | multicast | throw |\n"); - fprintf(stderr, " unreachable | prohibit | blackhole | nat ]\n"); - fprintf(stderr, "TABLE_ID := [ local | main | default | all | NUMBER ]\n"); -@@ -792,6 +792,30 @@ int iproute_modify(int cmd, unsigned fla - invarg("\"reordering\" value is invalid\n", *argv); - rta_addattr32(mxrta, sizeof(mxbuf), RTAX_REORDERING, reord); - #endif -+#ifdef RTAX_HOPLIMIT -+ } else if (strcmp(*argv, "hoplimit") == 0) { -+ unsigned hoplim; -+ NEXT_ARG(); -+ if (strcmp(*argv, "lock") == 0) { -+ mxlock |= (1<<RTAX_HOPLIMIT); -+ NEXT_ARG(); -+ } -+ if (get_unsigned(&hoplim, *argv, 0)) -+ invarg("\"hoplimit\" value is invalid\n", *argv); -+ rta_addattr32(mxrta, sizeof(mxbuf), RTAX_HOPLIMIT, hoplim); -+#endif -+#ifdef RTAX_INITCWND -+ } else if (strcmp(*argv, "initcwnd") == 0) { -+ unsigned initcwnd; -+ NEXT_ARG(); -+ if (strcmp(*argv, "lock") == 0) { -+ mxlock |= (1<<RTAX_HOPLIMIT); -+ NEXT_ARG(); -+ } -+ if (get_unsigned(&initcwnd, *argv, 0)) -+ invarg("\"initcwnd\" value is invalid\n", *argv); -+ rta_addattr32(mxrta, sizeof(mxbuf), RTAX_INITCWND, initcwnd); -+#endif - } else if (strcmp(*argv, "rtt") == 0) { - unsigned rtt; - NEXT_ARG(); --- a/ip/iptunnel.c +++ b/ip/iptunnel.c -@@ -134,7 +134,7 @@ static int parse_args(int argc, char **a +@@ -129,7 +129,7 @@ static int parse_args(int argc, char **a NEXT_ARG(); p->o_flags |= GRE_KEY; if (strchr(*argv, '.')) @@ -647,7 +605,7 @@ fprintf(stderr, "invalid value of \"okey\"\n"); --- a/Makefile +++ b/Makefile -@@ -49,7 +49,7 @@ install: all +@@ -57,7 +57,7 @@ install: all $(DESTDIR)$(DOCDIR)/examples install -m 0644 $(shell find examples/diffserv -maxdepth 1 -type f) \ $(DESTDIR)$(DOCDIR)/examples/diffserv @@ -656,7 +614,7 @@ install -m 0644 $(shell find etc/iproute2 -maxdepth 1 -type f) $(DESTDIR)$(CONFDIR) install -m 0755 -d $(DESTDIR)$(MANDIR)/man8 install -m 0644 $(shell find man/man8 -maxdepth 1 -type f) $(DESTDIR)$(MANDIR)/man8 -@@ -67,7 +67,7 @@ snapshot: +@@ -75,7 +75,7 @@ snapshot: clean: rm -f cscope.* @@ -679,7 +637,7 @@ --- a/tc/Makefile +++ b/tc/Makefile -@@ -14,6 +14,7 @@ TCMODULES += q_cbq.o +@@ -15,6 +15,7 @@ TCMODULES += q_cbq.o TCMODULES += q_rr.o TCMODULES += q_multiq.o TCMODULES += q_netem.o diff --git a/package/iproute2/patches/002-iproute2-ipxfrm_no_sctp.patch b/package/iproute2/patches/002-iproute2-ipxfrm_no_sctp.patch index b44ce20a96..46201a4d80 100644 --- a/package/iproute2/patches/002-iproute2-ipxfrm_no_sctp.patch +++ b/package/iproute2/patches/002-iproute2-ipxfrm_no_sctp.patch @@ -1,6 +1,6 @@ --- a/ip/ipxfrm.c +++ b/ip/ipxfrm.c -@@ -491,7 +491,6 @@ void xfrm_selector_print(struct xfrm_sel +@@ -467,7 +467,6 @@ void xfrm_selector_print(struct xfrm_sel switch (sel->proto) { case IPPROTO_TCP: case IPPROTO_UDP: @@ -8,7 +8,7 @@ case IPPROTO_DCCP: default: /* XXX */ if (sel->sport_mask) -@@ -1154,7 +1153,6 @@ static int xfrm_selector_upspec_parse(st +@@ -1130,7 +1129,6 @@ static int xfrm_selector_upspec_parse(st switch (sel->proto) { case IPPROTO_TCP: case IPPROTO_UDP: diff --git a/package/iproute2/patches/003-iproute2-htb_overhead.patch b/package/iproute2/patches/003-iproute2-htb_overhead.patch deleted file mode 100644 index bf7ee11d5f..0000000000 --- a/package/iproute2/patches/003-iproute2-htb_overhead.patch +++ /dev/null @@ -1,96 +0,0 @@ ---- a/tc/q_htb.c -+++ b/tc/q_htb.c -@@ -35,10 +35,14 @@ static void explain(void) - " default minor id of class to which unclassified packets are sent {0}\n" - " r2q DRR quantums are computed as rate in Bps/r2q {10}\n" - " debug string of 16 numbers each 0-3 {0}\n\n" -- "... class add ... htb rate R1 burst B1 [prio P] [slot S] [pslot PS]\n" -+ "... class add ... htb rate R1 [burst B1] [mpu B] [overhead O]\n" -+ " [prio P] [slot S] [pslot PS]\n" - " [ceil R2] [cburst B2] [mtu MTU] [quantum Q]\n" - " rate rate allocated to this class (class can still borrow)\n" - " burst max bytes burst which can be accumulated during idle period {computed}\n" -+ " mpu minimum packet size used in rate computations\n" -+ " overhead per-packet size overhead used in rate computations\n" -+ - " ceil definite upper class rate (no borrows) {rate}\n" - " cburst burst but for ceil {computed}\n" - " mtu max packet size we create rate map for {1600}\n" -@@ -103,7 +107,9 @@ static int htb_parse_class_opt(struct qd - struct tc_htb_opt opt; - __u32 rtab[256],ctab[256]; - unsigned buffer=0,cbuffer=0; -- int cell_log=-1,ccell_log = -1,mtu; -+ int cell_log=-1,ccell_log = -1; -+ unsigned mtu, mpu; -+ unsigned char mpu8 = 0, overhead = 0; - struct rtattr *tail; - - memset(&opt, 0, sizeof(opt)); mtu = 1600; /* eth packet len */ -@@ -120,6 +126,16 @@ static int htb_parse_class_opt(struct qd - if (get_u32(&mtu, *argv, 10)) { - explain1("mtu"); return -1; - } -+ } else if (matches(*argv, "mpu") == 0) { -+ NEXT_ARG(); -+ if (get_u8(&mpu8, *argv, 10)) { -+ explain1("mpu"); return -1; -+ } -+ } else if (matches(*argv, "overhead") == 0) { -+ NEXT_ARG(); -+ if (get_u8(&overhead, *argv, 10)) { -+ explain1("overhead"); return -1; -+ } - } else if (matches(*argv, "quantum") == 0) { - NEXT_ARG(); - if (get_u32(&opt.quantum, *argv, 10)) { -@@ -191,14 +207,18 @@ static int htb_parse_class_opt(struct qd - if (!buffer) buffer = opt.rate.rate / HZ + mtu; - if (!cbuffer) cbuffer = opt.ceil.rate / HZ + mtu; - -- if ((cell_log = tc_calc_rtable(opt.rate.rate, rtab, cell_log, mtu, 0)) < 0) { -+/* encode overhead and mpu, 8 bits each, into lower 16 bits */ -+ mpu = (unsigned)mpu8 | (unsigned)overhead << 8; -+ opt.ceil.mpu = mpu; opt.rate.mpu = mpu; -+ -+ if ((cell_log = tc_calc_rtable(opt.rate.rate, rtab, cell_log, mtu, mpu)) < 0) { - fprintf(stderr, "htb: failed to calculate rate table.\n"); - return -1; - } - opt.buffer = tc_calc_xmittime(opt.rate.rate, buffer); - opt.rate.cell_log = cell_log; - -- if ((ccell_log = tc_calc_rtable(opt.ceil.rate, ctab, cell_log, mtu, 0)) < 0) { -+ if ((ccell_log = tc_calc_rtable(opt.ceil.rate, ctab, cell_log, mtu, mpu)) < 0) { - fprintf(stderr, "htb: failed to calculate ceil rate table.\n"); - return -1; - } -@@ -222,6 +242,7 @@ static int htb_print_opt(struct qdisc_ut - double buffer,cbuffer; - SPRINT_BUF(b1); - SPRINT_BUF(b2); -+ SPRINT_BUF(b3); - - if (opt == NULL) - return 0; -@@ -244,10 +265,16 @@ static int htb_print_opt(struct qdisc_ut - fprintf(f, "ceil %s ", sprint_rate(hopt->ceil.rate, b1)); - cbuffer = ((double)hopt->ceil.rate*tc_core_tick2usec(hopt->cbuffer))/1000000; - if (show_details) { -- fprintf(f, "burst %s/%u mpu %s ", sprint_size(buffer, b1), -- 1<<hopt->rate.cell_log, sprint_size(hopt->rate.mpu, b2)); -- fprintf(f, "cburst %s/%u mpu %s ", sprint_size(cbuffer, b1), -- 1<<hopt->ceil.cell_log, sprint_size(hopt->ceil.mpu, b2)); -+ fprintf(f, "burst %s/%u mpu %s overhead %s ", -+ sprint_size(buffer, b1), -+ 1<<hopt->rate.cell_log, -+ sprint_size(hopt->rate.mpu&0xFF, b2), -+ sprint_size((hopt->rate.mpu>>8)&0xFF, b3)); -+ fprintf(f, "cburst %s/%u mpu %s overhead %s ", -+ sprint_size(cbuffer, b1), -+ 1<<hopt->ceil.cell_log, -+ sprint_size(hopt->ceil.mpu&0xFF, b2), -+ sprint_size((hopt->ceil.mpu>>8)&0xFF, b3)); - fprintf(f, "level %d ", (int)hopt->level); - } else { - fprintf(f, "burst %s ", sprint_size(buffer, b1)); diff --git a/package/iproute2/patches/006-iproute2-tc_esfq.patch b/package/iproute2/patches/006-iproute2-tc_esfq.patch index 2d9acd5daf..4552d50658 100644 --- a/package/iproute2/patches/006-iproute2-tc_esfq.patch +++ b/package/iproute2/patches/006-iproute2-tc_esfq.patch @@ -79,7 +79,7 @@ enum --- a/tc/Makefile +++ b/tc/Makefile -@@ -7,6 +7,7 @@ include ../Config +@@ -8,6 +8,7 @@ SHARED_LIBS ?= y TCMODULES := TCMODULES += q_fifo.o TCMODULES += q_sfq.o diff --git a/package/iproute2/patches/110-extra-ccopts.patch b/package/iproute2/patches/110-extra-ccopts.patch index 1921ae9e20..0bf822f28d 100644 --- a/package/iproute2/patches/110-extra-ccopts.patch +++ b/package/iproute2/patches/110-extra-ccopts.patch @@ -1,6 +1,6 @@ --- a/Makefile +++ b/Makefile -@@ -22,7 +22,7 @@ ADDLIB+=ipx_ntop.o ipx_pton.o +@@ -29,7 +29,7 @@ ADDLIB+=ipx_ntop.o ipx_pton.o CC = gcc HOSTCC = gcc diff --git a/package/iproute2/patches/120-libnetlink-pic.patch b/package/iproute2/patches/120-libnetlink-pic.patch index 8c0f2bd777..c7b78d0639 100644 --- a/package/iproute2/patches/120-libnetlink-pic.patch +++ b/package/iproute2/patches/120-libnetlink-pic.patch @@ -1,6 +1,7 @@ --- a/lib/Makefile +++ b/lib/Makefile -@@ -1,3 +1,4 @@ +@@ -1,4 +1,4 @@ +-CFLAGS += -fPIC +CFLAGS+=$(FPIC) UTILOBJ=utils.o rt_names.o ll_types.o ll_proto.o ll_addr.o inet_proto.o |