]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
9 years agoAdd the arm64 parts of libthread_db.
andrew [Wed, 1 Apr 2015 08:37:50 +0000 (08:37 +0000)]
Add the arm64 parts of libthread_db.

Differential Revision: https://reviews.freebsd.org/D2184
Reviewed by: imp
Sponsored by: The FreeBSD Foundation

9 years agoAdd the arm64 defines for cddl code.
andrew [Wed, 1 Apr 2015 08:31:56 +0000 (08:31 +0000)]
Add the arm64 defines for cddl code.

Differential Revision: https://reviews.freebsd.org/D2186
Reviewed by: emaste
Sponsored by: The FreeBSD Foundation

9 years agoMove the efi loaders to be under sys/boot/efi. This will help us add
andrew [Wed, 1 Apr 2015 08:30:40 +0000 (08:30 +0000)]
Move the efi loaders to be under sys/boot/efi. This will help us add
support for booting arm and arm64 from UEFI.

Differential Revision: https://reviews.freebsd.org/D2164
Reviewed by: emaste, imp (previous version)
Sponsored by: The FreeBSD Foundation

9 years agoRefine r280308. Do not completely disable timestamping of devfs nodes
kib [Wed, 1 Apr 2015 08:25:40 +0000 (08:25 +0000)]
Refine r280308.  Do not completely disable timestamping of devfs nodes
on reads or writes, the time marks are used to display idle time by
w(1) [1].  Instead, use vfs.devfs.dotimes as the selector of default
precision vs. using time_second.  The later gives seconds precision,
which is good enough for the purpose.

Note that timestamp updates are unlocked and the updates itself, as
well as the check in devfs_timestamp, are non-atomic.

Noted by: truckman [1]
Reviewed by: bde
Sponsored by: The FreeBSD Foundation
MFC after: 1 week

9 years agoMigrate the TL-WR1043nd v2 to use the new map based MAC hints mechanism.
adrian [Wed, 1 Apr 2015 06:44:39 +0000 (06:44 +0000)]
Migrate the TL-WR1043nd v2 to use the new map based MAC hints mechanism.

This programs separate, correct mac addresses for the ethernet and
wlan interfaces.

9 years agoDon't use a private copy of the ANI definitions - use the HAL definitions.
adrian [Wed, 1 Apr 2015 04:57:27 +0000 (04:57 +0000)]
Don't use a private copy of the ANI definitions - use the HAL definitions.

Whilst I'm at it:

* fix the NI+ to be correct, rather than NI-;
* use the diag api codes, now that the HAL is public.

Tested:

* AR9380, STA mode

9 years agoUse the HAL API for returning ar5212AniState, rather than just dumping
adrian [Wed, 1 Apr 2015 04:56:22 +0000 (04:56 +0000)]
Use the HAL API for returning ar5212AniState, rather than just dumping
AniState itself.

9 years agoExpose the ANI state / statistics using the public ANI function, rather than
adrian [Wed, 1 Apr 2015 04:56:10 +0000 (04:56 +0000)]
Expose the ANI state / statistics using the public ANI function, rather than
the ar9300_* definitions.

.. which of course don't match, and athstats was reading garbage ANI
data.

9 years agoStart the process of migrating the ANI statistics out of the HALs and into
adrian [Wed, 1 Apr 2015 03:42:46 +0000 (03:42 +0000)]
Start the process of migrating the ANI statistics out of the HALs and into
the top-level HAL.

The athstats program is blindly using a copy of the ar5212 ANI stats structure
to pull out ANI statistics/state and this is problematic for the AR9300
HAL.

So:

* Define HAL_ANI_STATS and HAL_ANI_STATE
* Use HAL_ANI_STATS inside the AR5212 HAL

This commit doesn't (yet) convert the ar5212AniState -> HAL_ANI_STATE when
exporting it to userland; that'll come in the next commit.

9 years agoWhoops! "arc commit --revision" != "arc diff --update"
dteske [Wed, 1 Apr 2015 02:05:26 +0000 (02:05 +0000)]
Whoops! "arc commit --revision" != "arc diff --update"

9 years agoAdd "GELI Passphrase:" prompt to boot loader.
dteske [Wed, 1 Apr 2015 02:01:34 +0000 (02:01 +0000)]
Add "GELI Passphrase:" prompt to boot loader.

Summary:
Add "GELI Passphrase:" prompt to boot loader.

A new loader.conf(5) option of geom_eli_passphrase_prompt="YES" will now
allow you to enter your geli(8) root-mount credentials prior to invoking
the kernel.

See check-password.4th(8) for details.

Differential Revision: https://reviews.freebsd.org/D2105
Reviewed by: (your name[s] here)
MFC after: 3 days
X-MFC-to: stable/10
Relnotes: yes

Test Plan:
Drop a head copy of check-password.4th into /boot and then apply the patch
(only the patch to /boot/check-password.4th is required; no other changes are
required but you do have to have a HEAD copy of check-password.4th to
apply the patch).

NB: The rest of your /boot files can be up to 2 years old but no older.
NB: The test won't work unless your kernel has the following change

https://svnweb.freebsd.org/base?view=revision&revision=273489

Now, put into /boot/loader.conf:

geom_eli_passphrase_prompt="YES"

and reboot.

You should be prompted for a GELI passphrase before the menu (if enabled),
just after loading loader.conf(5).

NB: It doesn't matter if you're using GELI or not. However if you are using
GELI and a sufficiently new enough release (has SVN r273489) and you entered
the proper passphrase to mount your GELI encrypted root device(s), you should
notice that the boot process did not stop (you went from loader all the way to login).

Reviewers: cperciva, allanjude, scottl, kmoore

Subscribers: jkh, imp

Differential Revision: https://reviews.freebsd.org/D2105

9 years agoSolve dreaded "dictionary full" issue by segregating words into new
dteske [Wed, 1 Apr 2015 01:54:28 +0000 (01:54 +0000)]
Solve dreaded "dictionary full" issue by segregating words into new
vocabularies delay-processing, password-processing, version-processing,
frame-drawing, menu-infrastructure, menu-namespace, menu-command-helpers,
and menusets-infrastructure. The net effect is to remove almost 200
definitions from the main forth vocabulary reducing the dictionary size
by over 50%. The chances of hitting "dictionary full" should be greatly
reduced by this patch.

MFC after: 3 days
X-MFC-to: stable/10

9 years agoWhen forced to draw ASCII lines/boxen, use `=' for the horizontal line
dteske [Wed, 1 Apr 2015 01:25:58 +0000 (01:25 +0000)]
When forced to draw ASCII lines/boxen, use `=' for the horizontal line
when double frames are requested versus single.

MFC after: 3 days
X-MFC-to: stable/10

9 years agoSecurely overwrite (zero) user input when we finish password checks.
dteske [Wed, 1 Apr 2015 01:22:30 +0000 (01:22 +0000)]
Securely overwrite (zero) user input when we finish password checks.

MFC after: 3 days
X-MFC-to: stable/10

9 years agoAdd remainder of supported ANSI escape sequences.
dteske [Wed, 1 Apr 2015 01:17:36 +0000 (01:17 +0000)]
Add remainder of supported ANSI escape sequences.

MFC after: 3 days
X-MFC-to: stable/10

9 years agoMove beastie to logo-*.4th; brands to brand-*.4th
dteske [Wed, 1 Apr 2015 01:14:19 +0000 (01:14 +0000)]
Move beastie to logo-*.4th; brands to brand-*.4th

Suggested by: jkh, alfred
MFC after: 3 days
X-MFC-to: stable/10

9 years agoUpdate elftoolchain to upstream revision 3179
emaste [Wed, 1 Apr 2015 01:08:01 +0000 (01:08 +0000)]
Update elftoolchain to upstream revision 3179

Some notable changes:
- libdwarf: Fixed DWARF4 line section
- elfcopy: Implement --localize-hidden
- nm: handle object name referenced by DW_AT_specification
- elfcopy: Add --strip-dwo and --extract-dwo options for split DWARF
- readelf: add remaining arm64 dynamic relocation names
- nm: Avoid integer overflow in value comparison

Relnotes: Yes
Sponsored by: The FreeBSD Foundation

9 years agoComments. No functional change.
dteske [Wed, 1 Apr 2015 00:49:34 +0000 (00:49 +0000)]
Comments. No functional change.

MFC after: 3 days
X-MFC-to: stable/10

9 years agoFix overflow bugs in and remove obsolete limit from kernel RPC
wollman [Wed, 1 Apr 2015 00:45:47 +0000 (00:45 +0000)]
Fix overflow bugs in and remove obsolete limit from kernel RPC
implementation.

The kernel RPC code, which is responsible for the low-level scheduling
of incoming NFS requests, contains a throttling mechanism that
prevents too much kernel memory from being tied up by NFS requests
that are being serviced.  When the throttle is engaged, the RPC layer
stops servicing incoming NFS sockets, resulting ultimately in
backpressure on the clients (if they're using TCP).  However, this is
a very heavy-handed mechanism as it prevents all clients from making
any requests, regardless of how heavy or light they are.  (Thus, when
engaged, the throttle often prevents clients from even mounting the
filesystem.)  The throttle mechanism applies specifically to requests
that have been received by the RPC layer (from a TCP or UDP socket)
and are queued waiting to be serviced by one of the nfsd threads; it
does not limit the amount of backlog in the socket buffers.

The original implementation limited the total bytes of queued requests
to the minimum of a quarter of (nmbclusters * MCLBYTES) and 45 MiB.
The former limit seems reasonable, since requests queued in the socket
buffers and replies being constructed to the requests in progress will
all require some amount of network memory, but the 45 MiB limit is
plainly ridiculous for modern memory sizes: when running 256 service
threads on a busy server, 45 MiB would result in just a single
maximum-sized NFS3PROC_WRITE queued per thread before throttling.

Removing this limit exposed integer-overflow bugs in the original
computation, and related bugs in the routines that actually account
for the amount of traffic enqueued for service threads.  The old
implementation also attempted to reduce accounting overhead by
batching updates until each queue is fully drained, but this is prone
to livelock, resulting in repeated accumulate-throttle-drain cycles on
a busy server.  Various data types are changed to long or unsigned
long; explicit 64-bit types are not used due to the unavailability of
64-bit atomics on many 32-bit platforms, but those platforms also
cannot support nmbclusters large enough to cause overflow.

This code (in a 10.1 kernel) is presently running on production NFS
servers at CSAIL.

Summary of this revision:
* Removes 45 MiB limit on requests queued for nfsd service threads
* Fixes integer-overflow and signedness bugs
* Avoids unnecessary throttling by not deferring accounting for
  completed requests

Differential Revision: https://reviews.freebsd.org/D2165
Reviewed by: rmacklem, mav
MFC after: 30 days
Relnotes: yes
Sponsored by: MIT Computer Science & Artificial Intelligence Laboratory

9 years agoFix "MOVS" instruction memory to MMIO emulation. Currently updates to
tychon [Wed, 1 Apr 2015 00:15:31 +0000 (00:15 +0000)]
Fix "MOVS" instruction memory to MMIO emulation.  Currently updates to
%rdi, %rsi, etc are inadvertently bypassed along with the check to
see if the instruction needs to be repeated per the 'rep' prefix.

Add "MOVS" instruction support for the 'MMIO to MMIO' case.

Reviewed by: neel

9 years agoAdd code for creating an EC2 AMI.
cperciva [Wed, 1 Apr 2015 00:00:17 +0000 (00:00 +0000)]
Add code for creating an EC2 AMI.

9 years agoWhitespace and cleanup. No functional change(s).
dteske [Tue, 31 Mar 2015 23:09:54 +0000 (23:09 +0000)]
Whitespace and cleanup. No functional change(s).

MFC after: 3 days
X-MFC-to: stable/10

9 years agoOptimize bootmsg to use fg/bg/me from screen.4th
dteske [Tue, 31 Mar 2015 23:00:48 +0000 (23:00 +0000)]
Optimize bootmsg to use fg/bg/me from screen.4th
NB: screen.4th is included by way of check-password.4th

MFC after: 3 days
X-MFC-to: stable/10

9 years agoComments. No functional change(s).
dteske [Tue, 31 Mar 2015 22:32:35 +0000 (22:32 +0000)]
Comments. No functional change(s).

MFC after: 3 days
X-MFC-to: stable/10

9 years agoWhitespace. No functional change(s).
dteske [Tue, 31 Mar 2015 22:10:40 +0000 (22:10 +0000)]
Whitespace. No functional change(s).

MFC after: 3 days
MFH: stable/10

9 years agoChange contents of the exec variable in loader.conf to be friendly to both
dteske [Tue, 31 Mar 2015 21:46:44 +0000 (21:46 +0000)]
Change contents of the exec variable in loader.conf to be friendly to both
Ficl/Forth and Lua. No visible change for Forth while enabling Lua support.

Submitted by: rpaulo

9 years agoFix typo in a comment.
dteske [Tue, 31 Mar 2015 21:34:42 +0000 (21:34 +0000)]
Fix typo in a comment.

MFC after: 3 days
X-MFC-to: stable/10 stable/9

9 years agosh: Add more tests for exotic IFS splitting.
jilles [Tue, 31 Mar 2015 20:59:37 +0000 (20:59 +0000)]
sh: Add more tests for exotic IFS splitting.

9 years agowordexp: Explicitly pass along IFS.
jilles [Tue, 31 Mar 2015 20:51:01 +0000 (20:51 +0000)]
wordexp: Explicitly pass along IFS.

Per Austin group issue #884, sh should not import IFS from the environment
but always set it to $' \t\n'. For wordexp(), however, it is documented and
useful for it to use IFS from the environment.

Since sh currently imports IFS from the environment, this change has no
functional effect.

MFC after: 1 week

9 years agoAdd limited to the default restrictions.
delphij [Tue, 31 Mar 2015 19:56:46 +0000 (19:56 +0000)]
Add limited to the default restrictions.

X-MFC-with: r280849

9 years agoFix build.
cy [Tue, 31 Mar 2015 19:35:32 +0000 (19:35 +0000)]
Fix build.

9 years agoConstify.
delphij [Tue, 31 Mar 2015 19:12:13 +0000 (19:12 +0000)]
Constify.

Suggested by: rdivacky
MFC after: 2 weeks

9 years agoAdd the fe* symbols to libm for arm64.
andrew [Tue, 31 Mar 2015 19:07:28 +0000 (19:07 +0000)]
Add the fe* symbols to libm for arm64.

Sponsored by: The FreeBSD Foundation

9 years agoRemove bogus cast.
kevlo [Tue, 31 Mar 2015 15:03:58 +0000 (15:03 +0000)]
Remove bogus cast.

9 years agoThe offset variable has been cleared all bits except IP6F_OFF_MASK.
ae [Tue, 31 Mar 2015 14:41:29 +0000 (14:41 +0000)]
The offset variable has been cleared all bits except IP6F_OFF_MASK.
Use ip6f_mf variable instead of checking its bits.

9 years agounwind-d2 build workaround for arm64
emaste [Tue, 31 Mar 2015 13:37:32 +0000 (13:37 +0000)]
unwind-d2 build workaround for arm64

The __builtin_init_dwarf_reg_size_table function is unimplemented in
clang 3.6 for AArch64. Comment it out for now and replace it with
a message and abort.

Tracked in upstream LLVM PR 22997
https://llvm.org/bugs/show_bug.cgi?id=22997

Submitted by: andrew

9 years agoCorrect copyright typo
emaste [Tue, 31 Mar 2015 12:53:07 +0000 (12:53 +0000)]
Correct copyright typo

9 years agoAdd kernel config files for Hardkernel Odroid-C1 and Visson ATV-102 devices.
ganbold [Tue, 31 Mar 2015 11:59:57 +0000 (11:59 +0000)]
Add kernel config files for Hardkernel Odroid-C1 and Visson ATV-102 devices.

Submitted by:   John Wehle
Approved by:   stas (mentor)

9 years agoAdd device tree files for Hardkernel Odroid-C1 and Visson ATV-102 devices.
ganbold [Tue, 31 Mar 2015 11:55:56 +0000 (11:55 +0000)]
Add device tree files for Hardkernel Odroid-C1 and Visson ATV-102 devices.

Submitted by: John Wehle
Approved by: stas (mentor)

9 years agoAdd necessary changes to support various Amlogic SoC devices
ganbold [Tue, 31 Mar 2015 11:50:46 +0000 (11:50 +0000)]
Add necessary changes to support various Amlogic SoC devices
specially aml8726-m6 and aml8726-m8b SoC based devices.
aml8726-m6 SoC exist in devices such as Visson ATV-102.
Hardkernel ODROID-C1 board has aml8726-m8b SoC.

The following support is included:
  Basic machdep code
  SMP
  Interrupt controller
  Clock control driver (aka gate)
  Pinctrl
  Timer
  Real time clock
  UART
  GPIO
  I2C
  SD controller
  SDXC controller
  USB
  Watchdog
  Random number generator
  PLL / Clock frequency measurement
  Frame buffer

Submitted by:   John Wehle
Approved by:    stas (mentor)

9 years agoUse appropriate timeout_t* instead of void* in tcp_timer_activate()
jch [Tue, 31 Mar 2015 10:17:13 +0000 (10:17 +0000)]
Use appropriate timeout_t* instead of void* in tcp_timer_activate()

Suggested by: imp
Differential Revision: https://reviews.freebsd.org/D2154
Reviewed by: imp, jhb
Approved by: jhb

9 years agoAdd the arm64 code to the runtime linker. It's not able to be built as we
andrew [Tue, 31 Mar 2015 09:51:19 +0000 (09:51 +0000)]
Add the arm64 code to the runtime linker. It's not able to be built as we
still need libc_pic for a few things, but this is expected to be ready
soon.

Differential Revision: https://reviews.freebsd.org/D2136
Reviewed by: kib
Sponsored by: The FreeBSD Foundation

9 years ago- Fix -Wsign issue
ngie [Tue, 31 Mar 2015 06:51:13 +0000 (06:51 +0000)]
- Fix -Wsign issue
- Bump up to WARNS=6

9 years agoMinor cleanup before converting to ATF testcases
ngie [Tue, 31 Mar 2015 06:50:28 +0000 (06:50 +0000)]
Minor cleanup before converting to ATF testcases

- Remove blank (tab-only) lines.
- Fix -Wunused warnings.
- Bump up to WARNS= 6

9 years agoCleanup and do minor refactoring before converting testcases to ATF
ngie [Tue, 31 Mar 2015 06:43:55 +0000 (06:43 +0000)]
Cleanup and do minor refactoring before converting testcases to ATF

- Convert errx(-1, ..) to errx(1, ..)
- Move the aio(4) checks to a single function (aio_available); use modfind(2)
  instead of depending on SIGSYS (doesn't work when aio(4) support is missing,
  not documented in the aio syscall manpages).
- Use aio_available liberally in the testcase functions
- Use mkstemp(3) + unlink(2) instead of mktemp(3)
- Fix some -Wunused warnings
- Bump WARNS to 6

MFC after: 1 week
Submitted by: mjohnston [*]
Sponsored by: EMC / Isilon Storage Division

9 years agoCCSRBAR_VA is mpc85xx-specific, so add guards, and include the proper header
jhibbits [Tue, 31 Mar 2015 05:29:44 +0000 (05:29 +0000)]
CCSRBAR_VA is mpc85xx-specific, so add guards, and include the proper header
file for it.

MFC after: 1 month

9 years agomachine/fdt.h no longer exists for powerpc.
jhibbits [Tue, 31 Mar 2015 05:26:30 +0000 (05:26 +0000)]
machine/fdt.h no longer exists for powerpc.

MFC after: 1 month

9 years ago- Remove more files when MK_ZONEINFO == no
amdmi3 [Tue, 31 Mar 2015 04:44:46 +0000 (04:44 +0000)]
- Remove more files when MK_ZONEINFO == no

MFC after: 1 week
Reviewed by: ngie
Approved by: ngie
Differential Revision: D1600

9 years ago- Remove more files when MK_TESTS_SUPPORT == no
amdmi3 [Tue, 31 Mar 2015 04:43:25 +0000 (04:43 +0000)]
- Remove more files when MK_TESTS_SUPPORT == no

MFC after: 1 week
Reviewed by: ngie
Approved by: ngie
Differential Revision: D1600

9 years ago- Remove more files when MK_LEGACY_CONSOLE == no
amdmi3 [Tue, 31 Mar 2015 04:42:00 +0000 (04:42 +0000)]
- Remove more files when MK_LEGACY_CONSOLE == no

MFC after: 1 week
Reviewed by: ngie
Approved by: ngie
Differential Revision: D1600

9 years ago- Remove more files when MK_KERBEROS_SUPPORT == no
amdmi3 [Tue, 31 Mar 2015 04:39:59 +0000 (04:39 +0000)]
- Remove more files when MK_KERBEROS_SUPPORT == no

MFC after: 1 week
Reviewed by: ngie
Approved by: ngie
Differential Revision: D1600

9 years ago- Remove more files when MK_KDUMP == no
amdmi3 [Tue, 31 Mar 2015 04:37:57 +0000 (04:37 +0000)]
- Remove more files when MK_KDUMP == no

MFC after: 1 week
Reviewed by: ngie
Approved by: ngie
Differential Revision: D1600

9 years ago- Remove more files when MK_JAIL == no
amdmi3 [Tue, 31 Mar 2015 04:36:51 +0000 (04:36 +0000)]
- Remove more files when MK_JAIL == no

MFC after: 1 week
Reviewed by: ngie
Approved by: ngie
Differential Revision: D1600

9 years agoIt would help if I committed the right patch...
cperciva [Tue, 31 Mar 2015 04:35:35 +0000 (04:35 +0000)]
It would help if I committed the right patch...

9 years ago- Remove more files when MK_CASPER == no
amdmi3 [Tue, 31 Mar 2015 04:31:42 +0000 (04:31 +0000)]
- Remove more files when MK_CASPER == no

MFC after: 1 week
Reviewed by: ngie
Approved by: ngie
Differential Revision: D1600

9 years agoFix a misparenthesization that could cause a crash if TERM is not set.
markj [Tue, 31 Mar 2015 02:49:05 +0000 (02:49 +0000)]
Fix a misparenthesization that could cause a crash if TERM is not set.

Reported by: Coverity (internal)
MFC after: 3 days
Sponsored by: EMC / Isilon Storage Division

9 years agoPartially revert r278118 now that the required logic for deciding whether
cperciva [Tue, 31 Mar 2015 01:44:29 +0000 (01:44 +0000)]
Partially revert r278118 now that the required logic for deciding whether
freebsd-update can be useful has moved into the firstboot_freebsd_update
script.

9 years agoProvide workaround for a performance issue with the popcnt instruction
kib [Tue, 31 Mar 2015 01:44:07 +0000 (01:44 +0000)]
Provide workaround for a performance issue with the popcnt instruction
on Intel processors.  Clear spurious dependency by explicitely xoring
the destination register of popcnt.

Use bitcount64() instead of re-implementing SWAR locally, for
processors without popcnt instruction.

Reviewed by: jhb
Discussed with: jilles (previous version)
Sponsored by: The FreeBSD Foundation

9 years agoAdd bits for building EC2 disk images. Make logic for uploading these
cperciva [Tue, 31 Mar 2015 01:28:33 +0000 (01:28 +0000)]
Add bits for building EC2 disk images.  Make logic for uploading these
to create EC2 AMIs will come in a later commit.

9 years agocxgbe/tom: return rx credits promptly if the socket buffer's low water
np [Tue, 31 Mar 2015 01:22:20 +0000 (01:22 +0000)]
cxgbe/tom: return rx credits promptly if the socket buffer's low water
mark cannot be reached because the window advertised to the peer isn't
wide enough.  While here, tweak the normal credit return too.

MFC after: 1 month

9 years agoAdopt jhb's suggested changes, updated comments and callout_migration() moving
rrs [Tue, 31 Mar 2015 00:18:00 +0000 (00:18 +0000)]
Adopt jhb's suggested changes, updated comments and callout_migration() moving
to kern/kern_timeout.c

This does *not* address his -1 -> NOCPU comment.

Sponsored by: Netflix Inc.

9 years agoChange the c_iflags and c_flags fields to short rather then int. This
rrs [Tue, 31 Mar 2015 00:15:27 +0000 (00:15 +0000)]
Change the c_iflags and c_flags fields to short rather then int. This
allows us to keep the KPI the same.

Discussed and brain-stormed with imp (thanks for the help Warner!)
Sponsored by: Netflix Inc.

9 years agoFix --one-file-system to include the directory encountered rather than
bdrewery [Tue, 31 Mar 2015 00:00:47 +0000 (00:00 +0000)]
Fix --one-file-system to include the directory encountered rather than
excluding it.  This was broken in 3.0.4 (r238856).

Obtained from: https://github.com/libarchive/libarchive/commit/fa9e61
MFC after: 3 days
Sponsored by: EMC / Isilon Storage Division

9 years agoCatch up on r271387 and remove unused parameter from
glebius [Mon, 30 Mar 2015 22:49:26 +0000 (22:49 +0000)]
Catch up on r271387 and remove unused parameter from
VOP_GETPAGES_ASYNC().

9 years agoRestore setting cpufuncs on arm1176, it was removed by accident with the
andrew [Mon, 30 Mar 2015 20:44:08 +0000 (20:44 +0000)]
Restore setting cpufuncs on arm1176, it was removed by accident with the
arm1136 code.

Reviewed by: ian

9 years agoAdd llvm patch corresponding to r280865.
dim [Mon, 30 Mar 2015 20:23:06 +0000 (20:23 +0000)]
Add llvm patch corresponding to r280865.

9 years agoWait 100 microseconds for a local APIC to dispatch each startup-related IPI
jhb [Mon, 30 Mar 2015 20:13:22 +0000 (20:13 +0000)]
Wait 100 microseconds for a local APIC to dispatch each startup-related IPI
rather than 20.  The MP 1.4 specification states in Appendix B.2:

  "A period of 20 microseconds should be sufficient for IPI dispatch to
   complete under normal operating conditions".

(Note that this appears to be separate from the 10 millisecond (INIT) and
200 microsecond (STARTUP) waits after the IPIs are dispatched.)  The
Intel SDM is silent on this issue as far as I can tell.

At least some hardware requires 60 microseconds as noted in the PR, so
bump this to 100 to be on the safe side.

PR: 197756
Reported by: zaphod@berentweb.com
MFC after: 1 week

9 years agollvm: Backport upstream r229195 to fix arm64 TLS relocations
emaste [Mon, 30 Mar 2015 20:01:41 +0000 (20:01 +0000)]
llvm: Backport upstream r229195 to fix arm64 TLS relocations

  As is described at http://llvm.org/bugs/show_bug.cgi?id=22408, the GNU
  linkers ld.bfd and ld.gold currently only support a subset of the
  whole range of AArch64 ELF TLS relocations. Furthermore, they assume
  that some of the code sequences to access thread-local variables are
  produced in a very specific sequence.  When the sequence is not as the
  linker expects, it can silently mis-relaxe/mis-optimize the
  instructions.
  Even if that wouldn't be the case, it's good to produce the exact
  sequence, as that ensures that linkers can perform optimizing
  relaxations.

  This patch:

  * implements support for 16MiB TLS area size instead of 4GiB TLS area
    size. Ideally clang would grow an -mtls-size option to allow support
    for both, but that's not part of this patch.
  * by default doesn't produce local dynamic access patterns, as even
    modern ld.bfd and ld.gold linkers do not support the associated
    relocations. An option (-aarch64-elf-ldtls-generation) is added to
    enable generation of local dynamic code sequence, but is off by
    default.
  * makes sure that the exact expected code sequence for local dynamic
    and general dynamic accesses is produced, by making use of a new
    pseudo instruction. The patch also removes two
    (AArch64ISD::TLSDESC_BLR, AArch64ISD::TLSDESC_CALL) pre-existing
    AArch64-specific pseudo SDNode instructions that are superseded by
    the new one (TLSDESC_CALLSEQ).

Submitted by: Kristof Beyls
Differential Revision: https://reviews.freebsd.org/D2175

9 years agoPull in r233552 from upstream libc++ trunk (by Eric Fiselier):
dim [Mon, 30 Mar 2015 19:36:33 +0000 (19:36 +0000)]
Pull in r233552 from upstream libc++ trunk (by Eric Fiselier):

  [libcxx] Fix PR22771 - Support access control SFINAE in the library
  version of is_convertible.

  Summary:
  Currently the conversion check does not take place in a context where
  access control SFINAE is applied. This patch changes the context of
  the test expression so that SFINAE occurs if access control does not
  permit the conversion.

  Related bug: https://llvm.org/bugs/show_bug.cgi?id=22771

  Reviewers: mclow.lists, rsmith, dim

  Reviewed By: dim

  Subscribers: dim, rodrigc, emaste, cfe-commits

  Differential Revision: http://reviews.llvm.org/D8461

This fixes building clang, and other programs using libc++, with newer
versions of gcc (specifically, gcc 4.8 and higher).

Reported by: rodrigc
MFC after: 1 week

9 years agoAdd pthread_md.h for arm64.
andrew [Mon, 30 Mar 2015 19:10:09 +0000 (19:10 +0000)]
Add pthread_md.h for arm64.

Differential Revision: https://reviews.freebsd.org/D2137
Reviewed by: kib
Sponsored by: The FreeBSD Foundation

9 years agoSigh. s/AutoSize/Growfs/ following upstream commit r761.
gjb [Mon, 30 Mar 2015 19:08:37 +0000 (19:08 +0000)]
Sigh.  s/AutoSize/Growfs/ following upstream commit r761.

MFH: 3 days
Sponsored by: The FreeBSD Foundation

9 years agoSwitch to ELF toolchain readelf(1)
emaste [Mon, 30 Mar 2015 17:38:25 +0000 (17:38 +0000)]
Switch to ELF toolchain readelf(1)

ELF toolchain readelf lacked some functionality at the time other tools
(like size, strip, nm, etc.) were switched over to the ELF toolchain
versions. That has been addressed as of the last update, so we can add
it to the list.

PR: 198950 [exp-run]
Reviewed by: bapt, imp, rpaulo
Relnotes: yes
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D2156

9 years agoFill out arm64 dynamic relocation #defines
emaste [Mon, 30 Mar 2015 17:15:48 +0000 (17:15 +0000)]
Fill out arm64 dynamic relocation #defines

Sponsored by: The FreeBSD Foundation

9 years agoCorrect mrs_fpcr and mrs_fpsr macros in arm64 fenv.h
emaste [Mon, 30 Mar 2015 16:42:08 +0000 (16:42 +0000)]
Correct mrs_fpcr and mrs_fpsr macros in arm64 fenv.h

Submitted by: andrew
Sponsored by: The FreeBSD Foundation

9 years agocompiler-rt: Build additional quad precision floating point builtins
emaste [Mon, 30 Mar 2015 14:28:31 +0000 (14:28 +0000)]
compiler-rt: Build additional quad precision floating point builtins

These are needed for arm64

Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D2160

9 years ago- Remove more files when MK_INET6 == no
amdmi3 [Mon, 30 Mar 2015 14:13:01 +0000 (14:13 +0000)]
- Remove more files when MK_INET6 == no

MFC after: 1 week
Reviewed by: ngie
Approved by: ngie
Differential Revision: D1600

9 years ago- Remove more files when MK_FORTH == no
amdmi3 [Mon, 30 Mar 2015 14:00:17 +0000 (14:00 +0000)]
- Remove more files when MK_FORTH == no

MFC after: 1 week
Reviewed by: ngie
Approved by: ngie
Differential Revision: D1600

9 years agoPeriodically wake up threads waiting for vmem(9) resources, so they could
mav [Mon, 30 Mar 2015 13:30:53 +0000 (13:30 +0000)]
Periodically wake up threads waiting for vmem(9) resources, so they could
ask for resource reclamation again.

This is kind of dirty hack, but as last resort this is better then stuck
indefinitely because of KVA fragmentation, waiting until some random event
free something sufficient.  OpenSolaris also has this hack in its vmem(9).

MFC after: 2 weeks

9 years agoMFV ntp 4.2.8p1 (r258945, r275970, r276091, r276092, r276093, r278284)
cy [Mon, 30 Mar 2015 13:30:15 +0000 (13:30 +0000)]
MFV ntp 4.2.8p1 (r258945, r275970, r276091, r276092, r276093, r278284)

Thanks to roberto for providing pointers to wedge this into HEAD.

Approved by: roberto

9 years agoFix bug in xrefinfo_find() for 64-bit platforms
zbb [Mon, 30 Mar 2015 09:49:54 +0000 (09:49 +0000)]
Fix bug in xrefinfo_find() for 64-bit platforms

uintptr_t may be 64-bit on some platforms, therefore when
finding xrefinfo by pointer to device the high word is being
cut off due to cast to phandle_t which is 32-bit long by definition.
Due to that we loose the high word of the address to compare with
xi->dev's address.
To fix that, first argument of xrefinfo_find() is extended to
uintptr_t and is being cast to appropriate type (phandle_t)
when compared.

Submitted by:  Zbigniew Bodek <zbb@semihalf.com>
Reviewed by:   nwhitehorn
Obtained from: Semihalf

9 years agoRemove support for CPU_XSCALE_80200. None of our configs support it, and
andrew [Mon, 30 Mar 2015 09:29:45 +0000 (09:29 +0000)]
Remove support for CPU_XSCALE_80200. None of our configs support it, and
there wasn;t an option to enable it.

While here remove a check for CPU_ARM10 being defined as it has also been
removed.

9 years agoImprove check for whether ${DESTDIR}/dev is mounted.
cperciva [Mon, 30 Mar 2015 09:08:24 +0000 (09:08 +0000)]
Improve check for whether ${DESTDIR}/dev is mounted.

Submitted by: gcooper

9 years agoAdd some additional quirks for various Western Digital Caviar MHDDs
eadler [Mon, 30 Mar 2015 09:05:20 +0000 (09:05 +0000)]
Add some additional quirks for various Western Digital Caviar MHDDs

Submitted by: Jeremy Chadwick
PR: 188685
MFC After: 1 month

9 years agoAnd it turns out someone beat me to it....
eadler [Mon, 30 Mar 2015 08:54:59 +0000 (08:54 +0000)]
And it turns out someone beat me to it....

PR: 199013

9 years agoAdd support for "MosChip MCS9922 PCIe to Peripheral Controller" to uart
eadler [Mon, 30 Mar 2015 08:48:35 +0000 (08:48 +0000)]
Add support for "MosChip MCS9922 PCIe to Peripheral Controller" to uart

Submitted by: <mlsemon35@gmail.com>
PR: 199013
MFC After: 1 month

9 years agoRemove support for CPU_FA626TE. It's unused by any of our kernel configs.
andrew [Mon, 30 Mar 2015 08:38:18 +0000 (08:38 +0000)]
Remove support for CPU_FA626TE. It's unused by any of our kernel configs.

9 years agoOnly build cpufunc_asm_armv4.S when needed.
andrew [Mon, 30 Mar 2015 08:37:03 +0000 (08:37 +0000)]
Only build cpufunc_asm_armv4.S when needed.

9 years agoClean up filesystem unmounting in vmimage builds:
cperciva [Mon, 30 Mar 2015 08:33:19 +0000 (08:33 +0000)]
Clean up filesystem unmounting in vmimage builds:
* Remove vm_umount_base function which is currently unused.
* Add umount_loop function which loops attempting to unmount one filesystem.
* Replace calls to umount with calls to umount_loop.
* Don't attempt to unmount ${DESTDIR}/dev if it isn't mounted.

The looping is necessary because sometimes umount fails due to filesystems
being busy.  The most common cause of such busyness is periodic(8) jobs
running `find / ...`.

Reviewed by: gjb

9 years agoxen: add a handler for the debug interrupt
royger [Mon, 30 Mar 2015 07:09:07 +0000 (07:09 +0000)]
xen: add a handler for the debug interrupt

Handle the VIRQ_DEBUG signal and print a stack trace of each vCPU on the Xen
console. This is only used for debug purposes and is triggered by the
administrator of the Xen host.

Sponsored by: Citrix Systems R&D
MFC after: 1 week

9 years agoFix ping(8) and ping6(8) usage in a couple of ip provider tests, and
markj [Mon, 30 Mar 2015 04:06:36 +0000 (04:06 +0000)]
Fix ping(8) and ping6(8) usage in a couple of ip provider tests, and
update expected test output to reflect differences in default TTL and
payload length.

MFC after: 1 week

9 years agoFix ping(8) usage in funcs/tst.system.d so that the test actually completes.
markj [Mon, 30 Mar 2015 04:03:01 +0000 (04:03 +0000)]
Fix ping(8) usage in funcs/tst.system.d so that the test actually completes.

MFC after: 1 week

9 years agoReplace dtest.pl, the upstream DTrace test suite harness, with a shell
markj [Mon, 30 Mar 2015 04:01:49 +0000 (04:01 +0000)]
Replace dtest.pl, the upstream DTrace test suite harness, with a shell
script. This reimplementation is much simpler than dtest.pl and is more
amenable to being run under Kyua - dtest.pl writes error output to a
temporary directory that is deleted when the run finishes, making it hard
to debug test failures. This change also removes the test suite's dependency
on perl.

9 years agoImport a missing piece of commit b8fac8e162eda7e98d from illumos-gate.
markj [Mon, 30 Mar 2015 03:55:51 +0000 (03:55 +0000)]
Import a missing piece of commit b8fac8e162eda7e98d from illumos-gate.

This adds an upper bound, dtrace_ustackdepth_max, to the number of frames
traversed when computing the userland stack depth. Some programs - notably
firefox - are otherwise able to trigger an infinite loop in
dtrace_getustack_common(), causing a panic.

MFC after: 1 week

9 years agoarm11_sleep is no longer needed, remove it.
andrew [Sun, 29 Mar 2015 22:46:07 +0000 (22:46 +0000)]
arm11_sleep is no longer needed, remove it.

9 years agopj4b_config and pj4bv7_setup are only used when CPU_MV_PJ4B is defined.
andrew [Sun, 29 Mar 2015 22:45:33 +0000 (22:45 +0000)]
pj4b_config and pj4bv7_setup are only used when CPU_MV_PJ4B is defined.

9 years agoBuild the cpufunc_asm_* files based on the cpu type, not which config file
andrew [Sun, 29 Mar 2015 22:43:39 +0000 (22:43 +0000)]
Build the cpufunc_asm_* files based on the cpu type, not which config file
we happen to be building.

9 years agowordexp(): Add testcase for non-default IFS in environment.
jilles [Sun, 29 Mar 2015 22:00:24 +0000 (22:00 +0000)]
wordexp(): Add testcase for non-default IFS in environment.

The non-default IFS is expected to be used.

MFC after: 1 week

9 years agoAdd initial support for the HAL channel survey support to the AR9300 HAL.
adrian [Sun, 29 Mar 2015 21:53:08 +0000 (21:53 +0000)]
Add initial support for the HAL channel survey support to the AR9300 HAL.

This is used by the 'athsurvey' command to print out channel survey
statistics - % busy times transmit, receive and airtime.

It's as buggy and incomplete as the rest of the HAL survey support -
notably, tying into the ANI code to read channel stats and occasionally
getting garbage counters isn't very nice.  It also doesn't (yet!) get
channel survey information during a scan.  But it's good enough for
basic air-time debugging, which is why I'm committing it in this state.

Tested:

* AR9380, STA mode

9 years agoMove the HAL channel survey support out to be in the top-level HAL,
adrian [Sun, 29 Mar 2015 21:50:21 +0000 (21:50 +0000)]
Move the HAL channel survey support out to be in the top-level HAL,
rathe than private in each HAL module.

Whilst here, modify ath_hal_private to always have the per-channel
noisefloor stats, rather than conditionally.  This just makes
life easier in general (no strange ABI differences between different
HAL compile options.)

Add a couple of methods (clear/reset, add) rather than using
hand-rolled versions of things.

9 years agoAdd a new field to HAL_ANISTATS - the extension channel busy count.
adrian [Sun, 29 Mar 2015 21:45:48 +0000 (21:45 +0000)]
Add a new field to HAL_ANISTATS - the extension channel busy count.

This is only used by the AR9300 HAL for now - but just be careful if
you decide to recompile the kernel with NO_CLEAN=1.