]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
10 years agoRemove a couple of unused macros.
markj [Sat, 17 Aug 2013 21:53:37 +0000 (21:53 +0000)]
Remove a couple of unused macros.

MFC after: 3 days

10 years agoBump up the maximum addressable memory on amd64 systems from 1TB to 4TB.
neel [Sat, 17 Aug 2013 19:49:08 +0000 (19:49 +0000)]
Bump up the maximum addressable memory on amd64 systems from 1TB to 4TB.
Bump up the KVA size proportionally from 512GB to 2TB.

The number of page table pages used by the direct map is now calculated at
run time based on 'Maxmem'. This means the small memory systems will not
see any additional tax in terms of page table pages for the direct map.

However all amd64 systems, regardless of the memory size, will use 3 more
pages to accomodate the bump in the KVA size.

More details available here:
http://lists.freebsd.org/pipermail/freebsd-hackers/2013-June/043015.html
http://lists.freebsd.org/pipermail/freebsd-current/2013-July/043143.html

Tested with the following configurations:
- Sandybridge server with 64GB of memory.
- bhyve VM with 64MB of memory.
- bhyve VM with a 8GB of memory with the memory segment above 4GB cuddling
  right up against the 4TB maximum memory limit.

Discussed on: hackers@, current@
Submitted by: Chris Torek (torek@torek.net)

10 years agoCorrect implementation of atomic_flag_test_and_set
emaste [Sat, 17 Aug 2013 19:34:41 +0000 (19:34 +0000)]
Correct implementation of atomic_flag_test_and_set

The function sets the flag and returns the previous value (7.17.8.1).

10 years agoEnable VFP support for BeagleBone.
ian [Sat, 17 Aug 2013 19:29:51 +0000 (19:29 +0000)]
Enable VFP support for BeagleBone.

10 years agolibc: Access _logname_valid more efficiently.
jilles [Sat, 17 Aug 2013 19:24:58 +0000 (19:24 +0000)]
libc: Access _logname_valid more efficiently.

The variable _logname_valid is not exported via the version script;
therefore, change C and i386/amd64 assembler code to remove indirection
(which allowed interposition). This makes the code slightly smaller and
faster.

Also, remove #define PIC_GOT from i386/amd64 in !PIC mode. Without PIC,
there is no place containing the address of each variable, so there is no
possible definition for PIC_GOT.

10 years ago- Remove struct ifinfo *iflist. It is no longer used.
hrs [Sat, 17 Aug 2013 19:23:35 +0000 (19:23 +0000)]
- Remove struct ifinfo *iflist.  It is no longer used.
- Suppress warnings about increase of alignment requirement.

10 years agoRename device vfp to option VFP and retire the ARM_VFP_SUPPORT option. This
andrew [Sat, 17 Aug 2013 18:51:38 +0000 (18:51 +0000)]
Rename device vfp to option VFP and retire the ARM_VFP_SUPPORT option. This
simplifies enabling as previously both options were required to be enabled,
now we only need a single option.

While here enable VFP on the PandaBoard.

10 years ago- Use getnameinfo(3) instead of gethostbyaddr(3) or inet_ntop(3).
hrs [Sat, 17 Aug 2013 17:23:42 +0000 (17:23 +0000)]
- Use getnameinfo(3) instead of gethostbyaddr(3) or inet_ntop(3).

- Fill sin6_scope_id from in6p.sin6_addr.s6_addr[2].  struct inpcb has
  struct in6_addr for the endpoint addresses, so sin6_scope_id must be filled.

10 years agoDo not use potentially stale thread in kthread_add()
bryanv [Sat, 17 Aug 2013 17:02:43 +0000 (17:02 +0000)]
Do not use potentially stale thread in kthread_add()

When an existing process is provided, the thread selected to use
to initialize the new thread could have exited and be reaped.
Acquire the proc lock earlier to ensure the thread remains valid.

Reviewed by: jhb, julian (previous version)
MFC after: 3 days

10 years agoRemove the armfpe config options. These files don't exist on FreeBSD.
andrew [Sat, 17 Aug 2013 15:21:17 +0000 (15:21 +0000)]
Remove the armfpe config options. These files don't exist on FreeBSD.

10 years agoRemove the ARMFPE option. It is unsupported, and appears to be broken as
andrew [Sat, 17 Aug 2013 15:09:14 +0000 (15:09 +0000)]
Remove the ARMFPE option. It is unsupported, and appears to be broken as
arm_fpe_core_changecontext is not a function.

10 years agoCorrect function name and return value.
pjd [Sat, 17 Aug 2013 14:55:31 +0000 (14:55 +0000)]
Correct function name and return value.

10 years agoRemove fpe_sp_state as we don't support fpe.
andrew [Sat, 17 Aug 2013 14:53:53 +0000 (14:53 +0000)]
Remove fpe_sp_state as we don't support fpe.

10 years agoRemove unused FPE code. This is not enabled anywhere as it is the only
andrew [Sat, 17 Aug 2013 14:52:19 +0000 (14:52 +0000)]
Remove unused FPE code. This is not enabled anywhere as it is the only
file I can find containing FAST_FPE. It appears this would not work as
want_resched is not defined anywhere.

10 years agoEnsure we set all fpu registers to zero by using the address and size of
andrew [Sat, 17 Aug 2013 14:42:40 +0000 (14:42 +0000)]
Ensure we set all fpu registers to zero by using the address and size of
the union over one of its members.

10 years agoSilence a warning that is incorrect on ARMv6 and later. In the smull, umull,
andrew [Sat, 17 Aug 2013 14:36:32 +0000 (14:36 +0000)]
Silence a warning that is incorrect on ARMv6 and later. In the smull, umull,
smlal, and umlal the output registers are allowed to be the same as either
input registers, where in ARMv4 and ARMv5 they could only be the same as the
last input register.

10 years agoRegenerate after r254447.
pjd [Sat, 17 Aug 2013 14:18:41 +0000 (14:18 +0000)]
Regenerate after r254447.

Sponsored by: The FreeBSD Foundation

10 years agoMake pdfork(2), pdkill(2) and pdgetpid(2) syscalls available for 32bit
pjd [Sat, 17 Aug 2013 14:17:13 +0000 (14:17 +0000)]
Make pdfork(2), pdkill(2) and pdgetpid(2) syscalls available for 32bit
binaries running under 64bit kernel.

Sponsored by: The FreeBSD Foundation

10 years agoIn r114945 the line 'nmp = TAILQ_NEXT(mp, mnt_list);' was duplicated.
pjd [Sat, 17 Aug 2013 14:13:45 +0000 (14:13 +0000)]
In r114945 the line 'nmp = TAILQ_NEXT(mp, mnt_list);' was duplicated.
Instead of just removing the duplicate, convert the loop to TAILQ_FOREACH().

10 years agoRemove redundant variable.
pjd [Sat, 17 Aug 2013 14:09:46 +0000 (14:09 +0000)]
Remove redundant variable.

10 years agoReturn 0 in nbi->expire when la_expire == 0. Conversion from time_uptime to
hrs [Sat, 17 Aug 2013 07:14:45 +0000 (07:14 +0000)]
Return 0 in nbi->expire when la_expire == 0.  Conversion from time_uptime to
time_second should not be performed in this case.

10 years agoUnbreak rwhod(8):
hrs [Sat, 17 Aug 2013 07:12:52 +0000 (07:12 +0000)]
Unbreak rwhod(8):

- It did not work with GENERIC kernel after r250603 because
  options PROCDESC was required for pdfork(2).  It now just uses fork(2)
  instead when this syscall is not available.

- Fix verify().  This function was broken in r250602 because the outermost
  "()" was removed from the condition !(isalnum() || ispunct()).
  It prevented hostnames including "-", for example.

10 years agoRemove the arbitrary binding of the pagedaemon threads to the domains,
kib [Sat, 17 Aug 2013 07:10:01 +0000 (07:10 +0000)]
Remove the arbitrary binding of the pagedaemon threads to the domains,
update the comment accordingly and make it more precise.

Requested and reviewed by: jeff (previous version)

10 years agoFix some USB controller names according to pciconf output.
hselasky [Sat, 17 Aug 2013 06:29:45 +0000 (06:29 +0000)]
Fix some USB controller names according to pciconf output.

MFC after: 1 week
Submitted by: Dmitry Luhtionov <dmitryluhtionov@gmail.com>

10 years agoDon't let user specified DESTDIR, break building our chosen make.
sjg [Sat, 17 Aug 2013 04:41:35 +0000 (04:41 +0000)]
Don't let user specified DESTDIR, break building our chosen make.

10 years agoCorrect sentence syntax too.
mjacob [Sat, 17 Aug 2013 01:17:51 +0000 (01:17 +0000)]
Correct sentence syntax too.

10 years agoLog the MAC address of the node in question rather than the pointer.
adrian [Sat, 17 Aug 2013 01:14:28 +0000 (01:14 +0000)]
Log the MAC address of the node in question rather than the pointer.

10 years agoCorrect spelling.
obrien [Sat, 17 Aug 2013 01:02:04 +0000 (01:02 +0000)]
Correct spelling.

10 years agoFix build.
delphij [Sat, 17 Aug 2013 00:25:11 +0000 (00:25 +0000)]
Fix build.

10 years agoConsistently init all mmc request, command, and data structures to zero
ian [Sat, 17 Aug 2013 00:19:27 +0000 (00:19 +0000)]
Consistently init all mmc request, command, and data structures to zero
before using them.

10 years agoHandle command retries for commands originating at the mmc layer, and
ian [Fri, 16 Aug 2013 23:05:34 +0000 (23:05 +0000)]
Handle command retries for commands originating at the mmc layer, and
ensure that all such commands have a non-zero retry count except for those
that are expected to fail (for example, because they are used to probe for
feature support).

While it is possible to pass a retry count down to the hardware driver in
the command request structure, no hardware driver currently implements any
retry logic.  The hardware doesn't know much about the context of a single
request, so it makes more sense to handle retries at a layer that does.

This adds retry loops to the mmc_wait_for_cmd() and mmc_wait_for_app_cmd()
functions.  These functions are the gateway from other code within mmc.c
to the hardware.  App commands are a sequence of two commands and a retry
has to rerun both of them in order, so it needs its own retry loop.

Retry looping is specifically NOT implemented in mmc_wait_for_request()
because it is the gateway for children on the bus, and they have to
implement their own retry logic depending on what makes sense for them.

10 years agoAdd new mmap(2) flags to permit applications to request specific virtual
jhb [Fri, 16 Aug 2013 21:13:55 +0000 (21:13 +0000)]
Add new mmap(2) flags to permit applications to request specific virtual
address alignment of mappings.
- MAP_ALIGNED(n) requests a mapping aligned on a boundary of (1 << n).
  Requests for n >= number of bits in a pointer or less than the size of
  a page fail with EINVAL.  This matches the API provided by NetBSD.
- MAP_ALIGNED_SUPER is a special case of MAP_ALIGNED.  It can be used
  to optimize the chances of using large pages.  By default it will align
  the mapping on a large page boundary (the system is free to choose any
  large page size to align to that seems best for the mapping request).
  However, if the object being mapped is already using large pages, then
  it will align the virtual mapping to match the existing large pages in
  the object instead.
- Internally, VMFS_ALIGNED_SPACE is now renamed to VMFS_SUPER_SPACE, and
  VMFS_ALIGNED_SPACE(n) is repurposed for specifying a specific alignment.
  MAP_ALIGNED(n) maps to using VMFS_ALIGNED_SPACE(n), while
  MAP_ALIGNED_SUPER maps to VMFS_SUPER_SPACE.
- mmap() of a device object now uses VMFS_OPTIMAL_SPACE rather than
  explicitly using VMFS_SUPER_SPACE.  All device objects are forced to
  use a specific color on creation, so VMFS_OPTIMAL_SPACE is effectively
  equivalent.

Reviewed by: alc
MFC after: 1 month

10 years agoDuring card identification, run the bus at 400KHz, not the minimum
ian [Fri, 16 Aug 2013 20:32:56 +0000 (20:32 +0000)]
During card identification, run the bus at 400KHz, not the minimum
speed the bus claims to be capable of.  The 400KHz speed is dictated
by the SD and MMC standards.

10 years agosh: Remove unnecessary reset functions.
jilles [Fri, 16 Aug 2013 20:24:41 +0000 (20:24 +0000)]
sh: Remove unnecessary reset functions.

These are already handled by exception handlers.

10 years agoPrint the card relative address in hex, because that's what all the
ian [Fri, 16 Aug 2013 20:22:57 +0000 (20:22 +0000)]
Print the card relative address in hex, because that's what all the
other debugging output does (when it appears in command arguments,
for example).

10 years agoAdd named constants for 8-bit bus support. The sdhci and mmc drivers
ian [Fri, 16 Aug 2013 19:44:49 +0000 (19:44 +0000)]
Add named constants for 8-bit bus support.  The sdhci and mmc drivers
don't have support for this yet, but some low-level hardware is ready
for it when the higher layers catch up.

10 years agoWhen the timeout clock is based on the SD clock, the timeout counter
ian [Fri, 16 Aug 2013 19:40:00 +0000 (19:40 +0000)]
When the timeout clock is based on the SD clock, the timeout counter
has to be recalculated every time the SD clock frequency changes.

Also, tidy up the counter calculation... it makes no sense to calculate
a value one larger than the limit, then whine that it's too large and
truncate it to the limit.  If the BROKEN_TIMEOUT quirk is set, don't
calculate the counter at all, just set it to the limit value.

10 years agoAdd .MAKE.ALWAYS_PASS_JOB_QUEUE knob (default yes)
sjg [Fri, 16 Aug 2013 18:47:18 +0000 (18:47 +0000)]
Add .MAKE.ALWAYS_PASS_JOB_QUEUE knob (default yes)
for backwards compatability.

10 years agoWhen we need to build using the in-tree make,
sjg [Fri, 16 Aug 2013 16:26:23 +0000 (16:26 +0000)]
When we need to build using the in-tree make,
switch at the earliest opportunity.
In the case of fmake vs bmake, this helps ensure correct load handling.

Reviewed by: obrien

10 years agoAdd unmapped I/O and larger I/O support to the sa(4) driver.
ken [Fri, 16 Aug 2013 16:14:32 +0000 (16:14 +0000)]
Add unmapped I/O and larger I/O support to the sa(4) driver.

We now pay attention to the maxio field in the XPT_PATH_INQ CCB,
and if it is set, propagate it up to physio via the si_iosize_max
field in the cdev structure.

We also now pay attention to the PIM_UNMAPPED capability bit in the
XPT_PATH_INQ CCB, and set the new SI_UNMAPPED cdev flag when the
underlying SIM supports unmapped I/O.

scsi_sa.c: Add unmapped I/O support and propagate the SIM's
maximum I/O size up.

Adjust scsi_tape_read_write() in the same way that
scsi_read_write() was changed to support unmapped
I/O.  We overload the readop parameter with bits
that tell us whether it's an unmapped I/O, and we
need to set the CAM_DATA_BIO CCB flag.  This change
should be backwards compatible in source and
binary forms.

MFC after: 1 week
Sponsored by: Spectra Logic

10 years agoRestore the previous sendfile(2) behaviour on the block devices.
kib [Fri, 16 Aug 2013 14:22:20 +0000 (14:22 +0000)]
Restore the previous sendfile(2) behaviour on the block devices.
Provide valid .fo_sendfile method for several missed struct fileops.

Reviewed by: glebius
Sponsored by: The FreeBSD Foundation

10 years agopselect(2): Add xref to sigsuspend(2).
jilles [Fri, 16 Aug 2013 14:06:29 +0000 (14:06 +0000)]
pselect(2): Add xref to sigsuspend(2).

10 years agosh: Recognize "--" as end of options in bg/fg/jobid builtins.
jilles [Fri, 16 Aug 2013 13:56:43 +0000 (13:56 +0000)]
sh: Recognize "--" as end of options in bg/fg/jobid builtins.

10 years agosh: Add test for the non-standard jobid builtin.
jilles [Fri, 16 Aug 2013 13:48:11 +0000 (13:48 +0000)]
sh: Add test for the non-standard jobid builtin.

10 years agoAdd tests for dup3().
jilles [Fri, 16 Aug 2013 13:16:55 +0000 (13:16 +0000)]
Add tests for dup3().

10 years agoAdd man page dup3(3).
jilles [Fri, 16 Aug 2013 13:16:27 +0000 (13:16 +0000)]
Add man page dup3(3).

10 years agoAdd dup3(), based on F_DUP2FD and F_DUP2FD_CLOEXEC fcntls.
jilles [Fri, 16 Aug 2013 13:10:30 +0000 (13:10 +0000)]
Add dup3(), based on F_DUP2FD and F_DUP2FD_CLOEXEC fcntls.

I removed functionality not proposed for POSIX in Austin group issue #411.
A man page (my own) and test cases will follow in later commits.

PR: 176233
Submitted by: Jukka Ukkonen

10 years agoGC unused source file.
des [Fri, 16 Aug 2013 10:53:36 +0000 (10:53 +0000)]
GC unused source file.

10 years agoBring datasheet URL up to date.
kevlo [Fri, 16 Aug 2013 07:42:06 +0000 (07:42 +0000)]
Bring datasheet URL up to date.

10 years agoProvide UTF-8 version of russian calendars.
glebius [Fri, 16 Aug 2013 07:02:17 +0000 (07:02 +0000)]
Provide UTF-8 version of russian calendars.

10 years agoMark the makefs(8) '-p' flag as deprecated in preference for
gjb [Fri, 16 Aug 2013 05:30:13 +0000 (05:30 +0000)]
Mark the makefs(8) '-p' flag as deprecated in preference for
the '-Z' flag for compatibility with NetBSD.

Submitted by: Eric van Gyzen (via stable@)
MFC after: 3 days

10 years agoUse strdup(9) instead of reimplementing it.
markj [Fri, 16 Aug 2013 03:41:41 +0000 (03:41 +0000)]
Use strdup(9) instead of reimplementing it.

10 years agoFix ordering of legacy IRQ reservations.
grehan [Fri, 16 Aug 2013 00:35:20 +0000 (00:35 +0000)]
Fix ordering of legacy IRQ reservations.

Submitted by: Jeremiah Lott   jlott at averesystems dot com

10 years agoChange the way that unmapped I/O capability is advertised.
ken [Thu, 15 Aug 2013 22:52:39 +0000 (22:52 +0000)]
Change the way that unmapped I/O capability is advertised.

The previous method was to set the D_UNMAPPED_IO flag in the cdevsw
for the driver.  The problem with this is that in many cases (e.g.
sa(4)) there may be some instances of the driver that can handle
unmapped I/O and some that can't.  The isp(4) driver can handle
unmapped I/O, but the esp(4) driver currently cannot.  The cdevsw
is shared among all driver instances.

So instead of setting a flag on the cdevsw, set a flag on the cdev.
This allows drivers to indicate support for unmapped I/O on a
per-instance basis.

sys/conf.h: Remove the D_UNMAPPED_IO cdevsw flag and replace it
with an SI_UNMAPPED cdev flag.

kern_physio.c: Look at the cdev SI_UNMAPPED flag to determine
whether or not a particular driver can handle
unmapped I/O.

geom_dev.c: Set the SI_UNMAPPED flag for all GEOM cdevs.
Since GEOM will create a temporary mapping when
needed, setting SI_UNMAPPED unconditionally will
work.

Remove the D_UNMAPPED_IO flag.

nvme_ns.c: Set the SI_UNMAPPED flag on cdevs created here
if NVME_UNMAPPED_BIO_SUPPORT is enabled.

vfs_aio.c: In aio_qphysio(), check the SI_UNMAPPED flag on a
cdev instead of the D_UNMAPPED_IO flag on the cdevsw.

sys/param.h: Bump __FreeBSD_version to 1000045 for the switch from
setting the D_UNMAPPED_IO flag in the cdevsw to setting
SI_UNMAPPED in the cdev.

Reviewed by: kib, jimharris
MFC after: 1 week
Sponsored by: Spectra Logic

10 years agosigsuspend(2): Add xrefs to pselect(2) and sigwait-alikes.
jilles [Thu, 15 Aug 2013 22:33:27 +0000 (22:33 +0000)]
sigsuspend(2): Add xrefs to pselect(2) and sigwait-alikes.

10 years ago - Fix bug in r254304. Use the ACTIVE pq count for the active list
jeff [Thu, 15 Aug 2013 22:29:49 +0000 (22:29 +0000)]
 - Fix bug in r254304.  Use the ACTIVE pq count for the active list
   processing, not inactive.  This was the result of a bad merge.

Reported by: pho
Sponsored by: EMC / Isilon Storage Division

10 years agoSimplify check for CMPXCHG8B instruction. Note CMPXCHG8B instruction is
jkim [Thu, 15 Aug 2013 21:09:05 +0000 (21:09 +0000)]
Simplify check for CMPXCHG8B instruction.  Note CMPXCHG8B instruction is
always available for Rise mP6 processors although it is not set by CPUID.

10 years agoChange the queue of locks in kern_rangelock.c from holding lock requests in
cperciva [Thu, 15 Aug 2013 20:19:17 +0000 (20:19 +0000)]
Change the queue of locks in kern_rangelock.c from holding lock requests in
the order that they arrive, to holding
(a) granted write lock requests, followed by
(b) granted read lock requests, followed by
(c) ungranted requests, in order of arrival.

This changes the stopping condition for iterating through granted locks to
see if a new request can be granted: When considering a read lock request,
we can stop iterating as soon as we see a read lock request, since anything
after that point is either a granted read lock request or a request which
has not yet been granted.  (For write lock requests, we must still compare
against all granted lock requests.)

For workloads with R parallel reads and W parallel writes, this improves
the time spent from O((R+W)^2) to O(W*(R+W)); i.e., heavy parallel-read
workloads become significantly more scalable.

No statistically significant change in buildworld time has been measured,
but synthetic tests of parallel 'dd > /dev/null' and 'openssl enc >/dev/null'
with the input file cached yield dramatic (up to 10x) improvement with high
(up to 128 processes) levels of parallelism.

Reviewed by: kib

10 years agoAvoid potential redefinition of the macro.
jkim [Thu, 15 Aug 2013 20:03:22 +0000 (20:03 +0000)]
Avoid potential redefinition of the macro.

10 years agoTurn comments about locking into actual lock assertions.
trasz [Thu, 15 Aug 2013 20:00:32 +0000 (20:00 +0000)]
Turn comments about locking into actual lock assertions.

Reviewed by: ken
Tested by: ken
MFC after: 1 month

10 years agoUse an ANSI C definition of initializecpucache() to match the declaration
brooks [Thu, 15 Aug 2013 17:44:44 +0000 (17:44 +0000)]
Use an ANSI C definition of initializecpucache() to match the declaration
and the rest of the file.

10 years agoCall set_i8254_freq with MODE_STOP (0) rather than a magic number of 0.
brooks [Thu, 15 Aug 2013 17:21:06 +0000 (17:21 +0000)]
Call set_i8254_freq with MODE_STOP (0) rather than a magic number of 0.

10 years agoExport the maxio field in the CAM XPT_PATH_INQ CCB in the isp(4)
ken [Thu, 15 Aug 2013 16:41:27 +0000 (16:41 +0000)]
Export the maxio field in the CAM XPT_PATH_INQ CCB in the isp(4)
driver.

This tells consumers up the stack the maximum I/O size that the
controller can handle.

The I/O size is bounded by the number of scatter/gather segments
the controller can handle and the page size.  For an amd64 system,
it works out to around 5MB.

Reviewed by: mjacob
MFC after: 3 days
Sponsored by: Spectra Logic

10 years ago- Add myself in committers-ports.dot
nemysis [Thu, 15 Aug 2013 16:03:09 +0000 (16:03 +0000)]
- Add myself in committers-ports.dot

Approved by: miwi/wxs/wg (mentors)

10 years agoOn the recovery path for vm_page_alloc(), if a page had been requested
attilio [Thu, 15 Aug 2013 11:01:25 +0000 (11:01 +0000)]
On the recovery path for vm_page_alloc(), if a page had been requested
wired, unwind back the wiring bits otherwise we can end up freeing a
page that is considered wired.

Sponsored by: EMC / Isilon storage division
Reported by: alc

10 years agoBelatedly bump __FreeBSD_version for libc being an ld script.
jlh [Thu, 15 Aug 2013 08:21:00 +0000 (08:21 +0000)]
Belatedly bump __FreeBSD_version for libc being an ld script.
This should have been done in r251668, on June 12, 2013.

This will have no practical consequences, besides having -lssp_nonshared
appearing twice on the command-line for systems built in this time frame.

10 years agoMake sendfile() a method in the struct fileops. Currently only
glebius [Thu, 15 Aug 2013 07:54:31 +0000 (07:54 +0000)]
Make sendfile() a method in the struct fileops.  Currently only
vnode backed file descriptors have this method implemented.

Reviewed by: kib
Sponsored by: Nginx, Inc.
Sponsored by: Netflix

10 years agoFix a typo.
markj [Thu, 15 Aug 2013 04:10:15 +0000 (04:10 +0000)]
Fix a typo.

MFC after: 3 days

10 years agoSpecify SDT probe argument types in the probe definition itself rather than
markj [Thu, 15 Aug 2013 04:08:55 +0000 (04:08 +0000)]
Specify SDT probe argument types in the probe definition itself rather than
using SDT_PROBE_ARGTYPE(). This will make it easy to extend the SDT(9) API
to allow probes with dynamically-translated types.

There is no functional change.

MFC after: 2 weeks

10 years agoSome objects - such as *_genassym.o are not hooked into
sjg [Wed, 14 Aug 2013 22:19:29 +0000 (22:19 +0000)]
Some objects - such as *_genassym.o are not hooked into
SRCS OBJS or anything else, yet have a dependency on symlinks
such as machine/

Reviewed by: obrien

10 years agosh: Recognize "--" as end of options in local builtin.
jilles [Wed, 14 Aug 2013 21:59:48 +0000 (21:59 +0000)]
sh: Recognize "--" as end of options in local builtin.

10 years agoDon't send uninitialized memory (two instances of 4 bytes) in
tuexen [Wed, 14 Aug 2013 21:51:32 +0000 (21:51 +0000)]
Don't send uninitialized memory (two instances of 4 bytes) in
every cookie on the wire. This bug was reported in
https://bugzilla.mozilla.org/show_bug.cgi?id=905080

MFC after: 3 days

10 years agoFix several performance related issues in the new NFS server's
rmacklem [Wed, 14 Aug 2013 21:11:26 +0000 (21:11 +0000)]
Fix several performance related issues in the new NFS server's
DRC for NFS over TCP.
- Increase the size of the hash tables.
- Create a separate mutex for each hash list of the TCP hash table.
- Single thread the code that deletes stale cache entries.
- Add a tunable called vfs.nfsd.tcphighwater, which can be increased
  to allow the cache to grow larger, avoiding the overhead of frequent
  scans to delete stale cache entries.
  (The default value will result in frequent scans to delete stale cache
   entries, analagous to what the pre-patched code does.)
- Add a tunable called vfs.nfsd.cachetcp that can be used to disable
  DRC caching for NFS over TCP, since the old NFS server didn't DRC cache TCP.
It also adjusts the size of nfsrc_floodlevel dynamically, so that it is
always greater than vfs.nfsd.tcphighwater.

For UDP the algorithm remains the same as the pre-patched code, but the
tunable vfs.nfsd.udphighwater can be used to allow the cache to grow
larger and reduce the overhead caused by frequent scans for stale entries.
UDP also uses a larger hash table size than the pre-patched code.

Reported by: wollman
Tested by: wollman (earlier version of patch)
Submitted by: ivoras (earlier patch)
Reviewed by: jhb (earlier version of patch)
MFC after: 1 month

10 years agosh: Allow a lone redirection before '|', ';;' or ';&'.
jilles [Wed, 14 Aug 2013 19:34:13 +0000 (19:34 +0000)]
sh: Allow a lone redirection before '|', ';;' or ';&'.

Example: </dev/null | :

PR: 181240
MFC after: 1 week

10 years agoIf sys/param.h MAXPHYS has been tuned to exceed MFI_MAXPHYS, the mfi(4)
sbruno [Wed, 14 Aug 2013 15:50:34 +0000 (15:50 +0000)]
If sys/param.h MAXPHYS has been tuned to exceed MFI_MAXPHYS, the mfi(4)
real JBOD mode (SYS PD) would fail fairly reliably during I/O.

Steal the mfi_disk.c check for this condition (indirectly) when establishing
d_maxsize.

Reviewed by: ambrisko@
MFC after: 4 weeks
Sponsored by: Yahoo! Inc.

10 years agoAdded 4K quirks for:-
smh [Wed, 14 Aug 2013 15:18:28 +0000 (15:18 +0000)]
Added 4K quirks for:-
* OCZ Agility 2 SSDs
* Marvell SSDs
* Intel X25-M Series SSDs

10 years agoRemove the {SRC,DOC,PORT}REVISION variables from release(7), and
gjb [Wed, 14 Aug 2013 14:45:47 +0000 (14:45 +0000)]
Remove the {SRC,DOC,PORT}REVISION variables from release(7), and
update the default {SRC,DOC,PORT}BRANCH defaults.

Submitted by: nwhitehorn
X-MFC-With: r254224, r254294
X-MFC-To: stable/9, releng/9.2

10 years agoMake carets line up in dtc diagnostics if the line starts with a tab.
theraven [Wed, 14 Aug 2013 14:34:02 +0000 (14:34 +0000)]
Make carets line up in dtc diagnostics if the line starts with a tab.

10 years agoext2fs: update format specifiers for ext4 type.
pfg [Wed, 14 Aug 2013 14:22:46 +0000 (14:22 +0000)]
ext2fs: update format specifiers for ext4 type.

Previous bandaid was not appropriate and didn't really work for
all platforms. While here, cleanup the surrounding code to match
ffs_checkoverlap()

Reported by: dim, jmallet and bde
MFC after: 3 weeks

10 years agoBelatedly add my birthday and fix a typo.
uqs [Wed, 14 Aug 2013 08:10:54 +0000 (08:10 +0000)]
Belatedly add my birthday and fix a typo.

10 years agoFix make depend
uqs [Wed, 14 Aug 2013 08:03:57 +0000 (08:03 +0000)]
Fix make depend

10 years agoReplace the homegrown implementation of nitems() with calls to nitems()
rpaulo [Wed, 14 Aug 2013 04:24:25 +0000 (04:24 +0000)]
Replace the homegrown implementation of nitems() with calls to nitems()
(param.h).

Operating systems that don't have nitems() can easily define it on their own
net80211 OS-specific header file.

Discussed with: adrian

10 years agoUse kld_{load,unload} instead of mod_{load,unload} for the linker file load
markj [Wed, 14 Aug 2013 00:42:21 +0000 (00:42 +0000)]
Use kld_{load,unload} instead of mod_{load,unload} for the linker file load
and unload event handlers added in r254266.

Reported by: jhb
X-MFC with: r254266

10 years ago - Disable quantum caches on the kmem_arena. This can make fragmentation
jeff [Tue, 13 Aug 2013 22:41:24 +0000 (22:41 +0000)]
 - Disable quantum caches on the kmem_arena.  This can make fragmentation
   worse on small KVA systems.  I had intended to only enable it for
   debugging.

Sponsored by: EMC / Isilon Storage Division

10 years ago - Add a statically allocated memguard arena since it is needed very early
jeff [Tue, 13 Aug 2013 22:40:43 +0000 (22:40 +0000)]
 - Add a statically allocated memguard arena since it is needed very early
   on.
 - Pass the appropriate flags to vmem_xalloc() when allocating space for
   the arena from kmem_arena.

Sponsored by: EMC / Isilon Storage Division

10 years agoMerge acpica_machdep.h for amd64 and i386 and move to x86. In fact, these
jkim [Tue, 13 Aug 2013 22:05:10 +0000 (22:05 +0000)]
Merge acpica_machdep.h for amd64 and i386 and move to x86.  In fact, these
two files were functionally identical.

10 years agoImprove pageout flow control to wakeup more frequently and do less work while
jeff [Tue, 13 Aug 2013 21:56:16 +0000 (21:56 +0000)]
Improve pageout flow control to wakeup more frequently and do less work while
maintaining better LRU of active pages.

 - Change v_free_target to include the quantity previously represented by
   v_cache_min so we don't need to add them together everywhere we use them.
 - Add a pageout_wakeup_thresh that sets the free page count trigger for
   waking the page daemon.  Set this 10% above v_free_min so we wakeup before
   any phase transitions in vm users.
 - Adjust down v_free_target now that we're willing to accept more pagedaemon
   wakeups.  This means we process fewer pages in one iteration as well,
   leading to shorter lock hold times and less overall disruption.
 - Eliminate vm_pageout_page_stats().  This was a minor variation on the
   PQ_ACTIVE segment of the normal pageout daemon.  Instead we now process
   1 / vm_pageout_update_period pages every second.  This causes us to visit
   the whole active list every 60 seconds.  Previously we would only maintain
   the active LRU when we were short on pages which would mean it could be
   woefully out of date.

Reviewed by: alc (slight variant of this)
Discussed with: alc, kib, jhb
Sponsored by: EMC / Isilon Storage Division

10 years agoIf a controller fails to initialize, do not notify consumers (nvd) of its
jimharris [Tue, 13 Aug 2013 21:49:32 +0000 (21:49 +0000)]
If a controller fails to initialize, do not notify consumers (nvd) of its
namespaces.

Sponsoredy by: Intel
Reviewed by: carl
MFC after: 3 days

10 years agoSend a shutdown notification in the driver unload path, to ensure
jimharris [Tue, 13 Aug 2013 21:47:08 +0000 (21:47 +0000)]
Send a shutdown notification in the driver unload path, to ensure
notification gets sent in cases where system shuts down with driver
unloaded.

Sponsored by: Intel
Reviewed by: carl
MFC after: 3 days

10 years agolibc: Use O_CLOEXEC when writing gmon files (cc -pg).
jilles [Tue, 13 Aug 2013 21:45:48 +0000 (21:45 +0000)]
libc: Use O_CLOEXEC when writing gmon files (cc -pg).

10 years agoTidy up global locks for ACPICA. There is no functional change.
jkim [Tue, 13 Aug 2013 21:34:03 +0000 (21:34 +0000)]
Tidy up global locks for ACPICA.  There is no functional change.

10 years agoRename imx_machdep.c to imx51_machdep.c, because it contains hardware
ian [Tue, 13 Aug 2013 21:12:28 +0000 (21:12 +0000)]
Rename imx_machdep.c to imx51_machdep.c, because it contains hardware
addresses which are specific to the imx51 chips.

10 years agoRemove get_rev_branch(), functionality exists in the release/Makefile.
gjb [Tue, 13 Aug 2013 21:01:23 +0000 (21:01 +0000)]
Remove get_rev_branch(), functionality exists in the release/Makefile.

Submitted by: hrs

10 years agovfork(2) was listed as deprecated in 1994 (r1573) and was the false
peter [Tue, 13 Aug 2013 20:38:55 +0000 (20:38 +0000)]
vfork(2) was listed as deprecated in 1994 (r1573) and was the false
reports of its impending demise were removed in 2009 (r199257).

However, in 1996 (r16117) system(3) was switched from vfork(2) to
fork(2) based partly on this.  Switch back to vfork(2).  This has a
dramatic effect in cases of extreme mmap use - such as excessive
abuse (500+) of shared libraries.

popen(3) has used vfork(2) for a while.  vfork(2) isn't going anywhere.

10 years agokdump: Decode AT_FDCWD in first argument of bindat() and connectat().
jilles [Tue, 13 Aug 2013 20:33:50 +0000 (20:33 +0000)]
kdump: Decode AT_FDCWD in first argument of bindat() and connectat().

10 years agoTeach libstdc++ about logl(3).
pfg [Tue, 13 Aug 2013 20:28:21 +0000 (20:28 +0000)]
Teach libstdc++ about logl(3).

The logl(3) family of functions were implemented in r251292.
Define them in libstdc++'s configuration so they can be used.

Reviewed by: dim

10 years ago- Remove the defaults for TARGET/TARGET_ARCH.
gjb [Tue, 13 Aug 2013 20:22:57 +0000 (20:22 +0000)]
- Remove the defaults for TARGET/TARGET_ARCH.

- Note that WORLD_FLAGS and KERNEL_FLAGS set the number of
  make(1) jobs only on SMP-capable systems.

MFC after: 3 days
X-MFC-With: r254224
X-MFC-To: stable/9, releng/9.2

10 years ago- Only set ARCH_FLAGS (TARGET/TARGET_ARCH) if specified, otherwise
gjb [Tue, 13 Aug 2013 20:16:14 +0000 (20:16 +0000)]
- Only set ARCH_FLAGS (TARGET/TARGET_ARCH) if specified, otherwise
  allow the toolchain to detect the correct values.

- Remove {SRC,DOC,PORT}REVISION variables, and use 'branch@rNNNNNN'
  as the {SRC,DOC,PORT}BRANCH variables.

- Only set default KERNEL_FLAGS and WORLD_FLAGS make(1) jobs if the
  number of CPUs is greater than 1.

Submitted by: hrs

10 years agoVirtualize carp(4) variables to have per vnet control.
trociny [Tue, 13 Aug 2013 19:59:49 +0000 (19:59 +0000)]
Virtualize carp(4) variables to have per vnet control.

Reviewed by: ae, glebius

10 years agokdump: Improve decoding of various *at calls:
jilles [Tue, 13 Aug 2013 19:57:35 +0000 (19:57 +0000)]
kdump: Improve decoding of various *at calls:

* Write AT_FDCWD where appropriate.
* Decode the remaining arguments of openat() etc like open() etc.