Go to file
David Ahern 8e7548462e Merge branch 'unify_tunnel_help' into next
Serhey Popovych  says:

====================

To show only relevant diffs of ip and ipv6 variants help message print
routines needs to be unified and improved.

Get rid of print_usage() and usage() wrappers: use single function to
output help message. As side effect we return -1 from parse function
instead of calling exit(2) in case of "... tunnel <help|garbage>" is
found.

Additionally we get pointer to @struct link_util and can directly access
->id information to prepare customized help message.

Split calls to fprintf() two group: one that contains format string with
specifiers (thus requiring parameters) and another one that does not.
This helps compiler to optimize calls to fprintf() with fputs() when no
format specifiers in string. Do not use fputs() directly to keep code
formatting nice.

After this series applied following diffs:

  # diff -urN ip/link_gre{,6}.c
  # diff -urN ip/link_vti{,6}.c
  # diff -urN ip/link_ip{,6}tnl.c

in scope of help print routines reduced to necessary minimum.

Tested minimally by compiling and executing "ip link help <kind>" and
"ip link add type help" commands. Looks correct.

See individual patch description for more information.

Reviews, commands and suggestions are welcome.

====================

Signed-off-by: David Ahern <dsahern@gmail.com>
2018-02-09 08:04:39 -08:00
bash-completion tc: bash-completion: add missing 'classid' keyword 2017-12-12 12:11:37 -08:00
bridge iplink: Use ll_name_to_index() instead of if_nametoindex() 2018-01-23 14:50:59 -08:00
devlink devlink: Ignore unknown attributes 2018-01-18 16:30:36 -08:00
doc/actions doc: drop old ip command documentation 2017-09-29 10:51:02 -07:00
etc/iproute2 whitespace cleanup 2017-01-12 17:31:20 -08:00
examples SPDX license identifiers 2017-11-24 12:21:35 -08:00
genl SPDX license identifiers 2017-11-24 12:21:35 -08:00
include ip: Introduce get_rtnl_link_stats_rta() to get link statistics 2018-02-07 16:15:28 -08:00
ip iptnl/ip6tnl: Unify iptunnel_print_help() 2018-02-09 08:04:23 -08:00
lib ip: Introduce get_rtnl_link_stats_rta() to get link statistics 2018-02-07 16:15:28 -08:00
man tc: implement ingress/egress block index attributes for qdiscs 2018-01-21 10:42:57 -08:00
misc ss: fix NULL pointer access when parsing unix sockets with oldformat 2018-01-09 08:02:46 -08:00
netem SPDX license identifiers 2017-11-24 12:21:35 -08:00
rdma Merge branch 'master' into net-next 2018-01-08 10:10:45 -08:00
schema bridge: add json schema for bridge fdb show 2016-07-20 12:02:02 -07:00
tc treewide: Use addattr_nest()/addattr_nest_end() to handle nested attributes 2018-02-02 15:01:09 -08:00
testsuite tests: make sure rand_dev suffix has 6 chars 2018-01-10 08:29:51 -08:00
tipc devlink, rdma, tipc: properly define TARGETS without HAVE_MNL 2018-01-05 16:32:17 -08:00
.gitignore ignore generated Config file 2017-09-29 10:02:45 -07:00
COPYING Update address of FSF in license 2008-03-08 13:31:03 -08:00
Makefile Restore --no-print-directory option for silent builds 2018-01-09 07:58:00 -08:00
README config: put CFLAGS/LDLIBS in config.mk 2017-08-23 10:03:09 -07:00
README.decnet Decnet documentation update 2005-06-13 18:47:56 +00:00
README.devel iproute2: fix minor typo in comments 2011-07-11 10:11:09 -07:00
README.distribution README cleanup's 2012-01-03 15:04:55 -08:00
README.iproute2+tc tc, bpf: finalize eBPF support for cls and act front-end 2015-04-10 13:31:19 -07:00
README.lnstat Rename: misc/README.lnstat -> README.lnstat 2004-10-19 20:24:47 +00:00
configure SPDX license identifiers 2017-11-24 12:21:35 -08:00

README

This is a set of utilities for Linux networking.

Information:
    http://www.linuxfoundation.org/collaborate/workgroups/networking/iproute2

Download:
    http://www.kernel.org/pub/linux/utils/net/iproute2/

Repository:
    git://git.kernel.org/pub/scm/linux/kernel/git/shemminger/iproute2.git

How to compile this.
--------------------
1. libdbm

arpd needs to have the db4 development libraries. For Debian
users this is the package with a name like libdb4.x-dev.
DBM_INCLUDE points to the directory with db_185.h which
is the include file used by arpd to get to the old format Berkeley
database routines.  Often this is in the db-devel package.

2. make

The makefile will automatically build a config.mk file which
contains definitions of libraries that may or may not be available
on the system such as: ATM, ELF, MNL, and SELINUX.

3. To make documentation, cd to doc/ directory , then
   look at start of Makefile and set correct values for
   PAGESIZE=a4		, ie: a4 , letter ...	(string)
   PAGESPERPAGE=2	, ie: 1 , 2 ...		(numeric)
   and make there. It assumes, that latex, dvips and psnup
   are in your path.

4. This package includes matching sanitized kernel headers because
   the build environment may not have up to date versions. See Makefile
   if you have special requirements and need to point at different
   kernel include files.

Stephen Hemminger
stephen@networkplumber.org

Alexey Kuznetsov
kuznet@ms2.inr.ac.ru