Commit Graph

195279 Commits

Author SHA1 Message Date
Xin LI
689c8e8b46 Fix inverted logic introduced in r272154.
Noticed by:	trasz
MFC after:	2 weeks
2014-12-01 20:51:01 +00:00
Rui Paulo
afe2c75694 Allow multiple devices to mmap. It's impossible to prevent this with
checks on the open/close functions.

MFC after:	1 week
2014-12-01 19:48:23 +00:00
Alexander Motin
238e75e505 Document ISP 2532 support and hint.isp.0.vports tunable.
MFC after:	1 week
2014-12-01 17:51:16 +00:00
Ed Maste
3194293903 Build infrastructure for elftoolchain tools
Set WITH_ELFTOOLCHAIN_TOOLS in src.conf to use the elftoolchain version
of the following tools:

 * addr2line
 * elfcopy (strip / mcs)
 * nm
 * size
 * strings

Reviewed by:	bapt (earlier version)
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D1224
2014-12-01 17:49:42 +00:00
Konstantin Belousov
6afb32fc67 Disable recursion for the process spinlock.
Tested by:	pho
Discussed with:	jhb
Sponsored by:	The FreeBSD Foundation
MFC after:	1 month
2014-12-01 17:36:10 +00:00
Ed Maste
257d0dda42 Track libarchive API change 2014-12-01 16:10:44 +00:00
Ed Maste
310b1572ef Temporarily disable non-FreeBSD NT_ note types 2014-12-01 16:10:03 +00:00
Ed Maste
50f69bfbd6 Fix elftoolchain tools in-tree build
* make variables static
 * add header for uint*_t typedefs
2014-12-01 16:07:31 +00:00
Alexander Motin
fa91cabfbd When passing LUN IDs through treat ASCII values as fixed-length, not
interpreating NULLs as EOLs, but converting them to spaces.

SPC-4 does not tell that T10-based IDs should be NULL-terminated/padded.
And while it tells that it should include only ASCII chars (0x20-0x7F),
there are some USB sticks (SanDisk Ultra Fit), that have NULLs inside
the value.  Treating NULLs as EOLs there made those LUN IDs non-unique.

MFC after:	1 week
2014-12-01 15:21:54 +00:00
Dimitry Andric
15ad7a7c39 Pull in r209785 from upstream libc++ trunk (by Marshall Clow):
Fix a problem exposed by r208825, which caused bind (and other bits of
  libc++) to stop working. And tests

This fix is needed to support clang 3.5.0 and higher, which are more
strict about forming pointer-to-function types with cv-qualifiers or
ref-qualifiers.  See also the upstream PR <http://llvm.org/PR19742> and
<http://llvm.org/viewvc/llvm-project?rev=208825&view=rev>

Reported by:	amdmi3
MFC after:	3 days
2014-12-01 15:02:49 +00:00
Alexander Motin
7511bd04e4 Move ctlfe_onoffline() out of lock to let it sleep when needed.
Do some more other polishing while there.

MFC after:	2 weeks
2014-12-01 13:55:45 +00:00
Dag-Erling Smørgrav
5d083d287b Disable the vxlan code until the people reponsible for it can come up with
new command names that don't conflict with existing commands.

Pointy hat to:	bryanv
2014-12-01 12:59:16 +00:00
Dag-Erling Smørgrav
cd06771f0c The early-late divider was originally set to mountcritlocal. Since that
service does not run in jails, it was necessary to change it to something
else when jailed, and NETWORKING was arbitrarily chosen.  The divider was
later moved to FILESYSTEMS when it was introduced, but the logic to change
it to NETWORKING when jailed remained.  Remove it, as it no longer serves
any purpose.

PR:		194975
MFC after:	1 week
2014-12-01 12:29:59 +00:00
Dag-Erling Smørgrav
e27961a496 Allow load_rc_config to be called without a service name.
MFC after:	1 week
2014-12-01 12:17:42 +00:00
Hans Petter Selasky
c25290420e Start process of removing the use of the deprecated "M_FLOWID" flag
from the FreeBSD network code. The flag is still kept around in the
"sys/mbuf.h" header file, but does no longer have any users. Instead
the "m_pkthdr.rsstype" field in the mbuf structure is now used to
decide the meaning of the "m_pkthdr.flowid" field. To modify the
"m_pkthdr.rsstype" field please use the existing "M_HASHTYPE_XXX"
macros as defined in the "sys/mbuf.h" header file.

This patch introduces new behaviour in the transmit direction.
Previously network drivers checked if "M_FLOWID" was set in "m_flags"
before using the "m_pkthdr.flowid" field. This check has now now been
replaced by checking if "M_HASHTYPE_GET(m)" is different from
"M_HASHTYPE_NONE". In the future more hashtypes will be added, for
example hashtypes for hardware dedicated flows.

"M_HASHTYPE_OPAQUE" indicates that the "m_pkthdr.flowid" value is
valid and has no particular type. This change removes the need for an
"if" statement in TCP transmit code checking for the presence of a
valid flowid value. The "if" statement mentioned above is now a direct
variable assignment which is then later checked by the respective
network drivers like before.

Additional notes:
- The SCTP code changes will be committed as a separate patch.
- Removal of the "M_FLOWID" flag will also be done separately.
- The FreeBSD version has been bumped.

MFC after:	1 month
Sponsored by:	Mellanox Technologies
2014-12-01 11:45:24 +00:00
Poul-Henning Kamp
32dbae6619 Face the fact that we have no idea where the ports tree really lives. 2014-12-01 10:17:23 +00:00
Gleb Kurtsou
c5f8185b36 Update tools/shlib-compat.
- Update dwarfdump / compiler support.
  Use hex instead of decimal for integers.
  Add boolean and restrict type definitions.
  Add options for specifing dwarfdump and objdump executables.

- Fix reporting missing symbol definitions as matching.

- Compare external variable definitions.

- Exclude special symbols like _init, _end by default.

- Fix test build.
2014-12-01 08:14:25 +00:00
Konstantin Belousov
95c4bf756a Provide mutual exclusion between zone allocation/destruction and
uma_reclaim().  Reclamation code must not see half-constructed or
destructed zones.  Do this by bracing uma_zcreate() and uma_zdestroy()
into a shared-locked sx, and take the sx exclusively in uma_reclaim().

Usually zones are not created/destroyed during the system operation,
but tmpfs mounts do cause zone operations and exposed the bug.

Another solution could be to only expose a new keg on uma_kegs list
after the corresponding zone is fully constructed, and similar
treatment for the destruction.  But it probably requires more risky
code rearrangement as well.

Reported and tested by:	pho
Discussed with:	avg
Sponsored by:	The FreeBSD Foundation
MFC after:	2 weeks
2014-11-30 20:20:55 +00:00
Jilles Tjoelker
e753a1effb sh: Remove special case for '=' in set -x; always quote it in outqstr().
I plan to make set -x output always printable using $'...'; avoiding quoting
words containing '=' is not worth the extra complexity.
2014-11-30 20:12:47 +00:00
Justin T. Gibbs
2c6bf3d90b Remove trailing whitespace. 2014-11-30 19:32:00 +00:00
Andrew Turner
b4ce9f7856 There is no need to use FUNC_END with aeabi_ldiv0 or aeabi_idiv0 as they
are aliases.

Sponsored by:	ABT Systems Ltd
2014-11-30 17:29:49 +00:00
Andrew Turner
da063e9d8c Use llabs when getting the absolute value of a long long.
Sponsored by:	ABT Ststems Ltd
2014-11-30 17:27:24 +00:00
Bryan Venteicher
abec64bc76 Cleanup and performance improvement of the virtio_blk driver
- Add support for GEOM direct completion. Depending on the benchmark,
    this tends to give a ~30% improvement w.r.t IOPs and BW.
  - Remove an invariants check in the strategy routine. This assertion
    is caught later on by an existing panic.
  - Rename and resort various related functions to make more sense.

MFC after:	1 month
2014-11-30 16:36:26 +00:00
Gleb Smirnoff
2cbcd3c198 Merge from projects/sendfile:
- Provide pru_ready function for TCP.
- Don't call tcp_output() from tcp_usr_send() if no ready data was put
  into the socket buffer.
- In case of dropped connection don't try to m_freem() not ready data.

Sponsored by:	Nginx, Inc.
Sponsored by:	Netflix
2014-11-30 13:43:52 +00:00
Gleb Smirnoff
c80ea19b38 Merge from projects/sendfile:
Provide pru_ready for AF_LOCAL sockets.  Local sockets sendsdata directly
to the receive buffer of the peer, thus pru_ready also works on the peer
socket.

Sponsored by:	Netflix
Sponsored by:	Nginx, Inc.
2014-11-30 13:40:58 +00:00
Hans Petter Selasky
78328f86e2 Fix building of some infiniband utilities by updating some header file
locations and compiler include directives.

MFC after:	3 days
Sponsored by:	Mellanox Technologies
2014-11-30 13:27:58 +00:00
Gleb Smirnoff
651e4e6a30 Merge from projects/sendfile: extend protocols API to support
sending not ready data:
o Add new flag to pru_send() flags - PRUS_NOTREADY.
o Add new protocol method pru_ready().

Sponsored by:	Nginx, Inc.
Sponsored by:	Netflix
2014-11-30 13:24:21 +00:00
Hans Petter Selasky
dcf58f92e2 Add missing libraries when linking.
MFC after:	3 days
Sponsored by:	Mellanox Technologies
2014-11-30 13:13:46 +00:00
Gleb Smirnoff
0f9d0a73a4 Merge from projects/sendfile:
o Introduce a notion of "not ready" mbufs in socket buffers.  These
mbufs are now being populated by some I/O in background and are
referenced outside.  This forces following implications:
- An mbuf which is "not ready" can't be taken out of the buffer.
- An mbuf that is behind a "not ready" in the queue neither.
- If sockbet buffer is flushed, then "not ready" mbufs shouln't be
  freed.

o In struct sockbuf the sb_cc field is split into sb_ccc and sb_acc.
  The sb_ccc stands for ""claimed character count", or "committed
  character count".  And the sb_acc is "available character count".
  Consumers of socket buffer API shouldn't already access them directly,
  but use sbused() and sbavail() respectively.
o Not ready mbufs are marked with M_NOTREADY, and ready but blocked ones
  with M_BLOCKED.
o New field sb_fnrdy points to the first not ready mbuf, to avoid linear
  search.
o New function sbready() is provided to activate certain amount of mbufs
  in a socket buffer.

A special note on SCTP:
  SCTP has its own sockbufs.  Unfortunately, FreeBSD stack doesn't yet
allow protocol specific sockbufs.  Thus, SCTP does some hacks to make
itself compatible with FreeBSD: it manages sockbufs on its own, but keeps
sb_cc updated to inform the stack of amount of data in them.  The new
notion of "not ready" data isn't supported by SCTP.  Instead, only a
mechanical substitute is done: s/sb_cc/sb_ccc/.
  A proper solution would be to take away struct sockbuf from struct
socket and allow protocols to implement their own socket buffers, like
SCTP already does.  This was discussed with rrs@.

Sponsored by:	Netflix
Sponsored by:	Nginx, Inc.
2014-11-30 12:52:33 +00:00
Enji Cooper
abcd412940 Remove duplicate FILESYSTEMS REQUIRE from etc/rc.d/ipmon and etc/rc.d/pflog 2014-11-30 12:34:48 +00:00
Andrew Turner
4c1720fd9a Correctly a few incorrect uses of ENTRY/EENTRY and END/EEND
Sponsored by:	ABT Systems Ltd
2014-11-30 12:25:04 +00:00
Andrew Turner
13fb42aabe Remove extra labels, ENTRY_NP already provides them.
Sponsored by:	ABT Systems Ltd
2014-11-30 12:20:24 +00:00
Gleb Smirnoff
300fa232ee Missed in r274421: use sbavail() instead of bare access to sb_cc. 2014-11-30 12:11:01 +00:00
Gleb Smirnoff
57f43a45a3 - Move sbcheck() declaration under SOCKBUF_DEBUG.
- Improve SOCKBUF_DEBUG macros.
- Improve sbcheck().

Sponsored by:	Netflix
Sponsored by:	Nginx, Inc.
2014-11-30 11:22:39 +00:00
Gleb Smirnoff
8967b220a3 Make sballoc() and sbfree() functions. Ideally, they could be marked
as static, but unfortunately Infiniband (ab)uses them.

Sponsored by:	Nginx, Inc.
2014-11-30 11:02:07 +00:00
Enji Cooper
d0082ce560 Remove duplicate FILESYSTEMS REQUIRE 2014-11-30 10:55:01 +00:00
Enji Cooper
7027385504 Remove duplicate FILESYSTEMS REQUIRE 2014-11-30 10:01:47 +00:00
Enji Cooper
9779edfbd3 Remove the unnecessary glob 2014-11-30 09:04:24 +00:00
Enji Cooper
d370dc47a1 Fix CFLAGS+=-DDEBUG by using the right header for libutil (libutil.h, not
util.h)
2014-11-30 09:03:34 +00:00
Roman Divacky
6e52f863ee Unbreak the code for non-digits below '0' by casting the expression
to unsigned int.

Pointed out by: bde
2014-11-30 08:43:55 +00:00
Enji Cooper
317fdbc621 Build spppcontrol if MK_PPP != no 2014-11-30 08:34:46 +00:00
Enji Cooper
162789296e MFhead @ r275302 2014-11-30 06:48:37 +00:00
Enji Cooper
3c4ee9781a Followup to r275299: add an ObsoleteFiles.inc entry for etc/rc.d/mrouted 2014-11-30 06:46:30 +00:00
Enji Cooper
ebffb67085 Fill in items to remove with relevant knobs, per r275300 2014-11-30 06:44:24 +00:00
Enji Cooper
2b0cb1247a Fill in MK_ACPI, (MK_ACPI && MK_APM), MK_INET6, MK_PPP, and MK_ROUTED
Rework script dependencies to allow everything made optional to more optional
2014-11-30 06:08:22 +00:00
Enji Cooper
b76f9cb7bc Remove etc/rc.d/mrouted
mrouted has been available in ports for the last 8 years as net/mrouted . An
equivalent rc.d script has been present in the port.

Remove all corresponding variables from etc/defaults/rc.conf

Relnotes: yes
2014-11-30 06:03:59 +00:00
Peter Jeremy
b6e5ca4a88 Cross reference tap(4) and tun(4) and include a short explanation as
to how they differ.  This will assist users in selecting which interface
is more appropriate for their purposes.

Approved by:	grog (co-mentor)
MFC after:	2 week
2014-11-30 04:50:13 +00:00
Enji Cooper
c696ccf200 Followup to r275296: add an ObsoleteFiles.inc entry 2014-11-30 03:02:20 +00:00
Enji Cooper
17441aa848 Remove etc/rc.d/mrouted
The rc.d script has been incorporated into net/mrouted for some time
2014-11-30 03:00:40 +00:00
Enji Cooper
e7d836f78d Make nfs server components conditional according to MK_NFS_SERVER 2014-11-30 02:31:37 +00:00