Commit Graph

1442 Commits

Author SHA1 Message Date
Stephen Hemminger
a08d2590a0 Update to kernel v3.3 headers
Initial merge window version of headers
2012-01-10 10:50:02 -08:00
Stephen Hemminger
aab2702d33 Fix man page whatis entry errors
lintian says:
W: iproute: manpage-has-bad-whatis-entry usr/share/man/man7/tc-hfsc.7.gz
W: iproute: manpage-has-bad-whatis-entry usr/share/man/man8/ip-address.8.gz
W: iproute: manpage-has-bad-whatis-entry usr/share/man/man8/ip-addrlabel.8.gz
W: iproute: manpage-has-bad-whatis-entry usr/share/man/man8/ip-link.8.gz
W: iproute: manpage-has-bad-whatis-entry usr/share/man/man8/ip-maddress.8.gz
W: iproute: manpage-has-bad-whatis-entry usr/share/man/man8/ip-monitor.8.gz
W: iproute: manpage-has-bad-whatis-entry usr/share/man/man8/ip-mroute.8.gz
W: iproute: manpage-has-bad-whatis-entry usr/share/man/man8/ip-neighbour.8.gz
W: iproute: manpage-has-bad-whatis-entry usr/share/man/man8/ip-netns.8.gz
W: iproute: manpage-has-bad-whatis-entry usr/share/man/man8/ip-ntable.8.gz
W: iproute: manpage-has-bad-whatis-entry usr/share/man/man8/ip-route.8.gz
W: iproute: manpage-has-bad-whatis-entry usr/share/man/man8/ip-rule.8.gz
W: iproute: manpage-has-bad-whatis-entry usr/share/man/man8/ip-tunnel.8.gz
W: iproute: manpage-has-bad-whatis-entry usr/share/man/man8/ip-xfrm.8.gz
2012-01-10 10:47:28 -08:00
Stephen Hemminger
13603f6a9e iplt2p: remove unused libnl headers
Leftover from change to original code.
2012-01-10 08:50:49 -08:00
Stephen Hemminger
447c118f13 v3.2.0 2012-01-05 08:34:31 -08:00
Jan Engelhardt
8e91a80d97 iproute2: fix calling up the xt action
Upsteam: has not been sent yet

Requesting the xt action never succeeded because it registered
using the wrong name.
2012-01-03 15:07:38 -08:00
Jan Engelhardt
d7aa57d450 iproute2: proper detection of libxtables position and flags
Upstream: not sent yet

Any tests involving iptables _MUST_ utilize pkg-config to find the
proper locations of the installation.
2012-01-03 15:05:25 -08:00
Stephen Hemminger
6c513a0061 README cleanup's
Spell check the README files and remove out of date release notes.
2012-01-03 15:04:55 -08:00
Stephen Hemminger
155ad8023b ematch: fix warning about unused input()
Use existing compile flag to indicate that input() is not used
by tc ematch, fixes compiler warning.
2012-01-03 13:55:59 -08:00
Stephen Hemminger
5761f04fb8 ematch: fix warning about yyerror and const
yyerror() should take const char * on current bison.
2012-01-03 13:55:00 -08:00
Jan Engelhardt
f5b830dc5d iproute2: avoid use of implicit declarations
gcc -DLIBDIR=\"/usr/lib64\" -D_GNU_SOURCE -fmessage-length=0 -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -g -Wstrict-prototypes -fPIC -DXT_LIB_DIR=\"/usr/lib64/xtables\" -I../include -DRESOLVE_HOSTNAMES -DLIBDIR=\"/usr/lib64\" -fPIC   -c -o ipx_pton.o ipx_pton.c
In file included from ../include/utils.h:8:0,
                 from ipx_ntop.c:5:
../include/libnetlink.h: In function 'rta_getattr_u64':
../include/libnetlink.h:84:2: warning: implicit declaration of function 'memcpy'
../include/libnetlink.h:84:2: warning: incompatible implicit declaration of built-in function 'memcpy'
2012-01-03 13:48:04 -08:00
Stephen Hemminger
38cd311ade l2tp: Add l2tp support
Based on earlier implementation by James Chapman. But instead of
dragging in all of libnl, use existing libnetlink infrastructure.
2011-12-29 09:35:37 -08:00
Stephen Hemminger
46c5d64d69 libnetlink: add attribute access inline functions
Based on idea in libmnl, add attribute access functions instead
of explicitly exposing casts. Also handle possible alignment issues
of u64.
2011-12-29 09:29:33 -08:00
Stephen Hemminger
cd70f3f522 libnetlink: remove unused junk callback
Both rtnl_talk and rtnl_dump had a callback for handling portions
of netlink message that do not match the correct pid or seq.
But this callback was never used by any part of iproute2 so remove
it.
2011-12-28 10:37:12 -08:00
Eric Dumazet
d060de7f8d netem: fix a typo in explain()
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
2011-12-24 11:21:33 -08:00
Stephen Hemminger
2aa3dd29a7 libnetlink: add more attribute functions
New functions to handle u8, u16, u32, u64 and string attribute types.
Use common code for all attribute wrappers.
2011-12-23 10:43:54 -08:00
Stephen Hemminger
6cf8398f5f libnetlink: change rtnl_send() to take void *
Avoid having to cast buffer being sent.
2011-12-23 10:41:50 -08:00
Stephen Hemminger
3c7950af59 netem: add support for 4 state and GE loss model
Incorporate support for new loss models.
2011-12-22 17:08:11 -08:00
Stephen Hemminger
fd6fac34e9 netem: fix man page
Format man page with conventional style (BNF and italics) to make
it match other pages.

Fix loss model options to match what will implemented!
2011-12-22 16:50:54 -08:00
Stephen Hemminger
1b1177ed5f Update to latest 3.2 kernel headers
Keep in sync
2011-12-22 10:40:39 -08:00
Stephen Hemminger
2a9721f1c4 Split up ip man page
The man page for ip command had grown too large to be readable.
Break it up into separate pages.
2011-12-22 10:34:03 -08:00
Florian Westphal
2587c01a0e tc: man: add man page for stochastic fair blue
With help from Eric Dumazet.
Man page is derived in parts from README file contained in
Juliusz Chroboczeks original sfb kernel patch.
2011-12-22 08:54:26 -08:00
Eric Dumazet
841fc7bc98 red: harddrop support and cleanups
Add harddrop support (kernel support added a long time ago), and various
cleanups.

min BYTES, max BYTES are now optional and follow Sally Floyd's
recommendations.

By the way, our default 2% probability is a bit low, Sally recommends 10%.
Not a big deal if upcoming adaptative algo is deployed.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
2011-12-08 16:43:18 -08:00
Hagen Paul Pfeifer
cd72dcf13c netem: add man-page
Signed-off-by: Hagen Paul Pfeifer <hagen@jauu.net>
2011-12-01 09:26:35 -08:00
Eric Dumazet
ab15aeacf5 red: make burst optional
Documentation advises to set burst to (min+min+max)/(3*avpkt)

Let tc do this automatically if user doesnt provide burst himself.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
2011-12-01 09:23:49 -08:00
Eric Dumazet
0cf67ead7b red: give a hint about burst value
Check for burst values that are too small.

Reported-by: Dave Taht <dave.taht@gmail.com>
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
2011-12-01 09:23:43 -08:00
Greg Rose
7b8179c780 iproute2: Add new command to ip link to enable/disable VF spoof check
Add ip link command parsing for VF spoof checking enable/disable

V2 - Fixed problem with parsing of dump info on kernels that don't
     support the spoof checking option and also wrapped the ifla_vf_info
     structure in #ifdef __KERNEL__ to prevent user space from directly
     accessing the structure
V3 - Improved parsing of vfinfo
V4 - Put Makefile back to proper list of subdirs
V5 - Remove struct ifla_vf_info, it is only used by the kernel
V6 - Make sure spoof check is reported by the driver - rtnl will set
     it to -1 to indicate driver didn't report a value.

Signed-off-by: Greg Rose <gregory.v.rose@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2011-11-23 14:53:12 -08:00
Eric Dumazet
719b958bbd ss: report ecnseen
Support ECNSEEN reporting in ss command.

ESTAB      0      0           10.170.73.123:4900
10.170.73.125:51001    uid:501 ino:385994 sk:f31e5f00
         mem:(r0,w0,f0,t0) ts sack ecn ecnseen bic wscale:8,8 rto:210
rtt:18.75/15 ato:40 cwnd:10 send 69.9Mbps rcv_space:32768

"ecn" means TCP session negociated ECN capability (TCP layer) at setup
time

"ecnseen" at least one frame with ECT(0) or ECT(1) or ECN (IP layer) was
received from peer.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
2011-11-23 14:51:54 -08:00
Thomas Jarosch
fcbd0165fc tc: Use correct variable type for get_distribution() result
get_distribution() returns an int.

cppcheck reported:
[tc/q_netem.c:243]: (style) Checking if unsigned variable 'dist_size' is less than zero.

The mismatch actually rendered the error checking
after get_distribution() ineffective.

Signed-off-by: Thomas Jarosch <thomas.jarosch@intra2net.com>
2011-11-23 14:46:24 -08:00
Thomas Jarosch
a3da01c519 tc: Remove unused variable 'res'.
Detected by cppcheck.

Signed-off-by: Thomas Jarosch <thomas.jarosch@intra2net.com>
2011-11-23 14:46:21 -08:00
Stephen Hemminger
9044a4547d Update to 3.2.0-rc2 headers 2011-11-23 14:34:49 -08:00
Stephen Hemminger
9cbe6bc337 v3.1.0 2011-11-17 16:53:50 -08:00
Petr Šabata
16963ce6f0 Display closed UDP sockets on 'ss -ul'
This patch emulates 'netstat -ul' behavior, showing 'closed'
(state 07) UDP sockets when ss is called with '-ul' options.
Although dirty, this seems like the least invasive way to fix
it and shouldn't really break anything.

Signed-off-by: Petr Šabata <contyk@redhat.com>
2011-11-16 09:32:20 -08:00
Stephen Hemminger
93ba481acb cleanup ematch yacc files
make clean needs to remove all the yacc output files for ematch.
2011-11-02 16:39:36 -07:00
Michal Soltys
9bac173fa6 HFS manpage changes
Few minor changes and small additions.
2011-11-02 16:35:32 -07:00
Michal Soltys
41f6004139 HFSC (7) & (8) documentation + assorted changes
This patch adds detailed documentation for HFSC scheduler. It roughly
follows HFSC paper, but tries to not rely too much on math side of things.
Post-paper/Linux specific subjects (timer resolution, ul service curve, etc.)
are also discussed.

I've read it many times over, but it's a lengthy chunk of text - so try
to be understanding in case I made some mistakes.

tc-hfsc(7): explains algorithm in detail (very long)
tc-hfsc(8): explains command line options briefly
tc(8): adds references to new man pages
Makefile: adds man7 directory to install target
q_hfsc.c: minimal help text changes, consistency with tc-hfsc(8)

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2011-11-02 16:33:50 -07:00
Mike Frysinger
aa48b5931a tc: fix parallel build file with lex/yacc
Building iproute2 in parallel might hit the race failure:
	emp_ematch.l:2:30: fatal error: emp_ematch.yacc.h:
		No such file or directory
	make[1]: *** [emp_ematch.lex.o] Error 1

This is because we currently allow the yacc/lex files to generate and
compile in parallel.  So add a simple dependency to make sure yacc has
finished before we attempt to compile the lex output.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2011-10-18 15:02:21 -07:00
Stephen Hemminger
7397944de6 ip: fix exit codes
Alternative fix to problem reported by: Bin Li
The issue is came from https://bugzilla.novell.com/show_bug.cgi?id=681952.

In any previous version (since suse ... 10.0?), ip addr add always returned
the error code 2 in case the ip address is already set on the interface:

    inet 172.16.2.3/24 brd 172.16.2.255 scope global bond0
RTNETLINK answers: File exists
2

On 11.4, it returns the exit code 254:

    inet 172.16.1.1/24 brd 172.16.1.255 scope global eth0
RTNETLINK answers: File exists
254

This of course causes ifup to return an error in this quite common case..
2011-10-13 08:38:33 -07:00
Thomas Jarosch
788731b320 Fix unterminated readlink() buffer usage
Signed-off-by: Thomas Jarosch <thomas.jarosch@intra2net.com>
2011-10-13 08:16:56 -07:00
Stephen Hemminger
707f612c00 Update to 3.1-rc9 kernel headers
Align header files with sanitized version of headers in kernel.
2011-10-10 11:02:42 -07:00
Stephen Hemminger
ce691fb5ce v3.0.0 2011-10-10 08:59:54 -07:00
Stephen Hemminger
b702f9cc37 ip: fix man page warnings
Fix usage of ".R" which is not man macro.
2011-10-10 08:55:56 -07:00
Thomas Jarosch
19bcc05bea Fix file descriptor leak on error in read_igmp()
Detected by cppcheck.

Signed-off-by: Thomas Jarosch <thomas.jarosch@intra2net.com>
2011-10-07 11:20:23 -07:00
Thomas Jarosch
297452a1c2 Fix file descriptor leak in do_tunnels_list()
Detected by cppcheck.

Signed-off-by: Thomas Jarosch <thomas.jarosch@intra2net.com>
2011-10-07 11:20:22 -07:00
Thomas Jarosch
e588a7db16 Fix file descriptor leak on error in read_mroute_list()
Detected by cppcheck.

Signed-off-by: Thomas Jarosch <thomas.jarosch@intra2net.com>
2011-10-07 11:20:21 -07:00
Thomas Jarosch
67ef60a293 Fix file descriptor leak on error in read_viftable()
Detected by cppcheck.

Signed-off-by: Thomas Jarosch <thomas.jarosch@intra2net.com>
2011-10-07 11:18:41 -07:00
Thomas Jarosch
25352af7c2 Fix file descriptor leak on error in iproute_flush_cache()
Detected by cppcheck.

Signed-off-by: Thomas Jarosch <thomas.jarosch@intra2net.com>
2011-10-07 11:18:09 -07:00
Thomas Jarosch
e9a927dc08 Add missing closedir() call in do_show()
Detected by cppcheck.

Signed-off-by: Thomas Jarosch <thomas.jarosch@intra2net.com>
2011-10-07 11:17:41 -07:00
Thomas Jarosch
1a6543c56b Fix memory leak of lname variable in get_target_name()
Detected by cppcheck.

Signed-off-by: Thomas Jarosch <thomas.jarosch@intra2net.com>
2011-10-07 11:17:10 -07:00
Thomas Jarosch
9f1ba57016 Fix wrong sanity check in choke_parse_opt()
Detected by cppcheck.

Signed-off-by: Thomas Jarosch <thomas.jarosch@intra2net.com>
2011-10-07 11:17:03 -07:00
Thomas Jarosch
6d5ee98a7c Fix wrong comparison in cmp_print_eopt()
Detected by cppcheck.

Signed-off-by: Thomas Jarosch <thomas.jarosch@intra2net.com>
2011-10-07 11:16:15 -07:00