jeff [Sat, 8 Mar 2014 00:35:06 +0000 (00:35 +0000)]
- Make runq_steal_from more aggressive. Previously it would examine only
a single priority queue. If that queue had a thread or threads which
could not be migrated we would fail to steal load. This could cause
starvation in situations where cores are idle.
imp [Sat, 8 Mar 2014 00:14:40 +0000 (00:14 +0000)]
Move all the files named foo/common.c to foo/foo_common.c, as
appropriate for each of the 'foo' in the tree. This will allow us to
compile them together (although symbol conflicts prevent us from doing
that today, this just fixes the file name collision).
asomers [Fri, 7 Mar 2014 23:40:36 +0000 (23:40 +0000)]
Partial revert of change 262914. I screwed up subversion syntax with
perforce syntax and committed some unrelated files. Only devd files
should've been committed.
Reported by: imp
Pointy hat to: asomers
MFC after: 3 weeks
X-MFC-With: r262914
asomers [Fri, 7 Mar 2014 23:01:35 +0000 (23:01 +0000)]
cddl/contrib/opensolaris/lib/libuutil/common/uu_avl.c
Fix a memory leak in uu_avl_pool_create: pthread_mutex_init without
a corresponding pthread_mutex_destroy. It shows up, among other
places, when doing "zfs list".
ian [Fri, 7 Mar 2014 21:36:49 +0000 (21:36 +0000)]
Strip arm/conf/DEFAULTS down to just items that are mandatory for running
the architecture. Move the other contents into each of the individual
config files.
dteske [Fri, 7 Mar 2014 20:44:19 +0000 (20:44 +0000)]
Rewrite groupmgmt -- hooking it into the scripting system with dispatch
commands groupAdd, groupDelete, and groupEdit. Getting rid of the awkward-
to-use `groupinput' bolt-on which Ron and I talked about rewriting.
ian [Fri, 7 Mar 2014 20:32:45 +0000 (20:32 +0000)]
Fix the arm sys_sigreturn(): its argument is a struct ucontext, not a
struct sigframe containing the struct ucontext.
The signal trampoline return code on the other hand DOES have just a
struct sigframe on the stack to work with, so have it get a pointer to
the ucontext out of there to pass along to sys_sigreturn.
In other words, make everything work right whether sys_sigreturn is
invoked from the trampoline or from userland code calling sigreturn(2).
asomers [Fri, 7 Mar 2014 19:30:03 +0000 (19:30 +0000)]
kern/Makefile
Set WARNS=5 for all files in this directory
kern/unix_seqpacket_test.c
Fix compiler warnings. Most were benign, but rcvbuf_oversized
wasn't working as intended because I forgot to set the buffer sizes.
mav [Fri, 7 Mar 2014 09:45:40 +0000 (09:45 +0000)]
Fix support for increased logical sector size (4K-native drives).
- Logical sector size is measured in words, not bytes.
- If physical sector is not bigger then logical sector, it does not mean
it should be set equal to 512 bytes, but set to logical sector.
grehan [Fri, 7 Mar 2014 06:23:37 +0000 (06:23 +0000)]
Open the uart emulation's backing tty in non-blocking mode.
This fixes the issue of bhyve appearing to halt when using
nmdm ports for the console, until a connection is made to
the other end.
ian [Fri, 7 Mar 2014 00:25:23 +0000 (00:25 +0000)]
Add option TMPFS to arm/conf/DEFAULTS, remove it from the few configs
that have it individually. Concensus on freebsd-arm@ is that it should
be included in all ARM kernels.
asomers [Thu, 6 Mar 2014 20:24:15 +0000 (20:24 +0000)]
Fix PR kern/185813 "SOCK_SEQPACKET AF_UNIX sockets with asymmetrical
buffers drop packets". It was caused by a check for the space available
in a sockbuf, but it was checking the wrong sockbuf.
sys/sys/sockbuf.h
sys/kern/uipc_sockbuf.c
Add sbappendaddr_nospacecheck_locked(), which is just like
sbappendaddr_locked but doesn't validate the receiving socket's
space. Factor out common code into sbappendaddr_locked_internal().
We shouldn't simply make sbappendaddr_locked check the space and
then call sbappendaddr_nospacecheck_locked, because that would cause
the O(n) function m_length to be called twice.
sys/kern/uipc_usrreq.c
Use sbappendaddr_nospacecheck_locked for SOCK_SEQPACKET sockets,
because the receiving sockbuf's size limit is irrelevant.
tests/sys/kern/unix_seqpacket_test.c
Now that 185813 is fixed, pipe_128k_8k fails intermittently due to
185812. Make it fail every time by adding a usleep after starting
the writer thread and before starting the reader thread in
test_pipe. That gives the writer time to fill up its send buffer.
Also, clear the expected failure message due to 185813. It actually
said "185812", but that was a typo.
PR: kern/185813
Reviewed by: silence from freebsd-net@ and rwatson@
MFC after: 3 weeks
Sponsored by: Spectra Logic Corporation
gjb [Thu, 6 Mar 2014 18:48:02 +0000 (18:48 +0000)]
Add a hack-ish attempt to provide backwards-compatibility with
release.conf SVNROOT entries that do not have a trailing '/'.
In order to provide a mechanism to use !svn, the trailing '/'
was added to SVNROOT so there were no assumptions being made
about '/' being in the URL between SVNROOT and SRCBRANCH.
marcel [Thu, 6 Mar 2014 01:59:13 +0000 (01:59 +0000)]
Use SYSDIR to reference to the top of the sys hierarchy. Define SYSDIR
relative to .CURDIR if not already defined. This makes the makefiles
more readable but also more re-usable and adaptable.
jeff [Thu, 6 Mar 2014 00:13:21 +0000 (00:13 +0000)]
- If we fail to do a non-blocking acquire of a buf lock while doing a
waiting sync pass we need to do a blocking acquire and restart.
Another thread, typically the buf daemon, may have this buf locked and
if we don't wait we can fail to sync the file. This lead to a great
variety of softdep panics because we rely on all dependencies being
flushed before proceeding in several cases.
jeff [Thu, 6 Mar 2014 00:10:07 +0000 (00:10 +0000)]
- Gracefully handle truncation failures when trying to shrink directories.
This could cause dirhash panics since the dirhash state would be
successfully truncated while the directory was not.
gjb [Wed, 5 Mar 2014 23:17:53 +0000 (23:17 +0000)]
Merge ^/projects/release-embedded into ^/head.
After several months of testing and fixing (and breaking)
various parts of release/release.sh changes, it is now
possible to build FreeBSD/arm images as part of the release
process.
When EMBEDDEDBUILD is set in the release.conf file, release.sh
will create the build environment, then run a separate script
in release/${XDEV}/release.sh [1]. Currently, only arm is
supported.
The release/${XDEV}/release.sh configures the build environment
specific for the target image, such as installing gcc(1),
installing additional third-party software from the ports tree,
and fetching external sources.
Once the build environment is set up, release/${XDEV}/release.sh
runs Crochet, written by Tim Kientzle, which builds the userland
and kernel, and creates an image that can be written to an SD
card with dd(1). Many thanks to Tim for his work on Crochet.
Sample configurations for FreeBSD/arm boards are in the
release/arm/ directory, and Crochet configuration files for each
board are located in release/tools/arm/. Supported boards at this
time are: BEAGLEBONE, PANDABOARD, RPI-B, and WANDBOARD-QUAD.
Adding support for additional boards will continue in the
projects/release-embedded/ branch, and incrementally merged back
to head/.
Many thanks to the FreeBSD Foundation for the support and
sponsorship of this project.
[1] XDEV is used in order to keep the various configurations
organized by architecture, but since TARGET and TARGET_ARCH
are used to build the chroot, the values of those variables
cannot be used.
MFC after: 1 month
Sponsored by: The FreeBSD Foundation
glebius [Wed, 5 Mar 2014 21:16:46 +0000 (21:16 +0000)]
The route code used to mtx_destroy() a locked mutex before rtentry free. Now,
after r262763 it started to return locked mutexes to UMA. To fix that,
conditionally unlock the mutex in the destructor.
Tested by: "Sergey V. Dyatko" <sergey.dyatko@gmail.com>
emaste [Wed, 5 Mar 2014 01:34:10 +0000 (01:34 +0000)]
Disable amd64 TLB Context ID (pcid) by default for now
There are a number of reports of userspace application crashes that
are "solved" by setting vm.pmap.pcid_enabled=0, including Java and the
x11/mate-terminal port (PR ports/184362).
I originally planned to disable this only in stable/10 (in r262753), but
it has been pointed out that additional crash reports on HEAD are not
likely to provide new insight into the problem. The feature can easily
be enabled for testing.
glebius [Wed, 5 Mar 2014 01:17:47 +0000 (01:17 +0000)]
- Remove rt_metrics_lite and simply put its members into rtentry.
- Use counter(9) for rt_pksent (former rt_rmx.rmx_pksent). This
removes another cache trashing ++ from packet forwarding path.
- Create zini/fini methods for the rtentry UMA zone. Via initialize
mutex and counter in them.
- Fix reporting of rmx_pksent to routing socket.
- Fix netstat(1) to report "Use" both in kvm(3) and sysctl(3) mode.
The change is mostly targeted for stable/10 merge. For head,
rt_pksent is expected to just disappear.
Discussed with: melifaro
Sponsored by: Netflix
Sponsored by: Nginx, Inc.