]> rtime.felk.cvut.cz Git - lisovros/iproute2_canprio.git/log
lisovros/iproute2_canprio.git
16 years agoiproute2: fix ip manpage typo (syntax error)
Andreas Henriksson [Fri, 22 Feb 2008 13:11:49 +0000 (14:11 +0100)]
iproute2: fix ip manpage typo (syntax error)

Hello Stephen!

The patches branch of the debian packaging repo, at
git://git.debian.org/git/collab-maint/pkg-iproute, now has four patches still
pending. (Not resending, since they've all been posted multiple times before.
Pick them up from the repo if you're interested.)

Here's the latest addition:

commit 3c904bb5933257533f4afecf805ca5a548a8e885
Author: Andreas Henriksson <andreas@fatal.se>
Date:   Fri Feb 22 13:57:10 2008 +0100

    Fix typo (syntax error) in ip(8) manpage.

    Caught by lintian (debian package checker).

16 years agomissing dport in f_u32 output
Stephen Hemminger [Fri, 22 Feb 2008 19:51:35 +0000 (11:51 -0800)]
missing dport in f_u32 output

Small typo from last change to decode filters. Should print dport
not port.

16 years agodecode the output of u32 matches
Stephen Hemminger [Mon, 18 Feb 2008 19:35:29 +0000 (11:35 -0800)]
decode the output of u32 matches

reverse the match offset/mask values into ip header matches.

16 years agoget rid of warning from misnamed prototype
Stephen Hemminger [Mon, 18 Feb 2008 18:59:22 +0000 (10:59 -0800)]
get rid of warning from misnamed prototype

Minor warning message from missing prototype, probably because of
function name change.

16 years agobreak excessively long lines
Stephen Hemminger [Mon, 18 Feb 2008 18:51:42 +0000 (10:51 -0800)]
break excessively long lines

Cleanup code (slightly).

16 years agoRevert "rlim qdisc support"
Stephen Hemminger [Mon, 18 Feb 2008 18:13:25 +0000 (10:13 -0800)]
Revert "rlim qdisc support"

This reverts commit 7ca30b789d7ea0a7afce45ddf5e5fd5fad0728dc.

Since rlim isn't upstream (yet), drop it.

16 years agoAdd missing prefix bit length for addrlabel
Varun Chandramohan [Thu, 14 Feb 2008 09:51:08 +0000 (15:21 +0530)]
Add missing prefix bit length for addrlabel

The prefix bit lenght value was not updated, resulting in incorrect addrlabel
entry. This patch fixes that issue.

Signed-off-by: Varun Chandramohan <varunc@linux.vnet.ibm.com>
Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoAdd addrlabel sub-command.
YOSHIFUJI Hideaki / 吉藤英明 [Wed, 13 Feb 2008 16:20:12 +0000 (03:20 +1100)]
Add addrlabel sub-command.

Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoUpdate various classifiers' help output for expected CLASSID syntax
PJ Waskiewicz [Wed, 13 Feb 2008 11:49:09 +0000 (03:49 -0800)]
Update various classifiers' help output for expected CLASSID syntax

update: Fix the spelling of "hexidecimal"

This updates the help output to specify that CLASSID should be hexidecimal.
This makes sure that a user entering "flowid 1:10" gets his flow put into
band 15 (0x10) and knows why.

Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoadd include/linux/hdlc/ioctl.h
Stephen Hemminger [Wed, 13 Feb 2008 20:32:49 +0000 (12:32 -0800)]
add include/linux/hdlc/ioctl.h

Need to add include/linux/hdlc/ioctl.h because it is not present
in older releases.

Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agominor typo fixes
Stephen Hemminger [Fri, 8 Feb 2008 06:10:14 +0000 (22:10 -0800)]
minor typo fixes

A couple of obvious typo's.

16 years agoProtocol field on tc_filter is required
Stephen Hemminger [Fri, 8 Feb 2008 03:25:26 +0000 (19:25 -0800)]
Protocol field on tc_filter is required

Kernel won't find matching filter if protocol value not
provided.

16 years agoadd support for matching AOE and CAN ether types
Stephen Hemminger [Fri, 8 Feb 2008 03:24:31 +0000 (19:24 -0800)]
add support for matching AOE and CAN ether types

Update the protocol table to match current kernel support.
Why is the list not in an /etc file?

16 years agoreharmonize headers with pre-freeze 2.6.25
Stephen Hemminger [Fri, 8 Feb 2008 03:22:42 +0000 (19:22 -0800)]
reharmonize headers with pre-freeze 2.6.25

Some minor header file changes headed for 2.6.25

16 years agofix typos in help message for meta match
Stephen Hemminger [Tue, 5 Feb 2008 20:07:07 +0000 (12:07 -0800)]
fix typos in help message for meta match

Make sure examples actually work.

16 years agoignore emacs backup files
Stephen Hemminger [Tue, 5 Feb 2008 19:41:48 +0000 (11:41 -0800)]
ignore emacs backup files

16 years agoChange where vlan option shows up in help
Stephen Hemminger [Tue, 5 Feb 2008 19:33:44 +0000 (11:33 -0800)]
Change where vlan option shows up in help

Vlan should not be in the socket section

16 years agocls_flow: add vlan-tag support
Patrick McHardy [Tue, 5 Feb 2008 14:31:53 +0000 (15:31 +0100)]
cls_flow: add vlan-tag support

commit 94e9cba778cb97d77d9146dc3bd38ff195bc2c8a
Author: Patrick McHardy <kaber@trash.net>
Date:   Sat Feb 2 18:22:16 2008 +0100

    [IPROUTE]: cls_flow: add vlan-tag support

Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoharmonize headers with upcoming 2.6.25
Stephen Hemminger [Fri, 1 Feb 2008 06:41:18 +0000 (22:41 -0800)]
harmonize headers with upcoming 2.6.25

Add stuff from early 2.6.25 merge.

Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoAdd flow classifier support
Patrick McHardy [Thu, 31 Jan 2008 17:58:59 +0000 (18:58 +0100)]
Add flow classifier support

[IPROUTE]: Add flow classifier support

Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoAdd support for SFQ xstats
Patrick McHardy [Thu, 31 Jan 2008 17:58:52 +0000 (18:58 +0100)]
Add support for SFQ xstats

[IPROUTE]: Add support for SFQ xstats

Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agofix problem caused by rtnl_send checks
Stephen Hemminger [Fri, 1 Feb 2008 05:38:58 +0000 (21:38 -0800)]
fix problem caused by rtnl_send checks

Some usages of rtnl_send could cause errors (ie flush requests)
others do a listen afterwards.

Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agowhitespace typo in tc_common.h
Stephen Hemminger [Fri, 1 Feb 2008 05:26:00 +0000 (21:26 -0800)]
whitespace typo in tc_common.h

minor whitespace typo.

16 years agopoll for errors after rtnl_send
Stephen Hemminger [Sat, 26 Jan 2008 19:09:42 +0000 (11:09 -0800)]
poll for errors after rtnl_send

This fixes the problem where a bulk operation (like ip flush)
is performed as non-root user.  The kernel will only send a response
if there is an error, so check for it.

16 years agoremove extra newline from perror() calls
Stephen Hemminger [Sat, 26 Jan 2008 19:08:31 +0000 (11:08 -0800)]
remove extra newline from perror() calls

perror error adds a newline, so don't split error message
across two lines.

16 years agolibnetlink: don't spin forever on receive error
Stephen Hemminger [Fri, 25 Jan 2008 23:39:09 +0000 (15:39 -0800)]
libnetlink: don't spin forever on receive error

If there is a problem talking to kernel, don't retry except in the
special case of signal or -EAGAIN

Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoMerge branch 'net-2.6.25'
Stephen Hemminger [Fri, 25 Jan 2008 22:27:19 +0000 (14:27 -0800)]
Merge branch 'net-2.6.25'

16 years agovlan meta tag match
Stephen Hemminger [Thu, 24 Jan 2008 21:16:41 +0000 (13:16 -0800)]
vlan meta tag match

Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoupdate headers to current net-2.6.25
Stephen Hemminger [Thu, 24 Jan 2008 21:14:28 +0000 (13:14 -0800)]
update headers to current net-2.6.25

Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agofix typo in ip batch error message
Stephen Hemminger [Mon, 21 Jan 2008 21:46:08 +0000 (13:46 -0800)]
fix typo in ip batch error message

Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agorelease v2.6.24-080108
Stephen Hemminger [Tue, 8 Jan 2008 16:59:32 +0000 (08:59 -0800)]
release v2.6.24-080108

Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoRevert "TC action parsing bug fix"
Stephen Hemminger [Thu, 3 Jan 2008 00:34:58 +0000 (16:34 -0800)]
Revert "TC action parsing bug fix"

This reverts commit 720a2e8d990707749b2cafa77ab3cd2b8241ec47.

After further investigation it seems clear to me that reverting the
commit 720a2e8d990707749b2... is the correct thing to do, since the real
fix for the problem this commit was supposed to fix was instead fixed in
commit c29391c7c68f031e246c...

Whatever you specify after a u32 police you will now get a syntax error,
and according to "tc filter add u32 help" there are several things that
you are supposed to be able to specify after a police.

So, Steven, please revert 720a2e8d990707749b2...

16 years agoiproute2: add synonyms for ip rule options to ip(8) manpage.
Andreas Henriksson [Wed, 2 Jan 2008 23:49:11 +0000 (00:49 +0100)]
iproute2: add synonyms for ip rule options to ip(8) manpage.

commit 355e1438f73602fbac029d28891dfa889471b679
Author: Andreas Henriksson <andreas@fatal.se>
Date:   Wed Jan 2 23:21:59 2008 +0100

    Add synonyms for ip rule options to ip(8) manpage.

    See:
    http://bugs.debian.org/433507
    http://bugs.debian.org/213673

Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoiproute2: revert syntax help text mistake.
Andreas Henriksson [Wed, 2 Jan 2008 23:47:30 +0000 (00:47 +0100)]
iproute2: revert syntax help text mistake.

Sorry. The pref and prio options are actually synonyms.
This reverts part of commit 576c63ee59de3f18bec4ebd8181a5a395f268d03.

Signed-off-by: Andreas Henriksson <andreas@fatal.se>
Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoiproute2: add synonyms for ip rule options to ip(8) manpage.
Andreas Henriksson [Wed, 2 Jan 2008 23:49:11 +0000 (00:49 +0100)]
iproute2: add synonyms for ip rule options to ip(8) manpage.

commit 355e1438f73602fbac029d28891dfa889471b679
Author: Andreas Henriksson <andreas@fatal.se>
Date:   Wed Jan 2 23:21:59 2008 +0100

    Add synonyms for ip rule options to ip(8) manpage.

    See:
    http://bugs.debian.org/433507
    http://bugs.debian.org/213673

Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoiproute2: revert syntax help text mistake.
Andreas Henriksson [Wed, 2 Jan 2008 23:47:30 +0000 (00:47 +0100)]
iproute2: revert syntax help text mistake.

Sorry. The pref and prio options are actually synonyms.
This reverts part of commit 576c63ee59de3f18bec4ebd8181a5a395f268d03.

Signed-off-by: Andreas Henriksson <andreas@fatal.se>
Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoRevert "TC action parsing bug fix"
Stephen Hemminger [Wed, 2 Jan 2008 17:29:30 +0000 (09:29 -0800)]
Revert "TC action parsing bug fix"

[...]
> Commands like "tc filter add dev ppp0 parent ffff: protocol ip prio 50
> u32 match ip src 0.0.0.0/0 police rate 4mbit burst 10k drop flowid :1"
> apparently no longer works. The flowid is not accepted anymore.
> Reverting commit 720a2e8d99... which you authored seems to "fix" this.
[...]

After further investigation it seems clear to me that reverting the
commit 720a2e8d990707749b2... is the correct thing to do, since the real
fix for the problem this commit was supposed to fix was instead fixed in
commit c29391c7c68f031e246c...

Whatever you specify after a u32 police you will now get a syntax error,
and according to "tc filter add u32 help" there are several things that
you are supposed to be able to specify after a police.

This reverts commit 720a2e8d990707749b2cafa77ab3cd2b8241ec47.

16 years agoMerge branch 'master' into net-2.6.25
Stephen Hemminger [Mon, 31 Dec 2007 20:56:31 +0000 (12:56 -0800)]
Merge branch 'master' into net-2.6.25

16 years agoadd include/netinet/tcp.h
Stephen Hemminger [Mon, 31 Dec 2007 20:56:08 +0000 (12:56 -0800)]
add include/netinet/tcp.h

ss.c needs lastest version of netinet/tcp.h which probably isn't
on most distro's yet.

Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoUpdate header files from net-2.6.25
Stephen Hemminger [Mon, 31 Dec 2007 20:54:18 +0000 (12:54 -0800)]
Update header files from net-2.6.25

Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoMerge branch 'master' into net-2.6.25
Stephen Hemminger [Mon, 31 Dec 2007 20:51:15 +0000 (12:51 -0800)]
Merge branch 'master' into net-2.6.25

16 years agoiptables compatiablity
Denys Fedoryshchenko [Mon, 24 Dec 2007 16:51:11 +0000 (11:51 -0500)]
iptables compatiablity

New iptables 1.4.0 has some library names changed from libipt to libxt.
It is prefferable also to open libxt_ first, as newer "style".

Signed-off-by: Denys Fedoryshchenko <nuclearcat@nuclearcat.com>
Signed-off-by: Jamal Hadi Salim <hadi@cyberus.ca>
Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoChange the rate table calc of transmit cost to use upper bound value.
Jesper Dangaard Brouer [Wed, 5 Sep 2007 13:24:51 +0000 (15:24 +0200)]
Change the rate table calc of transmit cost to use upper bound value.

Patrick McHardy, Cite: 'its better to overestimate than underestimate
to stay in control of the queue'.

Illustrating the rate table array:
 Legend description
   rtab[x]   : Array index x of rtab[x]
   xmit_sz   : Transmit size contained in rtab[x] (normally transmit time)
   maps[a-b] : Packet sizes from a to b, will map into rtab[x]

Current/old rate table mapping (cell_log:3):
 rtab[0]:=xmit_sz:0  maps[0-7]
 rtab[1]:=xmit_sz:8  maps[8-15]
 rtab[2]:=xmit_sz:16 maps[16-23]
 rtab[3]:=xmit_sz:24 maps[24-31]
 rtab[4]:=xmit_sz:32 maps[32-39]
 rtab[5]:=xmit_sz:40 maps[40-47]
 rtab[6]:=xmit_sz:48 maps[48-55]

New rate table mapping, with kernel cell_align support.
 rtab[0]:=xmit_sz:8  maps[0-8]
 rtab[1]:=xmit_sz:16 maps[9-16]
 rtab[2]:=xmit_sz:24 maps[17-24]
 rtab[3]:=xmit_sz:32 maps[25-32]
 rtab[4]:=xmit_sz:40 maps[33-40]
 rtab[5]:=xmit_sz:48 maps[41-48]
 rtab[6]:=xmit_sz:56 maps[49-56]

New TC util on a kernel WITHOUT support for cell_align
 rtab[0]:=xmit_sz:8 maps[0-7]
 rtab[1]:=xmit_sz:16 maps[8-15]
 rtab[2]:=xmit_sz:24 maps[16-23]
 rtab[3]:=xmit_sz:32 maps[24-31]
 rtab[4]:=xmit_sz:40 maps[32-39]
 rtab[5]:=xmit_sz:48 maps[40-47]
 rtab[6]:=xmit_sz:56 maps[48-55]

Signed-off-by: Jesper Dangaard Brouer <hawk@comx.dk>
Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoCleanup: tc_calc_rtable().
Jesper Dangaard Brouer [Wed, 5 Sep 2007 08:47:47 +0000 (10:47 +0200)]
Cleanup: tc_calc_rtable().

Change tc_calc_rtable() to take a tc_ratespec struct as an
argument. (cell_log still needs to be passed on as a parameter,
because -1 indicate that the cell_log needs to be computed by the
function.).

Signed-off-by: Jesper Dangaard Brouer <hawk@comx.dk>
Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoOverhead calculation is now done in the kernel.
Jesper Dangaard Brouer [Tue, 11 Sep 2007 14:59:58 +0000 (16:59 +0200)]
Overhead calculation is now done in the kernel.

The only current user is HTB. HTB overhead argument is now passed on
to the kernel (in the struct tc_ratespec). Also correct the data
types.

Signed-off-by: Jesper Dangaard Brouer <hawk@comx.dk>
Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoUse netinet/tcp.h (with correction) rather than kernel headers
Stephen Hemminger [Mon, 31 Dec 2007 18:41:18 +0000 (10:41 -0800)]
Use netinet/tcp.h (with correction) rather than kernel headers

Fix the userspace header file rather than importing more
kernel headers.

Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agosnapshot 31 Dec 2007
Stephen Hemminger [Mon, 31 Dec 2007 18:30:40 +0000 (10:30 -0800)]
snapshot 31 Dec 2007

Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoadd decode of match rules
Stephen Hemminger [Mon, 31 Dec 2007 18:29:52 +0000 (10:29 -0800)]
add decode of match rules

Show ip address etc when decoding output of tc filter show

Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoManual page fixes
Stephen Hemminger [Mon, 31 Dec 2007 18:15:03 +0000 (10:15 -0800)]
Manual page fixes

These are from debian sid.

Signed-off-by: Stephen Hemminger <stephen.hemminger@vyatta.com>
16 years agoveth.h move to linux/
Stephen Hemminger [Tue, 25 Dec 2007 20:38:08 +0000 (12:38 -0800)]
veth.h move to linux/

Move veth.h to linux/ since it is an API.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agosnapshot target
Stephen Hemminger [Fri, 21 Dec 2007 17:53:45 +0000 (09:53 -0800)]
snapshot target

Add Makefile target to create snapshot file.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoveth: use kernel header file
Stephen Hemminger [Fri, 21 Dec 2007 17:37:30 +0000 (09:37 -0800)]
veth: use kernel header file

Use santized kernel header for veth.h and put in correct place
to prevent possible future problems with API.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoveth device link management
Vitaliy Gusev [Tue, 18 Dec 2007 12:15:38 +0000 (15:15 +0300)]
veth device link management

Signed-off-by: Vitaliy Gusev <vgusev@openvz.org>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoiplink_parse() routine
Pavel Emelyanov [Thu, 19 Jul 2007 09:32:31 +0000 (13:32 +0400)]
iplink_parse() routine

This routine parses CLI attributes, describing generic link
parameters such as name, address, etc.

This is mostly copy-pasted from iplink_modify().

Signed-off-by: Pavel Emelyanov <xemul@openvz.org>
Acked-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoFix lost export-dynamic
Vitaliy Gusev [Mon, 17 Dec 2007 13:06:38 +0000 (16:06 +0300)]
Fix lost export-dynamic

get_link_kind() fails for statically linked modules (vlan, veth, etc.) if "ip"
was linked without "export-dynamic".

Signed-off-by: Vitaliy Gusev <vgusev@openvz.org>
--
Thank,
Vitaliy Gusev
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agorto_min value display overflow
YOSHIFUJI Hideaki / 吉藤英明 [Fri, 21 Dec 2007 13:58:04 +0000 (22:58 +0900)]
rto_min value display overflow

Reported by: Satoru SATOH <satoru.satoh@gmail.com>
"ip route show" does not print correct value when larger rto_min is
set (e.g. 3sec).

This problem is because of overflow in print_route() and
the patch below is a workaround fix for that.

[root test]# ./iproute2.git.org/ip/ip route show dev eth1
192.168.140.0/24  proto kernel  scope link  src 192.168.140.130
169.254.0.0/16  scope link
[root test]# ./iproute2.git.org/ip/ip route change 192.168.140.0/24
dev eth1 rto_min 3s
[root test]# ./iproute2.git.org/ip/ip route show dev eth1
192.168.140.0/24  scope link  rto_min lock 2ms     <-- wrong
169.254.0.0/16  scope link
[root test]# ./iproute2.git/ip/ip route show dev eth1  # patched version
192.168.140.0/24  scope link  rto_min lock 3000ms  <-- correct
169.254.0.0/16  scope link

This is a simpler fix.

Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agonetem potential dist table overflow
Stephen Hemminger [Wed, 12 Dec 2007 23:02:51 +0000 (15:02 -0800)]
netem potential dist table overflow

Fix possible stack overflow when given distribution table that is
too large.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoiproute2-2.6.23: RFC4214 Support (v2.5)
Templin, Fred L [Mon, 26 Nov 2007 17:46:06 +0000 (09:46 -0800)]
iproute2-2.6.23: RFC4214 Support (v2.5)

This patch includes support for the Intra-Site Automatic Tunnel
Addressing Protocol (ISATAP) per RFC4214.

The following diffs are specific to the iproute2-2.6.23
software distribution. This message includes the full and
patchable diff text; please use this version to apply patches.

Signed-off-by: Fred L. Templin <fred.l.templin@boeing.com>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoMerge branch 'master' into net-2.6.25
Stephen Hemminger [Tue, 11 Dec 2007 18:04:33 +0000 (10:04 -0800)]
Merge branch 'master' into net-2.6.25

16 years agoFix dotted quad for bit order
Stephen Hemminger [Tue, 11 Dec 2007 18:03:28 +0000 (10:03 -0800)]
Fix dotted quad for bit order

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoiproute2: support dotted-quad netmask notation.
Andreas Henriksson [Fri, 7 Dec 2007 23:41:34 +0000 (00:41 +0100)]
iproute2: support dotted-quad netmask notation.

On tor, 2007-12-06 at 11:53 -0800, Stephen Hemminger wrote:
> On Tue, 4 Dec 2007 14:58:18 +0100
> Andreas Henriksson <andreas@fatal.se> wrote:
>
> > Suggested patch for allowing netmask to be specified in dotted quad format.
> > See http://bugs.debian.org/357172
> >
> > (Known problem: this will not prevent some invalid syntaxes,
> > ie. "255.0.255.0" will be treated as "255.255.255.0")
> >
> > Comments? Suggestions? Improvements?
>
> Fix the bug you mentioned?
>
> [... snip example code ...]

Updated patch, added your netmask validation code but without the check
that made 0.0.0.0 (default) and 255.255.255.255 (one address) invalid
netmasks as they are permitted in CIDR format.

Signed-off-by: Andreas Henriksson <andreas@fatal.se>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agotc mask patch
François Delawarde [Mon, 26 Nov 2007 17:13:24 +0000 (18:13 +0100)]
tc mask patch

Hello Stephen,

As the current maintainer of iproute2 package, you could be interested
in including the attached patch that allow using masks in the fw filter
of the tc utility (very useful at least for me). AFAK, it works at least
from iproute2 version 2.6.20-?. Feel free to make the appropriate
cleaning changes if necessary, or contact me if you see any trouble.

Best regards,
François Delawarde.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoCorrect documentation regarding PROMISC and ALLMULTI.
Tomas Janousek [Tue, 20 Nov 2007 14:38:21 +0000 (15:38 +0100)]
Correct documentation regarding PROMISC and ALLMULTI.

The ip util would happily change these flags, it's just not recommended.
Reflect that in the doc.

The behaviour of ifconfig is exactly the same as of ip, delete the note about
it.

Signed-off-by: Tomas Janousek <tjanouse@redhat.com>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoAdd NAT action
Herbert Xu [Fri, 12 Oct 2007 09:08:40 +0000 (17:08 +0800)]
Add NAT action

Here's a patch to add support for the nat action which is now
in the kernel.

Thanks,
--
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
--

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoAdd NAT action
Herbert Xu [Fri, 12 Oct 2007 09:08:40 +0000 (17:08 +0800)]
Add NAT action

Here's a patch to add support for the nat action which is now
in the kernel.

Thanks,
--
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
--

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agorlim qdisc support
Stephen Hemminger [Mon, 10 Dec 2007 21:10:20 +0000 (13:10 -0800)]
rlim qdisc support

Add support for new rate limit qdisc

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoFix off by one in nested attribute management.
Stephen Hemminger [Mon, 10 Dec 2007 19:34:40 +0000 (11:34 -0800)]
Fix off by one in nested attribute management.

Fixes segv in:
  tc qdisc show dev eth1
due to uninitialized attribute table.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoFix breakage from netfilter/ip_tables header change.
Stephen Hemminger [Mon, 10 Dec 2007 17:40:45 +0000 (09:40 -0800)]
Fix breakage from netfilter/ip_tables header change.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoFix breakage from netfilter/ip_tables header change.
Stephen Hemminger [Mon, 10 Dec 2007 17:40:45 +0000 (09:40 -0800)]
Fix breakage from netfilter/ip_tables header change.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoMerge header file changes from net-2.6.25
Stephen Hemminger [Mon, 10 Dec 2007 17:36:07 +0000 (09:36 -0800)]
Merge header file changes from net-2.6.25

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years ago2.6.24-rc3 headers
Stephen Hemminger [Thu, 29 Nov 2007 21:56:15 +0000 (13:56 -0800)]
2.6.24-rc3 headers

Resync santized headers with 2.6.24-rc3

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoiproute 2.6.23 incompatibility
Patrick McHardy [Thu, 25 Oct 2007 17:46:29 +0000 (19:46 +0200)]
iproute 2.6.23 incompatibility

Arkadiusz Miskiewicz wrote:
> People are reporting that
>> ip link set multicast on dev eth0 (Invalid argument)
>> no longer works when using iproute 2.6.23 on kernel 2.6.21.
>>
>> On my testing machine it also fails:
>> # ./ip link set eth0 multicast on
>> RTNETLINK answers: Invalid argument

It seems it fails to properly detect that your kernel is missing
RTM_NEWLINK support. Apparently the reason is that the kernels
I tested with return a different error in this situation.

Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoFix typo in tunnel code (o_key vs. i_key).
Herbert Xu [Fri, 12 Oct 2007 08:56:40 +0000 (10:56 +0200)]
Fix typo in tunnel code (o_key vs. i_key).

If a dotted quad ikey is specified for GRE tunnels, it gets set as the
okey instead.  This patch fixes it. (http://bugs.debian.org/200714)

Signed-off-by: Andreas Henriksson <andreas@fatal.se>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoFix corruption when using batch files with comments and broken lines.
Andreas Henriksson [Fri, 12 Oct 2007 08:56:42 +0000 (10:56 +0200)]
Fix corruption when using batch files with comments and broken lines.
The problem was that length of allocation changed but caller not told.

Anyway, the patch fixes a problem resulting in a double free
that occurs when using batch files that contains a special combination
of broken up lines and comments as reported in:
http://bugs.debian.org/398912

Thanks to Michal Pokrywka <mpokrywka@hoga.pl> for testcase and information
on which conditions problem could be reproduced under.

Signed-off-by: Andreas Henriksson <andreas@fatal.se>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoRemove bogus reference to tc-filters(8) from tc(8) manpage.
Andreas Barth [Fri, 12 Oct 2007 08:56:41 +0000 (10:56 +0200)]
Remove bogus reference to tc-filters(8) from tc(8) manpage.

Spotted by Aleš Kozumplík <al_es@seznam.cz>
(http://bugs.debian.org/289225)

Signed-off-by: Andreas Henriksson <andreas@fatal.se>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoAdd parameters to usage help text.
Alexander Wirt [Fri, 12 Oct 2007 08:56:37 +0000 (10:56 +0200)]
Add parameters to usage help text.

Add src option to route help text (http://bugs.debian.org/226142).
Add prio option to rule prio help text (http://bugs.debian.org/213673).

Signed-off-by: Andreas Henriksson <andreas@fatal.se>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoFix various typos and nitpicks
Alexander Wirt [Fri, 12 Oct 2007 08:56:36 +0000 (10:56 +0200)]
Fix various typos and nitpicks

Fix typo in ss manpage.
Make the backslash visible in ip manpage (http://bugs.debian.org/285507).
Strict syntax for ip addr advice in error message.
Fix typo in libnetlink(3) manpage (writen -> written).
Fix typos in tc-prio(8) manpage.
Fix typo in tc-htb(8) manpage (mininum -> minimum).
Fix typo in tc-cbq-details(8) manpage (occured -> occurred).

Signed-off-by: Andreas Henriksson <andreas@fatal.se>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoadd q_rr to tc Makefile
Stephen Hemminger [Tue, 16 Oct 2007 21:27:42 +0000 (14:27 -0700)]
add q_rr to tc Makefile

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoUpdate snapshot for release
Stephen Hemminger [Tue, 16 Oct 2007 21:26:51 +0000 (14:26 -0700)]
Update snapshot for release

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoAlso do tc_core_time2big argument (long->unsigned).
Andreas Henriksson [Fri, 12 Oct 2007 12:37:09 +0000 (14:37 +0200)]
Also do tc_core_time2big argument (long->unsigned).

tc_core_time2big only used in tc/q_netem.c where it gets passed an unsigned.

Signed-off-by: Andreas Henriksson <andreas@fatal.se>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoSwitch helpers tc_core_{time2ktime,ktime2time} from long to unsigned as well.
Andreas Henriksson [Fri, 12 Oct 2007 11:49:49 +0000 (13:49 +0200)]
Switch helpers tc_core_{time2ktime,ktime2time} from long to unsigned as well.

Follow up patch to "Fix overflow in time2tick / tick2time." which switches
the remaining two helper functions from long to unsigned as well.
These functions are only used in "tc/q_hfsc.c" where both the passed argument
and the place the return value is stored are unsigned/u32 variables, so this
change should be safe to make but hasn't been tested as extensively as the
time2tick patch.

Signed-off-by: Andreas Henriksson <andreas@fatal.se>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoPrevent renaming interfaces to empty string.
Patrick McHardy [Fri, 12 Oct 2007 12:01:13 +0000 (14:01 +0200)]
Prevent renaming interfaces to empty string.

Andreas Henriksson wrote:
> From: Alexander Wirt <formorer@debian.org>
>
>
> Signed-off-by: Andreas Henriksson <andreas@fatal.se>
> ---
>  ip/iplink.c |    4 ++++
>  1 files changed, 4 insertions(+), 0 deletions(-)
>
> diff --git a/ip/iplink.c b/ip/iplink.c
> index 4060845..da1f64e 100644
> --- a/ip/iplink.c
> +++ b/ip/iplink.c
> @@ -670,6 +670,10 @@ static int do_set(int argc, char **argv)
>   }
>
>   if (newname && strcmp(dev, newname)) {
> + if (strlen(newname) == 0) {
> +     printf("\"\" is not valid device identifier\n");
> +     return -1;
> + }

Indentation fixed, same change for the non-ioctl case, use invarg.
While I'm at it I also fixed the error message for "name too long",
*argv is NULL at this point.

Signed-off-by: Patrick McHardy <kaber@trash.net>
16 years agoRevert "don't allow "" for device name"
Stephen Hemminger [Fri, 12 Oct 2007 22:44:44 +0000 (15:44 -0700)]
Revert "don't allow "" for device name"

Use Patrick's instead

This reverts commit ba371d989038e0dda803528c194e12e5177f7008.

16 years agoRevert "Remove bogus reference to tc-filters(8) from tc(8) manpage."
Stephen Hemminger [Fri, 12 Oct 2007 22:44:07 +0000 (15:44 -0700)]
Revert "Remove bogus reference to tc-filters(8) from tc(8) manpage."

This reverts commit 1bacc7ce752f795df3b1b3710245c4cd8c1bc396.

16 years agoDrop bogus reference to tc-filters and add lartc.org link to manpage.
Alexander Wirt [Fri, 12 Oct 2007 08:56:47 +0000 (10:56 +0200)]
Drop bogus reference to tc-filters and add lartc.org link to manpage.

Signed-off-by: Andreas Henriksson <andreas@fatal.se>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoFix overflow in time2tick / tick2time.
Andreas Henriksson [Fri, 12 Oct 2007 08:56:46 +0000 (10:56 +0200)]
Fix overflow in time2tick / tick2time.

The helper functions gets passed an unsigned int, which gets cast to long
and overflows. See http://bugs.debian.org/175462

Signed-off-by: Andreas Henriksson <andreas@fatal.se>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoAdd new rtacct/nstat manpages and additional symlinks.
Andreas Henriksson [Fri, 12 Oct 2007 08:56:44 +0000 (10:56 +0200)]
Add new rtacct/nstat manpages and additional symlinks.

Symlink rtstat(8) and ctstat(8) to lnstat(8).
Add rtacct/nstat manpage based on doc/nstat.sgml as rtacct(8).
Symlink nstat(8) to rtacct(8).
Add arpd(8) symlink based on doc/arpd.sgml.

Signed-off-by: Andreas Henriksson <andreas@fatal.se>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoFix ematch cmp and nbyte syntax help text.
Lionel Elie Mamane [Fri, 12 Oct 2007 08:56:43 +0000 (10:56 +0200)]
Fix ematch cmp and nbyte syntax help text.

The help/usage screen of ematch cmp and nbyte say recognised symbolic
values for "layer FOO" are link, header and next-header, but the code
does _not_ implement that: it will recognise "next-header" as what is
supposed to be "header" and will not recognise "header". The right
symbolic values seem to be link, network, transport. Here is a patch
that changes the help/usage screen to match the code.
(http://bugs.debian.org/438653)

Signed-off-by: Andreas Henriksson <andreas@fatal.se>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoRemove bogus reference to tc-filters(8) from tc(8) manpage.
Andreas Barth [Fri, 12 Oct 2007 08:56:41 +0000 (10:56 +0200)]
Remove bogus reference to tc-filters(8) from tc(8) manpage.

Spotted by Aleš Kozumplík <al_es@seznam.cz>
(http://bugs.debian.org/289225)

Signed-off-by: Andreas Henriksson <andreas@fatal.se>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agodon't allow "" for device name
Stephen Hemminger [Fri, 12 Oct 2007 21:43:03 +0000 (14:43 -0700)]
don't allow "" for device name

If a zero-length string is given, it is not rejected by
netlink in kernel so catch it at command line.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoremove support for IP multipath
Stephen Hemminger [Fri, 12 Oct 2007 21:38:30 +0000 (14:38 -0700)]
remove support for IP multipath

IP multipath routing was so buggy that it was dropped from the
current kernel.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoremove outdated netbug script.
Stephen Hemminger [Fri, 12 Oct 2007 20:50:43 +0000 (13:50 -0700)]
remove outdated netbug script.

Haven't received a bug from this script in years.
And it has several race conditions, etc.

See http://bugs.debian.org/289541, http://bugs.debian.org/313540,
http://bugs.debian.org/313541, and http://bugs.debian.org/313544.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoIPROUTE2: Support IPv4/IPv6 Tunnel
YOSHIFUJI Hideaki / 吉藤英明 [Fri, 12 Oct 2007 07:51:22 +0000 (16:51 +0900)]
IPROUTE2: Support IPv4/IPv6 Tunnel

Based on patch from Yasuyuki KOZAKAI <yasuyuki.kozakai@toshiba.co.jp>.

Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agorto support for ip command
Rick Jones [Thu, 11 Oct 2007 20:04:11 +0000 (13:04 -0700)]
rto support for ip command

Enable users of ip to specify the times for rtt, rttvar and rto_min
in human-friendly terms a la "tc" while maintaining backwards
compatability with the previous "raw" mechanism.  Builds upon
David Miller's uncommited patch to set rto_min.

Signed-off-by: Rick Jones <rick.jones2@hp.com>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agodon't make veth a shared library
Stephen Hemminger [Thu, 11 Oct 2007 20:01:42 +0000 (13:01 -0700)]
don't make veth a shared library

Making veth a shared library for ip caused build problems (not PIC)
and is unneeded.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoMerge 192.168.0.5:src/iproute2
Stephen Hemminger [Thu, 11 Oct 2007 19:43:27 +0000 (12:43 -0700)]
Merge 192.168.0.5:src/iproute2

16 years agolnstat : force a flush before sleep
Eric Dumazet [Thu, 27 Sep 2007 12:26:09 +0000 (14:26 +0200)]
lnstat : force a flush before sleep

Hi Stephen

This small patch allows to use lnstat/rtstat with a pipe output, without a full bufferisation.

Thank you
Eric

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years ago2.6.23 kernel headers
Stephen Hemminger [Thu, 11 Oct 2007 19:39:12 +0000 (12:39 -0700)]
2.6.23 kernel headers

Update headers to sanitized versions of 2.6.23 final

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoUpdate kernel headers to 2.6.23-rc5
Stephen Hemminger [Wed, 5 Sep 2007 12:05:21 +0000 (13:05 +0100)]
Update kernel headers to 2.6.23-rc5

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
16 years agoip: xfrm: Fix flush message.
Masahide NAKAMURA [Fri, 24 Aug 2007 02:05:24 +0000 (11:05 +0900)]
ip: xfrm: Fix flush message.

Fix xfrm state or policy flush message.
And minor updates are included:
o Use static buffer to show unknown value as string.
o Show policy type (ptype) only when kernel specified it.
o Clean-up xfrm_monitor.

Signed-off-by: Masahide NAKAMURA <nakam@linux-ipv6.org>
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>