]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/log
FreeBSD/stable/10.git
10 years agoMFC r258826, r259555, r 259558:
pfg [Wed, 25 Dec 2013 21:59:56 +0000 (21:59 +0000)]
MFC r258826, r259555, r 259558:

libcpp: Merge fixes from upstream
Fixes:
GCC preprocessor/29966:
GCC preprocessor/28709:
GCC c/31924
GCC preprocessor/14331

gcc: add Apple-compatible -Wnewline-eof

Obtained from: gcc per-4.3 (rev. 121340, 124356, 124358, 124730,
  125212, 125255 ; GPLv2)
Apple Inc. (Apple GCC 4.2 - 5531)

git-svn-id: svn://svn.freebsd.org/base/stable/10@259890 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258469:
pluknet [Wed, 25 Dec 2013 15:40:15 +0000 (15:40 +0000)]
MFC r258469:

- Purge one more reference to ad(4)[1].
- NSWAPDEV limit has gone.

Noticed by: Sergey V. Dyatko [1]

git-svn-id: svn://svn.freebsd.org/base/stable/10@259871 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259222:
mav [Wed, 25 Dec 2013 12:41:53 +0000 (12:41 +0000)]
MFC r259222:
Destroy mtx lock when failed to allocate memory during attach.

Submitted by: Dmitry Luhtionov <dmitryluhtionov@gmail.com>

git-svn-id: svn://svn.freebsd.org/base/stable/10@259866 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259729:
gjb [Wed, 25 Dec 2013 06:09:07 +0000 (06:09 +0000)]
MFC r259729:
  Bootstrap etcupdate(8) as part of the release build, similar
  to what is done for mergemaster(8).  This allows etcupdate(8)
  to work out-of-box after the first upgrade of a system.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@259861 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259740:
dim [Wed, 25 Dec 2013 00:53:48 +0000 (00:53 +0000)]
MFC r259740:

In usr.bin/sort/radixsort.c, pop_ls_mt() is only referenced if
SORT_THREADS is defined, so make the whole function conditional, instead
of just the pthread calls in it.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259853 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259724:
dim [Wed, 25 Dec 2013 00:48:08 +0000 (00:48 +0000)]
MFC r259724:

Apply upstream commit 33312fd828e59c78ae4ee30fd70d0ca109748cf0 (by
zoulasc) to contrib/file:

  don't write a char to a pointer.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259852 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259720:
dim [Wed, 25 Dec 2013 00:40:42 +0000 (00:40 +0000)]
MFC r259720:

For gnu/lib/csu, only use gcc-specific flags when compiling with gcc.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259851 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259520:
ae [Tue, 24 Dec 2013 23:23:44 +0000 (23:23 +0000)]
MFC r259520:
  Fix copy/paste typo.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259847 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC 259013:
jhb [Tue, 24 Dec 2013 19:10:56 +0000 (19:10 +0000)]
MFC 259013:
Fix the processor table entry structure to use a fixed-width type for
32-bit fields so it is the correct size on amd64.  Remove a workaround
for the broken structure from bhyve(8).

git-svn-id: svn://svn.freebsd.org/base/stable/10@259837 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC 258869:
jhb [Tue, 24 Dec 2013 19:01:08 +0000 (19:01 +0000)]
MFC 258869:
Fix an off-by-one error in r228960.  The maximum priority delta provided
by SCHED_PRI_TICKS should be SCHED_PRI_RANGE - 1 so that the resulting
priority value (before nice adjustment) is between SCHED_PRI_MIN and
SCHED_PRI_MAX, inclusive.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259834 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC 258177:
jhb [Tue, 24 Dec 2013 18:48:29 +0000 (18:48 +0000)]
MFC 258177:
Remove an incorrectly copied and pasted clause from these license
statements.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259831 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259473:
dim [Tue, 24 Dec 2013 14:26:31 +0000 (14:26 +0000)]
MFC r259473:

Enable llvm's integrated assembler for PowerPC, since it should now be
good enough for typical usage.

Requested by: rdivacky

git-svn-id: svn://svn.freebsd.org/base/stable/10@259822 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259677: swapon: Fix buffer overflow when configuring swap on GBDE.
jilles [Tue, 24 Dec 2013 13:46:54 +0000 (13:46 +0000)]
MFC r259677: swapon: Fix buffer overflow when configuring swap on GBDE.

PR: bin/184950

git-svn-id: svn://svn.freebsd.org/base/stable/10@259820 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259522:
kib [Tue, 24 Dec 2013 07:32:06 +0000 (07:32 +0000)]
MFC r259522:
If vn_open_vnode() succeeded in opening the vnode, but subsequent
advisory lock cannot be obtained, prevent double-close of the vnode in
vn_close() called from the fdrop(), by resetting file' f_ops methods.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259817 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259521:
kib [Tue, 24 Dec 2013 07:25:49 +0000 (07:25 +0000)]
MFC r259521:
Do not allow O_EXEC opens for fifo, return EINVAL.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259814 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259808
rodrigc [Tue, 24 Dec 2013 05:17:24 +0000 (05:17 +0000)]
MFC r259808

  Add pointer to wiki for Hyper-V information.

  Wiki content for Hyper-V in FreeBSD 10 was significantly updated by
  Abhishek Gupta <abgupta@microsoft.com>.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259809 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259527:
np [Tue, 24 Dec 2013 02:10:12 +0000 (02:10 +0000)]
MFC r259527:

Do not create a hardware IPv6 server if the listen address is not
in6addr_any and is not in the CLIP table either.  This fixes a reported
TOE+IPv6 NULL-dereference panic in do_pass_open_rpl().

While here, stop creating hardware servers for any loopback address.
It's just a waste of server tids.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259804 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoSwitch references to -CURRENT to -STABLE.
gjb [Mon, 23 Dec 2013 21:07:02 +0000 (21:07 +0000)]
Switch references to -CURRENT to -STABLE.
This is a direct commit to stable/10/.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@259789 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoUpdate FreeBSD version entity values.
gjb [Mon, 23 Dec 2013 20:52:29 +0000 (20:52 +0000)]
Update FreeBSD version entity values.
This is a direct commit to stable/10/, because the values differ
between stable/10/ and head/.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@259788 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259058,r259060:
delphij [Mon, 23 Dec 2013 20:20:46 +0000 (20:20 +0000)]
MFC r259058,r259060:

Remove -q from usage.

Document -q and --quiet as discouraged compatibility option.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259785 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259131:
delphij [Mon, 23 Dec 2013 20:16:54 +0000 (20:16 +0000)]
MFC r259131:

Don't panic when we get ZPOOL_STATUS_NON_NATIVE_ASHIFT
while listing importable pools.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259784 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259781:
rodrigc [Mon, 23 Dec 2013 19:51:30 +0000 (19:51 +0000)]
MFC r259781:
  Mention jemalloc upgrade to 3.4.0

git-svn-id: svn://svn.freebsd.org/base/stable/10@259783 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC:
rodrigc [Mon, 23 Dec 2013 11:48:22 +0000 (11:48 +0000)]
MFC:
  Merge release note updates.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259768 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259685:
imp [Mon, 23 Dec 2013 01:24:32 +0000 (01:24 +0000)]
MFC r259685:

 Plumb the cn_grab and cn_ungrab routines down into the uart
 clients. Mask RX interrupts while grabbed on the atmel serial
 driver. This UART interrupts every character. When interrupts are
 enabled at the mountroot> prompt, this means the ISR eats the
 characters. Rather than try to create a cooperative buffering system
 for the low level kernel console, instead just mask out the ISR. For
 NS8250 and decsendents this isn't needed, since interrupts only happen
 after 14 or more characters (depending on the fifo settings). Plumb
 such that these are optional so there's no change in behavior for all
 the other UART clients. ddb worked on this platform because all
 interrupts were disabled while it was running, so this problem wasn't
 noticed. The mountroot> issue has been around for a very very long
 time.

Approved by: re@ (gjb@)

git-svn-id: svn://svn.freebsd.org/base/stable/10@259759 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r256650: kldxref: Add static keyword to the new function only used in the
jilles [Sun, 22 Dec 2013 23:08:33 +0000 (23:08 +0000)]
MFC r256650: kldxref: Add static keyword to the new function only used in the
same file.

The WARNS level is not such that the omission broke the build.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259751 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259717:
dumbbell [Sun, 22 Dec 2013 21:53:08 +0000 (21:53 +0000)]
MFC r259717:

drm: Lower priority of "EDID checksum is invalid" message

The priority goes from "error" to "debug".

Connectors are polled every 10 seconds. Reading EDID is part of this
polling. However, when an invalid EDID is returned, this error message
is logged. When using Newcons for instance, having a kernel message
every 10 seconds is getting annoying.

Now that it's a debug message, it'll be logged only if hw.dri.debug is
enabled. This fix console spamming for some users.

Tested by: Larry Rosenman <ler@lerctr.org>

git-svn-id: svn://svn.freebsd.org/base/stable/10@259745 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259684:
dumbbell [Sun, 22 Dec 2013 21:18:21 +0000 (21:18 +0000)]
MFC r259684:

drm/ttm, drm/radeon: Replace EINTR/ERESTART by ERESTARTSYS...

... for msleep/cv_*wait() return values, where wait_event*() is used
on Linux. ERESTARTSYS is the return code expected by callers when the
operation was interrupted.

For instance, this is the case of radeon_cs_ioctl() (radeon_cs.c): if
an error occurs, and the code isn't ERESTARTSYS (eg. EINTR), it logs an
error.

Note that ERESTARTSYS is defined as ERESTART, but this keeps callers'
code close to Linux.

Submitted by: avg@ (previous version)

git-svn-id: svn://svn.freebsd.org/base/stable/10@259742 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259679:
dumbbell [Sun, 22 Dec 2013 21:09:43 +0000 (21:09 +0000)]
MFC r259679:

vga_pci: Improve boot display detection

The previous code was checking the "VGA Enable" bit on the video card's
parent PCI-to-PCI bridge only. This didn't work for the case where the
video card is attached to the root PCI bus (ie. the card has no parent
PCI-to-PCI bridge).

Now, the new code:
    1. checks the "VGA Enable" bit on the parent bridge only if it's a
       PCI-to-PCI bridge;
    2. always checks the "I/O" and "Memory address space decoding" bits
       on the video card itself.

However, vendor-specific bits are not used.

This fixes the use of many integrated Radeon cards: without this patch,
we fail to detect them as the boot display and, when radeonkms looks for
the Video BIOS, it skips the shadow copy made by the System BIOS. It
then fails to fully initialize the card, because the shadow copy is the
only way to read the Video BIOS in these situations. A workaround was to
force the boot display selection using the "hw.pci.default_vgapci_unit"
tunable.

A previous version of this patch added a new function doing the checks.
Now, the vga_pci_is_boot_display() function is used to perform the
checks (only until the boot display is found) and return if the given
device is the boot display or not.

Furthermore, vga_pci_attach() logs "Boot video device" if the card being
attached it the Chosen One:
    vgapci0: <VGA-compatible display> [...]
    vgapci0: Boot video device

Reviewed by: kib@, jhb@ (both a previous version)
Tested by: lunatic_ (#freebsd-xorg, integrated Radeon card,
xmj (#freebsd-xorg, i915+NVIDIA cards)

git-svn-id: svn://svn.freebsd.org/base/stable/10@259741 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259576:
pjd [Sun, 22 Dec 2013 19:36:08 +0000 (19:36 +0000)]
MFC r259576:

MFV r258923: 4188 assertion failed in dmu_tx_hold_free(): dn_datablkshift != 0

illumos/illumos-gate@bb411a08b05466bfe0c7095b6373bbc1587e259a

git-svn-id: svn://svn.freebsd.org/base/stable/10@259734 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259108:
mav [Sun, 22 Dec 2013 13:02:34 +0000 (13:02 +0000)]
MFC r259108:
When comparing device IDs, make sure that they have the same type
(like NAA assigned) and identify the same entity (like device or port).
Otherwise there can be false positives since at least some models of
Seagate disks use same IDs for the whole device and one of its ports.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259721 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258017, r258429, r258748, r258817:
pfg [Sat, 21 Dec 2013 18:47:00 +0000 (18:47 +0000)]
MFC r258017, r258429, r258748, r258817:

Merge updates from FSF pre4.3 GCC inspired on Apple's gcc:

  Updates to libiberty and mangling.
  New align attribute.
  Merge Apple updates to libstdc++.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259694 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259498:
dim [Fri, 20 Dec 2013 20:14:54 +0000 (20:14 +0000)]
MFC r259498:

Pull in r197399 from upstream clang trunk:

  Add bit_FXSAVE as an alias for bit_FXSR, for gcc compat.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259664 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC of 259626, tzdata2013i
edwin [Thu, 19 Dec 2013 23:29:34 +0000 (23:29 +0000)]
MFC of 259626, tzdata2013i

Removed support for solar-time-based time zones
Jordan stays at summer time this year.
Fix historical data for Cuba

git-svn-id: svn://svn.freebsd.org/base/stable/10@259636 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMF9: Don't fail to build if MALLOC_PRODUCTION is defined in make.conf
peter [Thu, 19 Dec 2013 21:03:08 +0000 (21:03 +0000)]
MF9: Don't fail to build if MALLOC_PRODUCTION is defined in make.conf

git-svn-id: svn://svn.freebsd.org/base/stable/10@259631 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259569:
np [Thu, 19 Dec 2013 19:15:24 +0000 (19:15 +0000)]
MFC r259569:
cxgbe.4: Belated update to the man page to reflect T5 support.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259622 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259276,259468-259470,259472,259474,259476-259478,259480-259481,259570,
dteske [Thu, 19 Dec 2013 18:52:41 +0000 (18:52 +0000)]
MFC r259276,259468-259470,259472,259474,259476-259478,259480-259481,259570,
259572, and 259597-259598...

r259276: Fix bug in `services' script in adding dumpdev comment to rc.conf
r259468: Ignore spurious escape generated by VMware's Ctrl-Cmd combination
r259469: Mask errors in `config' script from newaliases(1) about non-FQHN
r259470: Set atime=on for /var/mail zfsboot dataset to support mail server
r259472: Accept NULL input for zfsboot SWAP to indicate SWAP of zero bytes
r259474: Multiple changes, including bug-fixes and debugging improvements
r259476: Change default ZFS disk layout, making it easier to resize
r259477: fletcher4 is now the default (zfsboot related)
r259478: De-uglify the geli(8)-setup infobox (zfsboot related)
r259480: Fix ghosted zroot issue by always performing labelclear on swap
r259481: Auto-enable 4k sector alignmet when geli(8) is enabled (zfsboot)
r259570: Fix numerical comparison error (zfsboot)
r259572: Mask spurious rm error in bsdinstall_log from `auto' script
r259597: Fix zfsboot regression when installing to 3+ disks
r259598: Set cachefile property of bootpool so it imports to new system

git-svn-id: svn://svn.freebsd.org/base/stable/10@259621 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259266:
bdrewery [Thu, 19 Dec 2013 12:33:24 +0000 (12:33 +0000)]
MFC r259266:

  Fix multi-repository support by properly respecting 'enabled' flag.

  This will read the REPOS_DIR env/config setting (default is /etc/pkg
  and /usr/local/etc/pkg/repos) and use the last enabled repository.

  This can be changed in the environment using a comma-separated list,
  or in /usr/local/etc/pkg.conf with JSON array syntax of:
      REPOS_DIR: ["/etc/pkg", "/usr/local/etc/pkg/repos"]

Approved by: bapt (mentor)

git-svn-id: svn://svn.freebsd.org/base/stable/10@259613 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoDefer start/stop port to workqueues.
alfred [Thu, 19 Dec 2013 07:33:07 +0000 (07:33 +0000)]
Defer start/stop port to workqueues.

MFC: 259411

git-svn-id: svn://svn.freebsd.org/base/stable/10@259608 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259248 and r259462:
hselasky [Thu, 19 Dec 2013 07:20:37 +0000 (07:20 +0000)]
MFC r259248 and r259462:
Set chain bit correctly. This will fix some problems sending and
receiving Zero Length Packets, ZLPs. See comment in code for more
information.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259607 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259023 and r259095:
hselasky [Thu, 19 Dec 2013 07:13:59 +0000 (07:13 +0000)]
MFC r259023 and r259095:
Improve the XHCI command timeout recovery handling code.
Fix some typos while at it.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259603 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258629, 258662:
truckman [Thu, 19 Dec 2013 07:12:34 +0000 (07:12 +0000)]
MFC r258629, 258662:

r258629:
  Mention that devd will kldload the driver when the device is connected.

  Mention that the automatic mode switch from umass to u3g needed by some
  devices does not work unless the driver is loaded before the device is
  connected.

r258662 (by joel):
  mdoc: sort sections.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259601 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoRegenerate after
truckman [Thu, 19 Dec 2013 06:39:48 +0000 (06:39 +0000)]
Regenerate after
r255238, r257044, r259453 (if_run)
r255128 (ng_ubt)
r259592 (u3g)

git-svn-id: svn://svn.freebsd.org/base/stable/10@259596 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258363:
truckman [Thu, 19 Dec 2013 05:36:06 +0000 (05:36 +0000)]
MFC r258363:

Add alternate ID for Novatel MiFi 2200 CDMA, which is used by my
Virgin Mobile branded device.  It needs the U3GINIT_SCSIEJECT quirk.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259592 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258731:
pfg [Thu, 19 Dec 2013 02:39:11 +0000 (02:39 +0000)]
MFC r258731:

gcc: Make use of TREE_OVERFLOW_P.

While it was brought in r258179 only to fix a build issue,
bringing the rest of the change has the advantage of fixing
GCC/19978.

Obtained from: gcc 4.3 (rev. 120505; GPLv2)

git-svn-id: svn://svn.freebsd.org/base/stable/10@259584 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258651, r258943:
pfg [Thu, 19 Dec 2013 02:32:07 +0000 (02:32 +0000)]
MFC r258651, r258943:
gcc: Altivec register adjustments from Apple.
gcc: On rs6000 update sp_offset depending only on size.

Tested by: Justin Hibbits
Obtained from: gcc pre-4.3 (rev. 124763, 125116; GPLv2)

git-svn-id: svn://svn.freebsd.org/base/stable/10@259583 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259571:
rodrigc [Wed, 18 Dec 2013 21:49:17 +0000 (21:49 +0000)]
MFC r259571:

  Add SVN revision numbers for Mellanox updates.

MFC r259573:

  Add SVN revision numbers for Chelsio updates.

MFC r259574:

  Indent.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259577 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258428, r258445
pfg [Wed, 18 Dec 2013 19:07:29 +0000 (19:07 +0000)]
MFC r258428, r258445

gcc: another round of merges from the gcc pre-43 branch.

Bring The following revisions from the gcc43 branch[1]:

118360, 118361, 118363, 118576, 119820,
123906, 125246, and 125721.

They all have in common that the were merged long ago
into Apple's gcc and should help improve the general
quality of the compiler and make it easier to bring
new features from Apple's gcc42.

For details please review the additions to the files:
gcc/ChangeLog.gcc43
gcc/cp/ChangeLog.gcc43 (new, adds previous revisions)

Fix crosscompilation (r258445 by andreast)
Reference:
[1] http://gcc.gnu.org/viewcvs/gcc/trunk/?pathrev=126700

Obtained from: gcc pre4.3 (GPLv2) branch
MFC after: 3 weeks

git-svn-id: svn://svn.freebsd.org/base/stable/10@259563 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMerge r256868,257276-257277,257515,257913 from head. These are fixes
glebius [Wed, 18 Dec 2013 05:20:53 +0000 (05:20 +0000)]
Merge r256868,257276-257277,257515,257913 from head. These are fixes
required to make Xen buÑ‚ldable w/o INET.

Sponsored by: Nginx, Inc.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259541 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259302,r259413
grehan [Wed, 18 Dec 2013 03:51:04 +0000 (03:51 +0000)]
MFC r259302,r259413

r259302
  bhyve(8) man page

r259413
  mdoc: sort SEE ALSO

git-svn-id: svn://svn.freebsd.org/base/stable/10@259536 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259426, r259427:
gjb [Wed, 18 Dec 2013 01:14:25 +0000 (01:14 +0000)]
MFC r259426, r259427:
r259426:
  Add a pkg(8) repository configuration file for cdrom-based package
  installation.

  As part of the 'pkg-stage' target, copy the configuration file
  to the 'packages/repos/' directory on the DVD filesystem.

r259427:
  Export 'REPOS_DIR' when the selected source medium for package
  installation is cdrom.  This enables bsdconfig(8) to make use
  of the on-disc pkg(8) repository configuration, which fixes
  package selection and installation from the dvd installer.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@259533 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC DMAR busdma implementation.
kib [Tue, 17 Dec 2013 13:49:35 +0000 (13:49 +0000)]
MFC DMAR busdma implementation.

MFC r257251:
Import the driver for VT-d DMAR hardware.  Implement the busdma(9) using DMARs.

MFC r257512:
Add support for queued invalidation.

MFC miscellaneous follow-ups to r257251.

MFC r257266:
Remove redundand assignment to error variable and check for its value.

MFC r257308:
Remove redundand declaration.

MFC r257511:
Return BUS_PROBE_NOWILDCARD from the DMAR probe method.

MFC r257860,r257896,r257900,r257902,r257903 (by dim):
Fixes for gcc compilation.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259512 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257230:
kib [Tue, 17 Dec 2013 13:39:50 +0000 (13:39 +0000)]
MFC r257230:
Add a virtual table for the busdma methods on x86, to allow different
busdma implementations to coexist.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259511 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257228:
kib [Tue, 17 Dec 2013 13:38:21 +0000 (13:38 +0000)]
MFC r257228:
Add bus_dmamap_load_ma() function to load map with the array of
vm_pages.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259510 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257541:
kib [Tue, 17 Dec 2013 13:18:41 +0000 (13:18 +0000)]
MFC r257541:
Fix several issues with the busdma(9) KPI use in the e1000 drivers.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259508 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258088:
kib [Tue, 17 Dec 2013 13:10:28 +0000 (13:10 +0000)]
MFC r258088:
Add check for buflen overflow by comparing the buflen with both offset
and resid.

MFC r258397:
Redo r258088 to avoid relying on signed arithmetic overflow.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259506 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258039:
kib [Tue, 17 Dec 2013 09:21:56 +0000 (09:21 +0000)]
MFC r258039:
Avoid overflow for the page counts.

MFC r258365:
Revert back to use int for the page counts.
Rearrange the checks to correctly handle overflowing address arithmetic.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259499 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259493:
rodrigc [Tue, 17 Dec 2013 04:26:20 +0000 (04:26 +0000)]
MFC r259493:

  Add OFED and Mellanox items to release notes.

  Submitted by: Meny Yossefi <menyy mellanox com>

MFC r259490:

  Add release note items from Chelsio.

  Submitted by: np

git-svn-id: svn://svn.freebsd.org/base/stable/10@259494 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258770 (hrs):
gjb [Tue, 17 Dec 2013 04:16:20 +0000 (04:16 +0000)]
MFC r258770 (hrs):
  Add NOPKG to disable pkg-stage.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@259492 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259246:
gjb [Tue, 17 Dec 2013 03:46:44 +0000 (03:46 +0000)]
MFC r259246:
  Prevent release build errors found during snapshot builds where if
  NOPORTS=1, pkg-stage.sh cannot build the ports-mgmt/pkg port if
  WITH_DVD=1.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@259491 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoRecord mergeinfo for r258927.
gjb [Tue, 17 Dec 2013 01:02:34 +0000 (01:02 +0000)]
Record mergeinfo for r258927.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@259488 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258311
asomers [Mon, 16 Dec 2013 19:59:34 +0000 (19:59 +0000)]
MFC r258311

opensolaris/uts/common/dtrace/fasttrap.c
        Fix several problems that can cause panics on kldload and kldunload.

        * kproc_create(fasttrap_pid_cleanup_cb, ...) gets called before
          fasttrap_provs.fth_table gets allocated.  This can lead to a panic
          on module load, because fasttrap_pid_cleanup_cb references
          fasttrap_provs.fth_table.  Move kproc_create down after the point
          that fasttrap_provs.fth_table gets allocated, and modify the error
          handling accordingly.

        * dtrace_fasttrap_{fork,exec,exit} weren't getting NULLed until
          after fasttrap_provs.fth_table got freed.  That caused panics on
          module unload because fasttrap_exec_exit calls
          fasttrap_provider_retire, which references
          fasttrap_provs.fth_table.  NULL those function pointers earlier.

        * There wasn't any code to destroy the
          fasttrap_{tpoints,provs,procs}.fth_table mutexes on module unload,
          leading to a resource leak when WITNESS is enabled.  Destroy those
          mutexes during fasttrap_unload().

Sponsored by: Spectra Logic Corporation

git-svn-id: svn://svn.freebsd.org/base/stable/10@259483 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258819,258928:
nwhitehorn [Mon, 16 Dec 2013 15:00:06 +0000 (15:00 +0000)]
MFC r258819,258928:

Add new sysctl, kern.supported_archs, containing the list of FreeBSD
MACHINE_ARCH values whose binaries this kernel can run. This patch provides
a feature requested for implementing pkgng ABI identifiers in a robust
way.

The list is designed to indicate whether, say, an i386 package can be run on
the current system. If kern.supported_abis contains "i386", then the answer
is yes. Otherwise, the answer is no.

At the moment, this only supports MACHINE_ARCH and MACHINE_ARCH32. As we
gain support for more interesting combinations, this needs to become more
flexible, possibily through the sysent framework, along with the
hw.machine_arch emulation immediately preceding this code in kern_mib.c.

Reviewed by: imp

git-svn-id: svn://svn.freebsd.org/base/stable/10@259465 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r256718, r257410 and r257411:
hselasky [Mon, 16 Dec 2013 09:48:08 +0000 (09:48 +0000)]
MFC r256718, r257410 and r257411:
- Fix RF registers for RT3070.
- Initialize BBP68 to improve RX sensitivity.
- Add RT2860_BCN_OFFSET1 and RT2860_MAX_LEN_CFG register initialization to
match with the vendor driver. While here, remove unused RT2860_DEF_MAC
definition.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259461 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r238274, r246752, r256720, r256721, r256722, r256955, r257409
hselasky [Mon, 16 Dec 2013 08:10:38 +0000 (08:10 +0000)]
MFC r238274, r246752, r256720, r256721, r256722, r256955, r257409
 r257429, r257435, r257712, r257732, r257743, r257748, r257955
 r257957, r257958, r258082, r258641, r258643, r258732, r258733,
 r258840, r258919, r258921, r259029, r259030, r259031, r259032 and r259046:

- Add support for the MediaTek/Ralink RT5370/RT5372 chipset.
- Various minor USB WLAN fixes and improvements.

PR:     usb/182936

git-svn-id: svn://svn.freebsd.org/base/stable/10@259453 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258950:
delphij [Mon, 16 Dec 2013 06:41:31 +0000 (06:41 +0000)]
MFC r258950:

Enable Hyper-V support in i386 GENERIC.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259450 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259286,259424,259425:
bjk [Mon, 16 Dec 2013 02:04:28 +0000 (02:04 +0000)]
MFC r259286,259424,259425:
  Apply patch from upstream Heimdal for encoding fix

  RFC 4402 specifies the implementation of the gss_pseudo_random()
  function for the krb5 mechanism (and the C bindings therein).
  The implementation uses a PRF+ function that concatenates the output
  of individual krb5 pseudo-random operations produced with a counter
  and seed.  The original implementation of this function in Heimdal
  incorrectly encoded the counter as a little-endian integer, but the
  RFC specifies the counter encoding as big-endian.  The implementation
  initializes the counter to zero, so the first block of output (16 octets,
  for the modern AES enctypes 17 and 18) is unchanged.  (RFC 4402 specifies
  that the counter should begin at 1, but both existing implementations
  begin with zero and it looks like the standard will be re-issued, with
  test vectors, to begin at zero.)

  This is upstream's commit f85652af868e64811f2b32b815d4198e7f9017f6,
  from 13 October, 2013:
  % Fix krb5's gss_pseudo_random() (n is big-endian)
  %
  % The first enctype RFC3961 prf output length's bytes are correct because
  % the little- and big-endian representations of unsigned zero are the
  % same.  The second block of output was wrong because the counter was not
  % being encoded as big-endian.
  %
  % This change could break applications.  But those applications would not
  % have been interoperating with other implementations anyways (in
  % particular: MIT's).

Bump __FreeBSD_version accordingly and add a note in UPDATING.

Approved by: hrs (mentor, src committer)

git-svn-id: svn://svn.freebsd.org/base/stable/10@259447 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoRecord r258428 and r258445 as not merged.
peter [Mon, 16 Dec 2013 01:47:52 +0000 (01:47 +0000)]
Record r258428 and r258445 as not merged.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259445 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259132,r259133,r259143:
eadler [Mon, 16 Dec 2013 01:20:18 +0000 (01:20 +0000)]
MFC r259132,r259133,r259143:
Per the resolution of POSIX bug 0000779 (note 0002050) add support for using 'i'
as a case insensitive flag.

Add regression test for recently added 'i' flag in r259132.

the i modifier was added in r259132 since POSIX recently agreed to add
it. Switch uses of /I to /i.

PR: standards/184641

git-svn-id: svn://svn.freebsd.org/base/stable/10@259443 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258530;
pfg [Sun, 15 Dec 2013 04:27:49 +0000 (04:27 +0000)]
MFC r258530;

libcpp: Keep a record of changes from upstream GCC (pre-43).

git-svn-id: svn://svn.freebsd.org/base/stable/10@259408 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC rr258501, r258507;
pfg [Sun, 15 Dec 2013 03:47:31 +0000 (03:47 +0000)]
MFC rr258501, r258507;
gcc: Bring updates from Google's enhanced gcc-4.2.1.

Google released and enhanced version of gcc-4.2.1 plus their local
patches for Android[1].

The patches are owned by Google and the license hasn't been changed
from  the original GPLv2. We are only bringing a subset of the
available patches that may be helpful in FreeBSD, in other words,
changes specific to android are not included.

From the README.google file[1].

Patches applied to google_vendor_src_branch/gcc/gcc-4.2.1:

gcc/Makefile.in
gcc/c-common.c
gcc/c-common.h
gcc/c-opts.c
gcc/c-typeck.c
gcc/cp/typeck.c
gcc/doc/invoke.texi
gcc/flags.h
gcc/opts.c
gcc/tree-flow.h
gcc/tree-ssa-alias-warnings.c
gcc/tree-ssa-alias.c

 Backport of -Wstrict-aliasing from mainline.
  Silvius Rus <rus@google.com>

gcc/coverage.c:
  Patch coverage_checksum_string for PR 25351.
  Seongbae Park <spark@google.com>
  Not yet submitted to FSF.

gcc/c-opts.c
gcc/c-ppoutput.c
gcc/c.opt
gcc/doc/cppopts.texi
libcpp/Makefile.in
libcpp/directives-only.c
libcpp/directives.c
libcpp/files.c
libcpp/include/cpplib.h
libcpp/init.c
libcpp/internal.h
libcpp/macro.c
  Support for -fdirectives-only.
  Ollie Wild <aaw@google.com>.
  Submitted to FSF but not yet approved.

libstdc++-v3/include/ext/hashtable.h
  http://b/742065
  http://b/629994
  Reduce min size of hashtable for hash_map, hash_set from 53 to 5

libstdc++-v3/include/ext/hashtable.h
  http://b/629994
  Do not iterate over buckets if hashtable is empty.

gcc/common.opt
gcc/doc/invoke.texi
gcc/flags.h
gcc/gimplify.c
gcc/opts.c
  Add Saito's patch for -finstrument-functions-exclude-* options.

gcc/common.opt
gcc/doc/invoke.texi
gcc/final.c
gcc/flags.h
gcc/opts.c
gcc/testsuite/gcc.dg/Wframe-larger-than.c
  Add a new flag -Wframe-larger-than- which enables a new warning
  when a frame size of a function is larger than specified.
  This patch hasn't been integrated into gcc mainline yet.

gcc/tree-vrp.c
  Add a hack to avoid using ivopts information for pointers starting
  at constant values.

Reference:

[1]
https://android.googlesource.com/toolchain/gcc/+/master/gcc-4.2.1/

Obtained from: Google Inc.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259405 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259400:
gjb [Sat, 14 Dec 2013 22:43:30 +0000 (22:43 +0000)]
MFC r259400:
  Reduce disc1.iso size by 74MB by removing lib32 libraries, sendmail,
  and atf.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@259401 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r256430:
gjb [Sat, 14 Dec 2013 22:39:01 +0000 (22:39 +0000)]
MFC r256430:
  Reduce disc1.iso image size by installing the userland with
  the WITHOUT_PROFILE=1 option set, trimming 56MB from the image.

This change was somehow lost during the 10.0-RELEASE cycle, and
is intended for MFC to releng/10.0.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@259399 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259113, r259115, r259144, r259148:
gjb [Sat, 14 Dec 2013 20:55:53 +0000 (20:55 +0000)]
MFC r259113, r259115, r259144, r259148:

r259113 (dteske):
  Fix failed attempt to send pkg(8) stderr to /dev/null

r259115 (dteske):
  Prevent truncating /tmp/bsdinstall_log each time we
  exec a module.

r259144 (dteske):
  Fix a regression after successfully installing to encrypted
  ZFS root, the passphrase is not accepted and a message about
  "incorrect key" is displayed.

r259148 (dteske):
  Fix a regression resulting in mountroot prompt after attempting
  to install to encrypted ZFS root (caused by a typo in a
  variable name -- ZFSBOOT_BOOT_FSNAME -> ZFSBOOT_BOOTFS_NAME).

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@259396 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257987:
ae [Sat, 14 Dec 2013 04:24:32 +0000 (04:24 +0000)]
MFC r257987:
  Initialize prot variable.

  PR: 177417

git-svn-id: svn://svn.freebsd.org/base/stable/10@259385 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257965:
ae [Sat, 14 Dec 2013 04:16:27 +0000 (04:16 +0000)]
MFC r257965:
  Add missing line breaks.

  PR: 181900

git-svn-id: svn://svn.freebsd.org/base/stable/10@259383 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259212, r259220:
ian [Sat, 14 Dec 2013 01:35:57 +0000 (01:35 +0000)]
MFC r259212, r259220:

  Fix one race and one fence post error. When the TX buffer was
  completely full, we'd not complete any of the mbufs due to the fence
  post error (this creates a large leak). When this is fixed, we still
  leak, but at a much smaller rate due to a race between ateintr and
  atestart_locked as well as an asymmetry where atestart_locked is
  called from elsewhere.  Ensure that we free in-flight packets that
  have completed there as well. Also remove needless check for NULL on
  mb, checked earlier in the loop and simplify a redundant if.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259381 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r259038, r259039:
ian [Sat, 14 Dec 2013 01:34:24 +0000 (01:34 +0000)]
MFC r259038, r259039:

  Bump the maximum VM space from 3 * memory size to a fixed
  256MB. That's all we have room for since we map the hardware registers
  starting at 0xd0000000. This allows my 64MB AT91SAM9G20 to boot again
  after the unmmaped I/O changes were MFC'd at r251897. Other
  subplatforms may need similar treatment.

  Although not strictly required to boot a 64MB board, bump
  vm_max_virtual_address to be KERNVIRTADDR + 256MB. This allows some
  future shock protection since the KVA requirements have gone up since
  the unmapped changes have gone in, as well as preventing us from
  overlapping with the hardware devices, which we map at 0xd0000000,
  which we'd hit with anything more than 85MB...

git-svn-id: svn://svn.freebsd.org/base/stable/10@259380 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258828:
ian [Sat, 14 Dec 2013 01:15:26 +0000 (01:15 +0000)]
MFC r258828:

  Add a nand flash controller driver for Atmel at91 family.  Tested only
  on at91rm9200 so far.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259379 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258820: Add definitions for the PIO pins found on recent AT91 SoCs.
ian [Sat, 14 Dec 2013 01:14:38 +0000 (01:14 +0000)]
MFC r258820:  Add definitions for the PIO pins found on recent AT91 SoCs.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259378 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258392, r258412:
ian [Sat, 14 Dec 2013 01:12:13 +0000 (01:12 +0000)]
MFC r258392, r258412:

  Call cpu_setup() immediately after the page tables are installed.  This
  enables data cache and other chip-specific features.  It was previously
  done via an early SYSINIT, but it was being done after pmap and vm setup,
  and those setups need to use mutexes.  On some modern ARM platforms,
  the ldrex/strex instructions that implement mutexes require the data cache
  to be enabled.

  Call cpu_setup() from the initarm() routine on platforms that don't use
  the common FDT-aware initarm() in arm/machdep.c.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259377 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258393:
ian [Sat, 14 Dec 2013 00:59:40 +0000 (00:59 +0000)]
MFC r258393:

  Add USB_HOST_ALIGN=64; the cache line size on the am335x is 64 bytes.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259375 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258356:
ian [Sat, 14 Dec 2013 00:58:13 +0000 (00:58 +0000)]
MFC r258356:

  Bugfixes... the host capabilties from FDT data are stored in host.caps, not
  host.host_ocr, examine the correct field when setting up the hardware.  Also,
  the offset for the capabilties register should be 0x140, not 0x240.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259374 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258240:
ian [Sat, 14 Dec 2013 00:57:05 +0000 (00:57 +0000)]
MFC r258240:

  In the data abort handler, don't panic if kdb is available and says it
  handled the condition.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259373 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258740:
ian [Sat, 14 Dec 2013 00:55:34 +0000 (00:55 +0000)]
MFC r258740:

  Look up a nand chip by id in the static table before trying to obtain
  ONFI parameters.  This allows a static table entry to provide valid data
  for chips known to provide invalid ONFI data.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259372 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257892, r258196, r258197, r258199, r258200, r258201, r258202:
ian [Sat, 14 Dec 2013 00:54:05 +0000 (00:54 +0000)]
MFC r257892, r258196, r258197, r258199, r258200, r258201, r258202:

  Add ONFI signature check.

  Add Micron chip found in Freescale Vybrid Family Phytec COSMIC board.

  The vendor specified field is 88 bytes, not 8 bytes.

  Update the onfi_params struct to ONFI revision 3.2 (06 12 2013).

  Search for and validate the ONFI params as specified in the standard.

  ONFI parameters are little-endian, hence we must take care to convert them
  to native endianness.  We must also pay attention to unaligned accesses.

  Rework the routine that returns a pointer to the table of software ECC
  byte positions within the OOB area to support chips with unusual OOB
  sizes such as 218 or 224 bytes.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259371 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r258076, r258077:
ian [Sat, 14 Dec 2013 00:25:57 +0000 (00:25 +0000)]
MFC r258076, r258077:

  This fixes 3 problems in syslogd related to sizing receive buffers...

  - A call was misplaced at the wrong level of nested if blocks, so that
    the buffers for unix domain sockets (/dev/log, /dev/klog) were never
    increased at all; they remained at a way-too-small default size of 4096.

  - The function that was supposed to double the size of the buffer
    sometimes did nothing, and sometimes installed a wildly-wrong buffer
    size (either too large or too small) due to an unitialized 'slen'
    variable passed to getsockopt().  Most often it doubled the UDP buffers
    from 40k to 80k because accidentally there would be harmless stack
    garbage in the unitialized variables.

  - The whole concept of blindly doubling a socket's buffer size without
    knowing what size it started at is a design flaw that has to be called a
    bug.  If the double_rbuf() function had worked at all (I.E., if the
    other two bugs didn't exist) this would lead to UDP sockets having an
    80k buffer while unix dgram sockets get an 8k buffer.  There's nothing
    about the problem being solved that requires larger buffers for UDP than
    for unix dgram sockets -- the buffering requirements are the same
    regardless of socket type.

  This change renames the double_rbuf() function to increase_rbuf() and
  increases the buffer size on all types of sockets to 80k.  80k was
  chosen only because it appears to be the size the original change was
  shooting for, and it certainly seems to be reasonably large (I might
  have picked 64k in the absence of any historical guidance).

  Add ENETUNREACH and EADDRNOTAVAIL to the list of errors that are potentially
  transient and shouldn't result in closing the socket and giving up forever.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259368 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257924:
ian [Sat, 14 Dec 2013 00:23:43 +0000 (00:23 +0000)]
MFC r257924:

  Apparently with "const uint32_t foo = 0x60;" gcc doesn't consider 'foo'
  to be a constant integer suitable for use in a case label, so use #defines.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259366 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257669, r257672, r257673, r257676, r257678:
ian [Sat, 14 Dec 2013 00:16:08 +0000 (00:16 +0000)]
MFC r257669, r257672, r257673, r257676, r257678:

  Call initarm_lastaddr() later in the init sequence, after establishing
  static device mappings, rather than as the first of the initializations
  that a platform can hook into.  This allows a platform to allocate KVA
  from the top of the address space downwards for things like static device
  mapping, and return the final "last usable address" result after that and
  other early init work is done.

  Because some platforms were doing work in initarm_lastaddr() that needs to
  be done early, add a new initarm_early_init() routine and move the early
  init code to that routine on those platforms.

  Make PTE_DEVICE a synonym for PTE_NOCACHE on armv4, to make it easier to
  share the same code on both architectures.

  Add new helper routines for arm static device mapping.  The new code
  allocates kva space from the top down for the device mappings and builds
  entries in an internal table which is automatically used later by
  arm_devmap_bootstrap().  The platform code just calls the new
  arm_devmap_add_entry() function as many times as it needs to (up to 32
  entries allowed; most platforms use 2 or 3 at most).

  Remove imx local devmap code and use the essentially identical common
  code that got moved from imx_machdep.c to arm/devmap.c.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259365 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257648, r257649, r257660:
ian [Fri, 13 Dec 2013 23:56:53 +0000 (23:56 +0000)]
MFC r257648, r257649, r257660:

  Begin reducing code duplication in arm pmap.c and pmap-v6.c by factoring
  out common code related to mapping device memory into a new devmap.c file.

  Remove the growing duplication of code that used pmap_devmap_find_pa() and
  then did some math with the returned results to generate a virtual address,
  and likewise in reverse to get a physical address.  Now there are a pair
  of functions, arm_devmap_vtop() and arm_devmap_ptov(), to do that.  The
  bus_space_map() implementations are rewritten in terms of these.

  Move remaining code and data related to static device mapping into the
  new devmap.[ch] files.  Emphasize the MD nature of these things by using
  the prefix arm_devmap_ on the function and type names (already a few of
  these things found their way into MI code, hopefully it will be harder to
  do by accident in the future).

git-svn-id: svn://svn.freebsd.org/base/stable/10@259364 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257639:
ian [Fri, 13 Dec 2013 23:07:22 +0000 (23:07 +0000)]
MFC r257639:

  Remove the duplicated implementations of some bus_space functions and use
  the essentially identical generic implementations instead.  The generic
  implementations differ only in the spelling of a couple variable names
  and some formatting differences.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259363 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257603, r257604:
ian [Fri, 13 Dec 2013 22:52:59 +0000 (22:52 +0000)]
MFC r257603, r257604:

  Rename WANDBOARD-COMMON to WANDBOARD.common and adjust the configs that
  include it accordingly.  The build machinery for universe and tinderbox
  tries to build every kernel config whose name begins and ends with [A-Z0-9]
  and the common include file that has most of the options isn't buildable
  by itself, so the new lowercase .common will avoid building it.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259361 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257595: Comments and style(9) only, no functional changes.
ian [Fri, 13 Dec 2013 22:51:09 +0000 (22:51 +0000)]
MFC r257595:  Comments and style(9) only, no functional changes.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259360 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257561:
ian [Fri, 13 Dec 2013 22:50:12 +0000 (22:50 +0000)]
MFC r257561:

  Bugfix:  the attach routine needs to use the same table of fdt compat
  strings that the probe routine used.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259359 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257557: Add a missing register definition.
ian [Fri, 13 Dec 2013 22:49:18 +0000 (22:49 +0000)]
MFC r257557:  Add a missing register definition.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259358 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257556:
ian [Fri, 13 Dec 2013 22:48:01 +0000 (22:48 +0000)]
MFC r257556:

  Arrange for uart_cpu_fdt's probe() routine to use the same table of compat
  strings as uart_bus_fdt's probe().

git-svn-id: svn://svn.freebsd.org/base/stable/10@259357 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257518, r257519:
ian [Fri, 13 Dec 2013 22:46:10 +0000 (22:46 +0000)]
MFC r257518, r257519:

  TI sdhci driver improvements, mostly related to fdt data...

  Use the published compatible strings (our own invention, "ti,mmchs" is
  still accepted as well, for now).

  Don't blindly turn on 8-bit bus mode, because even though the controller
  supports it, the board has to be wired appropriately as well.  Use the
  published property (bus-width=<n>) and honor all the valid values (1,4,8).

  The eMMC device on a Beaglebone Black is wired for 8-bit, update the dts.

  The mmchs controller can inherently do both 1.8v and 3.0v on the first
  device and 1.8v only on other devices, unless an external transceiver is
  used.  Set the voltage automatically for the first device and honor
  the published fdt property (ti,dualvolt) for other devices.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259356 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257483, r257486, r257489:
ian [Fri, 13 Dec 2013 22:41:57 +0000 (22:41 +0000)]
MFC r257483, r257486, r257489:

  Add the Soc- / machine-dependent parts of imx6 support.
  Add dts source for imx6 SoCs and for Wandboard boards.
  Add kernel config for Wandboard.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259355 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257476, r257478:
ian [Fri, 13 Dec 2013 22:30:21 +0000 (22:30 +0000)]
MFC r257476, r257478:

  Revamp the SoC identity numbering scheme to be more in line with the way
  Freescale numbers the chips in the ID registers.

  Add definitions for the register and data that describes the SoC type.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259354 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257454: Add sdhci driver glue for imx family SoCs.
ian [Fri, 13 Dec 2013 22:28:19 +0000 (22:28 +0000)]
MFC r257454:  Add sdhci driver glue for imx family SoCs.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259353 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

10 years agoMFC r257453: Add stubbed-out imx6 support for clocks and power management.
ian [Fri, 13 Dec 2013 22:27:26 +0000 (22:27 +0000)]
MFC r257453:  Add stubbed-out imx6 support for clocks and power management.

git-svn-id: svn://svn.freebsd.org/base/stable/10@259352 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f