Commit Graph

191313 Commits

Author SHA1 Message Date
Jilles Tjoelker
e61ae4ffc8 sh: Remove prefix() function. Use strncmp() instead. 2014-07-20 12:06:52 +00:00
Adrian Chadd
ce44e5f776 Add the UDP hash -> RSS mbuf hash type for the ixgbe(4) driver. 2014-07-20 08:43:53 +00:00
Adrian Chadd
e3af537e75 Teach ixgbe(4) about rss_gethashconfig().
If RSS is enabled, ixgbe(4) will query the RSS API for the types of hashes
which should be used.  It'll then only enable hashes that are exposed via
the RSS layer.

This way it won't try to do things like enable UDP hashing if RSS explicitly
states that it isn't supported in lookups.

Tested:

* 82599EB ixgbe(4) NIC
2014-07-20 07:45:48 +00:00
Adrian Chadd
e965b0dcd1 Disable the ixgbe(4) UDP 4-tuple hashing for the time being.
A mix of fragmented and non-fragmented UDP in a single stream will end up
being hashed differently, resulting in out-of-order behaviour in the receive
path.

This was done in the linux e1000 driver in 2011.

Discussed with:	jfv
2014-07-20 07:43:41 +00:00
Adrian Chadd
0ae3f42231 When it's time to do 4-tuple UDP IPv6 hashing, make sure this is a known
type.
2014-07-20 07:39:54 +00:00
Adrian Chadd
58ef629f00 Make the PCBGROUPS code aware of IPv4 UDP 4-tuple. 2014-07-20 07:38:38 +00:00
Adrian Chadd
9870806c93 Add hash awareness of the IPv4 and IPv6 UDP 4-tuple.
Note: it would be nice if the supported hash check would be used here!
2014-07-20 07:37:47 +00:00
Adrian Chadd
40c753e3da Implement rss_gethashconfig() - return the currently supported hash methods
by the stack.

Right now the stack isn't really setup for RSS with 4-tuple UDP hashing
for either IPv4 and IPv6.

The specifics:

* The UDP init path udp_init() and udplite_init() specify the hash as
  2-tuple, so the PCBGROUPS code only tries a 2-tuple check;
* The PCBGROUPS and RSS code doesn't know about the UDP hash types
  just yet, so they're never treated as valid hashes.
* For correctness, 4-tuple can't be enabled in the general case because
  UDP datagrams can be more fragmented than IP datagrams may be.

Strictly speaking, TCP datagrams may also be fragmented and this could
cause issues with PCBGROUPS/RSS until the IP defragment path grows some
code to re-calculate the RSS hash.

I'll follow this commit up with awareness of the UDP 4-tuple for those
who wish to configure it, but for now it'll stay disabled.

No drivers (yet) know to use this function when RSS is enabled.
2014-07-20 07:36:59 +00:00
Adrian Chadd
85415b47c8 Update the comment to be more concise. 2014-07-20 07:31:55 +00:00
Adrian Chadd
c64a6bc62d Correctly program the RSS redirection table entries.
Without this, the RSS bucket assignments aren't correct - they're
DCBA instead of ABCD in each DWORD.

Tested:	82599EB ixgbe(4), TCP and UDP RSS
2014-07-20 04:11:18 +00:00
Nathan Whitehorn
31411fea11 Fix allocation of 128MB extended memory region, broken since some careless
modifications in December.

MFC after:	3 days
2014-07-20 00:08:50 +00:00
Nathan Whitehorn
3ddad7da27 Enable X11 via xf86-video-scfb on the Playstation 3. This commit made from
an xterm running for the first time on said Playstation.
2014-07-19 23:39:17 +00:00
Ian Lepore
677a88cec2 Add dl_unwind_find_exidx() for ARM EABI, required for C++ exception
handling.  For statically linked apps this uses the __exidx_start/end
symbols set up by the linker.  For dynamically linked apps it finds the
shared object that contains the given address and returns the location and
size of the exidx section in that shared object.

The dl_unwind_find_exidx() name is used by other BSD projects and Android,
and is mentioned in clang 3.5 comments as "the BSD interface" for finding
exidx data.  GCC (in libgcc_s) expects the exact same API and functionality
to be provided by a function named __gnu_Unwind_Find_exidx(), so we provide
that with an alias ("strong reference").

Reviewed by:	kib@
MFC after:	1 week
2014-07-19 22:13:27 +00:00
Dag-Erling Smørgrav
16722cb2c1 Add support for the "account" facility.
PR:		115164
MFC after:	1 week
2014-07-19 21:04:21 +00:00
Neel Natu
091d453222 Handle nested exceptions in bhyve.
A nested exception condition arises when a second exception is triggered while
delivering the first exception. Most nested exceptions can be handled serially
but some are converted into a double fault. If an exception is generated during
delivery of a double fault then the virtual machine shuts down as a result of
a triple fault.

vm_exit_intinfo() is used to record that a VM-exit happened while an event was
being delivered through the IDT. If an exception is triggered while handling
the VM-exit it will be treated like a nested exception.

vm_entry_intinfo() is used by processor-specific code to get the event to be
injected into the guest on the next VM-entry. This function is responsible for
deciding the disposition of nested exceptions.
2014-07-19 20:59:08 +00:00
Dag-Erling Smørgrav
ec5622ad86 Check if the specified group is the user's primary group before
iterating over the (possibly empty) list of members.  Otherwise, we
get a false negative when the target group has no members listed in
/etc/group.  This went mostly unnoticed because root is explicitly
listed as a member of wheel, so the bug is never triggered in the most
common use case, which is su(8).

PR:		109416
MFC after:	1 week
2014-07-19 20:55:13 +00:00
Dag-Erling Smørgrav
e8263e185c Clean up the libunbound build to avoid accidentally regenerating the
configuration lexer and parser during buildworld.  Instead of being
included in the source as it is in the upstream distribution, the code is
now always generated (in ${.OBJDIR}) at build time.

PR:		190739
MFC after:	1 week
2014-07-19 18:38:48 +00:00
Nathan Whitehorn
34a856a200 Allow mappings of memory not previously direct-mapped by the kernel when
calling mmap on /dev/mem and add a handler for the possible userland
machine checks that may result. Remove some pointless and wrong copy/paste
that has been in here for a decade as well.

This results in a /dev/mem with identical semantics to the x86 version.

MFC after:	1 week
2014-07-19 15:11:58 +00:00
Robert Watson
9fa958082f Better align headers and data for 'procstat -f' with and without '-C'.
MFC after:	3 days
Sponsored by:	DARPA, AFRL
2014-07-19 15:09:53 +00:00
Pedro F. Giffuni
65227e53ce Clean r268867.
Proposed by:	bde
2014-07-19 14:34:06 +00:00
Dag-Erling Smørgrav
8f812fec9f Use -o (output to file) instead of -t (print to stdout) and a redirect.
MFC after:	1 week
2014-07-19 14:26:04 +00:00
Baptiste Daroussin
0e89acf4b4 Merge libucl 20140718 (fixes a bug in the parser) 2014-07-19 14:10:31 +00:00
Baptiste Daroussin
8f2b0cccb4 Import libucl 20140718 (fixes a bug in the parser) 2014-07-19 14:07:49 +00:00
Jilles Tjoelker
2ef146f14c sh: Deduplicate some code in ulimit builtin. 2014-07-19 14:06:23 +00:00
Mark Johnston
5a5f9d21dd Use a C wrapper for trap() instead of checking and calling the DTrace trap
hook in assembly.

Suggested by:	kib
Reviewed by:	kib (original version)
X-MFC-With:	r268600
2014-07-19 02:27:31 +00:00
Pedro F. Giffuni
bef4f148b1 Use unsigned optlen in getsourcefilter()
Sizes can not be negative and the functions that use it
expect an unsigned value anyways.

Obtained from:	Apple (Libc-997.90.3)
MFC after:	1 week
2014-07-19 01:53:52 +00:00
Rick Macklem
9f7289bfc4 r243637 changed the default number of nfsd threads created,
but the man page did not reflect this.
This is a content change.

Reported by:	bde
MFC after:	2 weeks
2014-07-19 01:15:01 +00:00
Xin LI
b4bb49887b Reduce lock contention on the z_teardown_lock under heavily cached
read workload by splitting the single teardown rrw lock into
RRM_NUM_LOCKS (17) of them.

Read acquisitions are randomly distributed among these locks based
on curthread pointer.  Write acquisitions are going to all the
locks, which for the usage of this type of lock should be rare.

Illumos issue:
    5008 lock contention (rrw_exit) while running a read only load

MFC after:	2 weeks
2014-07-19 00:26:03 +00:00
Dag-Erling Smørgrav
0d0485e20e Document the need to regenerate the local_unbound configuration. 2014-07-19 00:11:51 +00:00
Devin Teske
7ee104abde Oops, forgot to bump manual date/copyright in r268860.
MFC after:	3 days
X-MFC-to:	stable/10, stable/9, ports
X-MFC-with:	r268860
2014-07-18 23:23:52 +00:00
Baptiste Daroussin
4a61cd4e9b Add libsbuf.so.6 to obsolete libraries since it has been bumped to .so.7 2014-07-18 23:04:27 +00:00
Baptiste Daroussin
56793850d8 Improve timeout(1) man page
Document the exit values and the duration format
Improve wording
Pet mandoc -Tlint
Sort SEE ALSO

Phabric:	https://phabric.freebsd.org/D432
Reviewed by:	wblock
2014-07-18 22:56:59 +00:00
Devin Teske
e6c0306561 Minor enhancements, bug fixes, and man-page adjustments.
+ Make `sysrc -x foo' produce error status if foo is unset.
NB: Reported by lme (everything else ``while I'm at it'')
+ Remove mention of SYSRC_VERBOSE from `sysrc --help' output.
NB: False documentation leftover from an ancient precursor.
+ Make `sysrc -qc foo' work the same as `sysrc -ic foo' when foo is unset
NB: For syntax convenience (my fingers know `-q' more than `-i').
+ Update description of `-c' flag in help message/manual.
+ Update description of `-q' flag in help message/manual.
+ Make `sysrc -vc foo' work as documented in the manual
NB: Show message stating whether foo is currently set.
+ Make `sysrc -vc foo=1' work as documented in the manual
NB: Show message stating how value of foo would be changed (if at all).
+ Remove odd usage of parentheses in `-R dir' section of manual.
+ Clarify syntax section of manual w/respect to sysctl(8) similarities.
+ Add new/missing people to the `THANKS TO' section of the manual.

Reported by:	lme
MFC after:	3 days
X-MFC-to:	stable/10, stable/9, ports
2014-07-18 22:44:15 +00:00
Xin LI
82599d31fe MFV r268851:
When a sync task is waiting for a txg to complete, we should hurry it along
by increasing the number of outstanding async writes (i.e. make
vdev_queue_max_async_writes() return a larger number).

Illumos issue:
    4753 increase number of outstanding async writes when sync task is waiting

MFC after:	2 weeks
2014-07-18 22:34:01 +00:00
Xin LI
f886b6e3bc MFV r268850:
Change the interaction between the DMU and ARC so that when the DMU is
shutting down an objset, we do not evict the data from the ARC.  Instead
we simply coordinate the destruction of the DMU's data with the ARC.

The only case where we actually need to explicitly evict from the ARC is
when dbuf_rele_and_unlock() determines that the administrator has requested
that it not be kept in memory, via the primarycache/secondarycache properties.
In this case, we evict the data from the ARC by its blkptr_t, the same way
as when a block is freed we explicitly evict it from the ARC.

Illumos issue:
    4631 zvol_get_stats triggering too many reads

MFC after:	2 weeks
2014-07-18 22:04:21 +00:00
Jilles Tjoelker
becf520163 ttyname(3): Fix EBADF/ENOTTY error descriptions.
Also, make sure to document the return values and errors for all three
functions in the man page.

PR:		191931
MFC after:	1 week
2014-07-18 21:29:59 +00:00
Xin LI
cd01c7a84f Fix build by using the driver API (driver converted in r266979 which should
be upstreamed).

X-MFC with:	r268854
MFC after:	5 days
2014-07-18 21:28:59 +00:00
Xin LI
7882b61f60 MFV r268848:
Instead of asserting all zio's be properly aligned, only assert
on the logical ones.

Cap uberblocks at 8k, otherwise with ashift=17, there would be
only one uberblock.

This fixes a problem that zdb would trip assert on pools with
ashift >= 0xe (8k).

While there, also change the code so it only attempt to condense
space map unless the uncondensed size consumes greater than
zfs_metaslab_condense_block_threshold blocks.

Illumos issue:
  4958 zdb trips assert on pools with ashift >= 0xe

MFC after:	2 weeks
2014-07-18 20:41:40 +00:00
David C Somayajulu
e3a36fb018 Initiate error recovery stats fail to update after 3 retries.
Change bxe_panic() ECORE_DBG_BREAK_IF() ECORE_BUG() ECORE_BUG_ON() to
panic only if ECORE_STOP_ON_ERROR is defined.

MFC after:5 days
2014-07-18 20:04:11 +00:00
Xin LI
4fa00fc6d6 5008 lock contention (rrw_exit) while running a read only load
Reviewed by: Matthew Ahrens <matthew.ahrens@delphix.com>
Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Alex Reece <alex.reece@delphix.com>
Reviewed by: Christopher Siden <christopher.siden@delphix.com>
Reviewed by: Richard Yao <ryao@gentoo.org>
Reviewed by: Saso Kiselkov <skiselkov.ml@gmail.com>
Approved by: Garrett D'Amore <garrett@damore.org>

illumos/illumos-gate@c9030f6c93
2014-07-18 18:09:20 +00:00
Xin LI
747c0e4125 4753 increase number of outstanding async writes when sync task is waiting
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Adam Leventhal <ahl@delphix.com>
Reviewed by: Christopher Siden <christopher.siden@delphix.com>
Reviewed by: Dan McDonald <danmcd@omniti.com>
Approved by: Garrett D'Amore <garrett@damore.org>

illumos/illumos-gate@73527f441c
2014-07-18 18:05:09 +00:00
Xin LI
5dace04917 4631 zvol_get_stats triggering too many reads
Reviewed by: Adam Leventhal <ahl@delphix.com>
Reviewed by: Sebastien Roy <sebastien.roy@delphix.com>
Reviewed by: Matt Ahrens <mahrens@delphix.com>
Approved by: Dan McDonald <danmcd@omniti.com>

illumos/illumos-gate@bbfa8ea8bb
2014-07-18 18:02:34 +00:00
Xin LI
df9458d254 4958 zdb trips assert on pools with ashift >= 0xe
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Max Grossman <max.grossman@delphix.com>
Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Christopher Siden <christopher.siden@delphix.com>
Approved by: Garrett D'Amore <garrett@damore.org>

illumos/illumos-gate@2a104a5236
2014-07-18 17:55:12 +00:00
Hiren Panchasara
eee92ad073 The description is a bit misleading. Trying to make it more obvious.
Phabric:    https://phabric.freebsd.org/D435
Reviewed by:	gnn
2014-07-18 16:25:35 +00:00
Pedro F. Giffuni
1d717f206a Revert r268826:
The current ordering of this header is a feature as it
is more consistent with POSIX.
Also adding gratuitous newlines is not elegant.

Pointed out by:	bde
2014-07-18 16:21:15 +00:00
Alan Cox
ea40a6a62c Remove obsolete man pages. The corresponding code was removed in r255608. 2014-07-18 15:39:07 +00:00
Gleb Smirnoff
c71b4037ff Use assignment instead of bcopy.
Submitted by:	jmg
2014-07-18 14:59:35 +00:00
Baptiste Daroussin
42e62eca52 Extend kqueue's EVFILT_TIMER by adding precision unit flags support
Define the precision macros as bits sets to conform with XNU equivalent.
Test fflags passed for EVFILT_TIMER and return EINVAL in case an invalid flag
is passed.

Phabric:	https://phabric.freebsd.org/D421
Reviewed by:	kib
2014-07-18 14:27:04 +00:00
Gavin Atkinson
ee3a0d1c0f Fix two typos in iscsictl.8
PR:		191581
Submitted by:	Jimmy Olgeni
MFC after:	3 days
2014-07-18 12:51:35 +00:00
Dag-Erling Smørgrav
5741c3f510 Use a combination of unblock-lan-zones (r268839) and domain-insecure
to fix reverse lookups on networks using private addresses.
2014-07-18 12:33:22 +00:00