]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/log
FreeBSD/stable/10.git
9 years agoMFC: r279364
jkim [Fri, 6 Mar 2015 22:31:35 +0000 (22:31 +0000)]
MFC: r279364

Use realpath(3) to properly expand $ORIGIN to its absolute path.

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

9 years agoMFC of 279706,tzdata10:
edwin [Fri, 6 Mar 2015 21:56:44 +0000 (21:56 +0000)]
MFC of 279706,tzdata10:

Release 2015a - 2015-01-29

Changes affecting future time stamps

    The Mexican state of Quintana Roo, represented by America/Cancun,
    will shift from Central Time with DST to Eastern Time without DST
    on 2015-02-01 at 02:00.  (Thanks to Steffen Thorsen and Gwillim Law.)

    Chile will not change clocks in April or thereafter; its new standard time
    will be its old daylight saving time.  This affects America/Santiago,
    Pacific/Easter, and Antarctica/Palmer.  (Thanks to Juan Correa.)

    New leap second 2015-06-30 23:59:60 UTC as per IERS Bulletin C 49.
    (Thanks to Tim Parenti.)

  Changes affecting past time stamps

    Iceland observed DST in 1919 and 1921, and its 1939 fallback
    transition was Oct. 29, not Nov. 29.  Remove incorrect data from
    Shanks about time in Iceland between 1837 and 1908.

    Some more zones have been turned into links, when they differed
    from existing zones only for older time stamps.  As usual,
    these changes affect UTC offsets in pre-1970 time stamps only.
    Their old contents have been moved to the 'backzone' file.
    The affected zones are: Asia/Aden, Asia/Bahrain, Asia/Kuwait,
    and Asia/Muscat.

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

9 years agoMFC r279563:
hselasky [Fri, 6 Mar 2015 16:08:10 +0000 (16:08 +0000)]
MFC r279563:
Add quirk for USB 3.0 controllers which don't support 64-bit DMA.

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

9 years agoMFH: r279050
brueffer [Fri, 6 Mar 2015 11:25:10 +0000 (11:25 +0000)]
MFH: r279050

Apply mdoc style.

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

9 years agoMFC r279362:
kib [Fri, 6 Mar 2015 09:22:05 +0000 (09:22 +0000)]
MFC r279362:
The VNASSERT in vflush() FORCECLOSE case is trying to panic early to
prevent errors from yanking devices out from under filesystems.  Only
care about special vnodes on devfs, special nodes on other kinds of
filesystems do not have special properties.

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

9 years agoMFC r279544:
hselasky [Thu, 5 Mar 2015 10:18:03 +0000 (10:18 +0000)]
MFC r279544:
Add quirk to disable 64-bit XHCI DMA after r276717.

Requested by: Gary Jennejohn <gljennjohn@gmail.com>

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

9 years agoMFC r279324:
ae [Thu, 5 Mar 2015 10:08:37 +0000 (10:08 +0000)]
MFC r279324:
  When gpart(8) is trying automatically determine the first available
  block of free space after existing partition, take into account
  provider's stripeoffset, since the result will be adjusted to this
  value.

  PR: 197989

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

9 years agoMFC r279210:
hselasky [Thu, 5 Mar 2015 10:04:34 +0000 (10:04 +0000)]
MFC r279210:
Add support for the DWC OTG v2 chipset found in the STM32F4 series of
processors. Make sure we pullup the data lines in device mode when we
power on the port.

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

9 years agoMFC r279297:
hselasky [Thu, 5 Mar 2015 09:39:29 +0000 (09:39 +0000)]
MFC r279297:
Update to upstream version 2.10

The most notable new feature is support for definition files.

Obtained from: http://dotat.at/prog/unifdef

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

9 years agoMFC r279270:
hselasky [Thu, 5 Mar 2015 09:31:36 +0000 (09:31 +0000)]
MFC r279270:
Add ugen keyword to USB pnpinfo. Remove extra space from existing pnpinfo.

PR: 198015
PR: 198019
PR: 198026

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

9 years agoMFC r279241 and r279242:
hselasky [Thu, 5 Mar 2015 09:23:43 +0000 (09:23 +0000)]
MFC r279241 and r279242:
Fix debugging macros.

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

9 years agoMFC r279326:
kib [Thu, 5 Mar 2015 09:01:46 +0000 (09:01 +0000)]
MFC r279326:
Use pthread_mutex_trylock(3) to implement mtx_trylock(3).

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

9 years agoMFC r279318:
kib [Thu, 5 Mar 2015 09:00:27 +0000 (09:00 +0000)]
MFC r279318:
Check that the pointer to the thread return value is not NULL before
dereferencing. NULL is allowed by C11 and must be handled.

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

9 years agoMFC r278493: Update copyrights.
dteske [Thu, 5 Mar 2015 00:44:50 +0000 (00:44 +0000)]
MFC r278493: Update copyrights.

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

9 years agoMFC r278491: Add bsdconfig api function f_dialog_menutag2help()
dteske [Thu, 5 Mar 2015 00:43:50 +0000 (00:43 +0000)]
MFC r278491: Add bsdconfig api function f_dialog_menutag2help()

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

9 years agoMFC r278490:
dteske [Thu, 5 Mar 2015 00:42:58 +0000 (00:42 +0000)]
MFC r278490:
Add bsdconfig api functions f_dialog_pause()/f_dialog_pause_no_cancel()

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

9 years agoMFC r278489: Eliminate sub-shells where possible for performance.
dteske [Thu, 5 Mar 2015 00:42:06 +0000 (00:42 +0000)]
MFC r278489: Eliminate sub-shells where possible for performance.

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

9 years agoMFC r278488: Whitespace.
dteske [Thu, 5 Mar 2015 00:41:03 +0000 (00:41 +0000)]
MFC r278488: Whitespace.

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

9 years agoMFC r278483: Comments.
dteske [Thu, 5 Mar 2015 00:40:19 +0000 (00:40 +0000)]
MFC r278483: Comments.

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

9 years agoMFC r278470:
dteske [Thu, 5 Mar 2015 00:39:15 +0000 (00:39 +0000)]
MFC r278470:
Add new alias "bsdconfig api" (same as "bsdconfig includes")
NB: My fingers like typing "api" a lot more than "includes"

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

9 years agoMFC r278467:
dteske [Thu, 5 Mar 2015 00:37:54 +0000 (00:37 +0000)]
MFC r278467:
Replace the only instance of sed(1) in bsdconfig(8) with awk(1).

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

9 years agoMFC r274073:
dteske [Thu, 5 Mar 2015 00:34:33 +0000 (00:34 +0000)]
MFC r274073:
Follow-up to r255036; remove beforeinstall directives from bsdconfig(8)
Makefile's, fixing concurrent installworld (`make -j17 installworld').

Reviewed by: delphij
Thanks to: delphij, emaste

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

9 years agoMFC r273068:
dteske [Thu, 5 Mar 2015 00:32:54 +0000 (00:32 +0000)]
MFC r273068:
Rename awk(1) implementation of GNU awk's built-in asorti() function to
prevent fatal conflict should one-true-awk ever be replaced -- e.g., in
an appliance -- with GNU awk. NB: Renamed my implementation to _asorti()

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

9 years agoMFC r273067:
dteske [Thu, 5 Mar 2015 00:29:58 +0000 (00:29 +0000)]
MFC r273067:
Fix awk(1) asorti() implementation to work when called in a loop.

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

9 years agoMFC r279284:
kib [Wed, 4 Mar 2015 09:32:59 +0000 (09:32 +0000)]
MFC r279284:
Propagate errors from _thr_umutex_unlock2 through mutex_unlock_common.

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

9 years agoMFC r279283:
kib [Wed, 4 Mar 2015 09:31:10 +0000 (09:31 +0000)]
MFC r279283:
When failing to claim ownership of a umtx_pi, restore the umutex owner
to its previous, unowned state.

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

9 years agoMFC r279282:
kib [Wed, 4 Mar 2015 09:29:25 +0000 (09:29 +0000)]
MFC r279282:
When unlocking a contested PI pthread mutex, if the queue of waiters
is empty, look up the umtx_pi and disown it if the current thread owns it.

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

9 years agoMFC r279301: GNU nm: Avoid NULL dereference
emaste [Wed, 4 Mar 2015 01:10:09 +0000 (01:10 +0000)]
MFC r279301: GNU nm: Avoid NULL dereference

  bfd_dwarf2_find_line() calls find_line() with NULL functionname_ptr,
  which resulted in a crash on certain ELF objects.

  This change was implemented independently from upstream binutils, but
  I have checked that the crash does not happen there.

Sponsored by: The FreeBSD Foundation

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

9 years agoMFC r278915:
loos [Tue, 3 Mar 2015 17:03:41 +0000 (17:03 +0000)]
MFC r278915:

Set the #address-cells and #size-cells properties on I2C controllers of
Raspberry-pi.

This fixes the issues on dtc(1) while compiling I2C addresses set with
"reg" property.

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

9 years agoMFC r278844:
royger [Tue, 3 Mar 2015 10:11:58 +0000 (10:11 +0000)]
MFC r278844:

xen: fix xenstore dev

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

9 years agoMFC r279249, r279250, r279257:
gjb [Tue, 3 Mar 2015 02:46:59 +0000 (02:46 +0000)]
MFC r279249, r279250, r279257:

 r279249:
  Add 'cloudware-install' target to handle copying cloud
  disk images to a directory within DESTDIR.

  Add CLOUDINSTALL variable to automatically generate the
  actual list of install targets.  While here, rename the
  cloud-specific names from 'vm-' to 'cw-' to avoid naming
  collisions.

  Add AZURE_DISK, GCE_DISK, and OPENSTACK_DISK output file
  variables.

  Add 'cloudware-install' to the 'install' target.

 r279250:
  Remove a stale comment.

 r279257:
  Add a CLOUDPACKAGE variable to contain a list of targets for
  post-install packaging cloud provider images.

  Add a 'gce-package.sh' script to generate the final output
  image ready for upload to the GCE platform.  Right now, this
  is the only image that has a specific output format (GNU-tar),
  and this implementation is expected to be temporary.

  This is not directly connected to the other release targets.

Sponsored by: The FreeBSD Foundation

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

9 years agoMFC rev. 278728:
thomas [Mon, 2 Mar 2015 23:17:17 +0000 (23:17 +0000)]
MFC rev. 278728:
(backup_kernel_finddir, backup_kernel, install_files):
Add missing references to $BASEDIR, in order to allow correct operation
when updating a system mounted at another location than / (e.g. when
updating an alternate Boot Environment).

Reviewed by:  cperciva

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

9 years agoMFC r279346:
ken [Mon, 2 Mar 2015 21:00:54 +0000 (21:00 +0000)]
MFC r279346:

  ------------------------------------------------------------------------
  r279346 | ken | 2015-02-26 19:44:12 -0700 (Thu, 26 Feb 2015) | 13 lines

  Remove an obsolete comment in devstat(3) about the accuracy of the
  milliseconds per transaction (DSM_MS_PER_TRANSACTION) calculation.

  The comment was accurate many years ago when the kernel didn't
  record I/O times on a per-I/O basis, but now that we do collect
  that information in most areas, it isn't correct.

  The milliseconds per transaction values are correct, assuming the
  I/O duration has been recorded.

  Sponsored by: Spectra Logic

  ------------------------------------------------------------------------

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

9 years agoMFC r279367:
kib [Mon, 2 Mar 2015 09:15:50 +0000 (09:15 +0000)]
MFC r279367:
Fix typo.

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

9 years agoMFC r279206:
ae [Mon, 2 Mar 2015 07:51:14 +0000 (07:51 +0000)]
MFC r279206:
  In some cases soreceive_dgram() can return no data, but has control
  message. This can happen when application is sending packets too big
  for the path MTU and recvmsg() will return zero (indicating no data)
  but there will be a cmsghdr with cmsg_type set to IPV6_PATHMTU.
  Remove KASSERT() which does NULL pointer dereference in such case.
  Also call m_freem() only when m isn't NULL.

MFC r279209:
  soreceive_generic() still has similar KASSERT(), therefore instead of
  remove KASSERT(), change it to check mbuf isn't NULL.

PR: 197882
Sponsored by: Yandex LLC

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

9 years agoRegen src.conf(5)
ngie [Sun, 1 Mar 2015 22:12:24 +0000 (22:12 +0000)]
Regen src.conf(5)

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

9 years agoMFC r278193:
ngie [Sun, 1 Mar 2015 22:07:54 +0000 (22:07 +0000)]
MFC r278193:

Add MK_FILE to control whether or not to build file(1), libmagic(3), etc

Sponsored by: EMC / Isilon Storage Division

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

9 years agoMFC r278192:
ngie [Sun, 1 Mar 2015 22:03:52 +0000 (22:03 +0000)]
MFC r278192:

Add the following options to enable/disable several features in the base system

WITHOUT_BOOTPARAMD - bootparamd
WITHOUT_BOOTPD - bootpd
WITHOUT_FINGER - finger, fingerd
WITHOUT_FTP - ftp, ftpd
WITHOUT_INETD - inetd
WITHOUT_RBOOTD - rbootd
WITHOUT_TCP_WRAPPERS - tcpd, et al
WITHOUT_TFTP - tftp, tftp-server
WITHOUT_TIMED - timed

Sponsored by: EMC / Isilon Storage Division

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

9 years agoMFC r278704:
ngie [Sun, 1 Mar 2015 21:24:19 +0000 (21:24 +0000)]
MFC r278704:

Unbreak rcorder when MK_UNBOUND == no by moving local_unbound from REQUIRE:
in NETWORKING to BEFORE: in the script

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

9 years agoUnbreak rcorUnbreak rcorder when MK_UTX == no by moving utx from REQUIRE: in LOGIN to
ngie [Sun, 1 Mar 2015 21:22:34 +0000 (21:22 +0000)]
Unbreak rcorUnbreak rcorder when MK_UTX == no by moving utx from REQUIRE: in LOGIN to
BEFORE: in utx

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

9 years agoMFC r278891:
ngie [Sun, 1 Mar 2015 21:03:34 +0000 (21:03 +0000)]
MFC r278891:

Add the mnt_lockref field to the ddb(4) 'show mount' command

Differential Revision: https://reviews.freebsd.org/D1688
Submitted by: Conrad Meyer <conrad.meyer@isilon.com>
Sponsored by: EMC / Isilon Storage Division

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

9 years agoMFC r276949:
kib [Sun, 1 Mar 2015 10:39:19 +0000 (10:39 +0000)]
MFC r276949:
(only to ease merging of r279117).

MFC r279117:
Revert r276949 and redo the fix for PCIe/PCI bridges, which do not
follow specification and do not provide PCIe capability.

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

9 years agoMFC r276948:
kib [Sun, 1 Mar 2015 10:35:54 +0000 (10:35 +0000)]
MFC r276948:
Print rid when announcing DMAR context creation.  Print sid when fault
occurs.

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

9 years agoMFC r276867:
kib [Sun, 1 Mar 2015 10:29:48 +0000 (10:29 +0000)]
MFC r276867:
Fix DMAR context allocations for the devices behind PCIe->PCI bridges
after dmar driver was converted to use rids.  The bus component to
calculate context page must be taken from the requestor rid, which is
a bridge, and not from the device bus number.

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

9 years agoMFC r279276: Add checks for malloc() failures.
mav [Sun, 1 Mar 2015 09:29:59 +0000 (09:29 +0000)]
MFC r279276: Add checks for malloc() failures.

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

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

9 years agoMFC r279277: Fix memory leak on incorrect initiator portal.
mav [Sun, 1 Mar 2015 09:28:39 +0000 (09:28 +0000)]
MFC r279277: Fix memory leak on incorrect initiator portal.

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

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

9 years agoMFC r277649:
rstone [Sun, 1 Mar 2015 04:39:07 +0000 (04:39 +0000)]
MFC r277649:

   vmspace_release() may sleep if the last reference is being released,
   so add a WITNESS_WARN() to catch cases where it is called with a
   non-sleepable lock held.

   MFC after:    1 month
   Sponsored by: Sandvine Inc.

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

9 years agoMFC r272284
rstone [Sun, 1 Mar 2015 04:36:20 +0000 (04:36 +0000)]
MFC r272284

   Fix integer truncation in affecting systat -ifstat

   The "systat -ifstat" command was using a u_int to store byte counters.
   With a 10Gbps or faster interface, this overflows within the default
   5 second refresh period.  Switch to using a uint64_t across the board,
   which matches the size used for all counters as of r263102.

   PR:           182448
   MFC after:    1 week
   Sponsored by: Sandvine Inc

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

9 years agoMFC r265107
rstone [Sun, 1 Mar 2015 04:28:30 +0000 (04:28 +0000)]
MFC r265107

   Be consistent with the whitespace in the rest of these files.

   X-MFC-With: r264007

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

9 years agoMFC r264091
rstone [Sun, 1 Mar 2015 04:26:47 +0000 (04:26 +0000)]
MFC r264091

   Correct a PCI enumeration bug introduced in r264011

   Ensure that first_func is set to 0 on every iteration of the PCI slot
   enumeration loop after the first.  There is a continue statement that would
   cause first_func to stay at 1 any PCI device where slot 0 has no functions
   until we find a slot that does have a function.  This would cause us to
   not enumerate the first PCI function on the device.

   Credit to markj@ for spotting the bug.

   X-MFC-With: r264011

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

9 years agoMFC r264007,r264008,r264009,r264011,r264012,r264013
rstone [Sun, 1 Mar 2015 04:22:06 +0000 (04:22 +0000)]
MFC r264007,r264008,r264009,r264011,r264012,r264013

MFC support for PCI Alternate RID Interpretation.  ARI is an optional PCIe
feature that allows PCI devices to present up to 256 functions on a bus.
This is effectively a prerequisite for PCI SR-IOV support.

r264007:
   Add a method to get the PCI RID for a device.

   Reviewed by:  kib
   MFC after:    2 months
   Sponsored by: Sandvine Inc.

r264008:
   Re-implement the DMAR I/O MMU code in terms of PCI RIDs

   Under the hood the VT-d spec is really implemented in terms of
   PCI RIDs instead of bus/slot/function, even though the spec makes
   pains to convert back to bus/slot/function in examples.  However
   working with bus/slot/function is not correct when PCI ARI is
   in use, so convert to using RIDs in most cases.  bus/slot/function
   will only be used when reporting errors to a user.

   Reviewed by:  kib
   MFC after:    2 months
   Sponsored by: Sandvine Inc.

r264009:
   Re-write bhyve's I/O MMU handling in terms of PCI RID.

   Reviewed by:  neel
   MFC after:    2 months
   Sponsored by: Sandvine Inc.

r264011:
   Add support for PCIe ARI

   PCIe Alternate RID Interpretation (ARI) is an optional feature that
   allows devices to have up to 256 different functions.  It is
   implemented by always setting the PCI slot number to 0 and
   re-purposing the 5 bits used to encode the slot number to instead
   contain the function number.  Combined with the original 3 bits
   allocated for the function number, this allows for 256 functions.

   This is enabled by default, but it's expected to be a no-op on currently
   supported hardware.  It's a prerequisite for supporting PCI SR-IOV, and
   I want the ARI support to go in early to help shake out any bugs in it.
   ARI can be disabled by setting the tunable hw.pci.enable_ari=0.

   Reviewed by:  kib
   MFC after:    2 months
   Sponsored by: Sandvine Inc.

r264012:
   Print status of ARI capability in pciconf -c

   Teach pciconf how to print out the status (enabled/disabled) of the ARI
   capability on PCI Root Complexes and Downstream Ports.

   MFC after:    2 months
   Sponsored by: Sandvine Inc.

r264013:
   Add missing copyright date.

   MFC after:    2 months

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

9 years agoMFC r279312:
dim [Sun, 1 Mar 2015 01:08:14 +0000 (01:08 +0000)]
MFC r279312:

Fix a number of -Wcast-qual warnings under sys/arm.  No functional
change.

Submitted by: andrew

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

9 years agoMFC r279311:
dim [Sun, 1 Mar 2015 00:57:01 +0000 (00:57 +0000)]
MFC r279311:

In sys/arm/ti/am335x/am335x_rtc.c, fix a clang 3.6.0 warning about
am33x_rtc_softc::sc_irq_res (which is an array) never being NULL.

Submitted by: andrew

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

9 years agoMFC r279307:
dim [Sun, 1 Mar 2015 00:47:37 +0000 (00:47 +0000)]
MFC r279307:

Make libcxxrt's parsing of DWARF exception handling tables work on
architectures with strict alignment, by using memcpy() instead of
directly reading fields.

Reported by: Daisuke Aoyama <aoyama@peach.ne.jp>
Reviewed by: imp, bapt
Tested by: bapt
Differential Revision: https://reviews.freebsd.org/D1967

MFC r279310:

Since newer versions of compiler-rt require unwind.h, and we want to use
the copy in libcxxrt for it, fix the arm-specific header to define the
_Unwind_Action type.

Submitted by: andrew

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

9 years agoMFC r279233:
hselasky [Fri, 27 Feb 2015 12:20:03 +0000 (12:20 +0000)]
MFC r279233:
Ensure that the XHCI driver will refresh the control endpoint settings
when re-enumerating a FULL speed device. Else the wrong max packet
setting might be used when trying to re-enumerate a FULL speed device.

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

9 years agoMFC r279083:
jamie [Fri, 27 Feb 2015 02:53:44 +0000 (02:53 +0000)]
MFC r279083:

  Fix the logic for skipping parameters (with -s) that have "jailsys"
  parents (such as host.hostname); these were being skipped all the time.
  That it went this long without anyone noticing is a sign that this feature
  isn't actually used by anyone, but it's there so it might as well work.

MFC r279123:

  Allow for parameters added with the JP_OPT flag to not exist.
  That's why the flag exists in the first place.

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

9 years agoMFC r279081:
jamie [Fri, 27 Feb 2015 02:50:01 +0000 (02:50 +0000)]
MFC r279081:

  Allow parameters listed on the command line to override the -v option,
  instead of crashing.

PR: 197701

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

9 years agoMFC r278964:
ken [Thu, 26 Feb 2015 20:46:16 +0000 (20:46 +0000)]
MFC r278964:

The __FreeBSD_version was changed to 1001510 to be appropriate for
stable/10.

I will followup with a commit to mpr(4) and mps(4) in head to reflect
the stable/10 __FreeBSD_version and merge the change back to stable/10.

  ------------------------------------------------------------------------
  r278964 | ken | 2015-02-18 11:30:19 -0700 (Wed, 18 Feb 2015) | 46 lines

  Make sure that the flags for the XPT_DEV_ADVINFO CCB are initialized
  properly.

  If there is garbage in the flags field, it can sometimes include a
  set CDAI_FLAG_STORE flag, which may cause either an error or
  perhaps result in overwriting the field that was intended to be
  read.

  sys/cam/cam_ccb.h:
   Add a new flag to the XPT_DEV_ADVINFO CCB, CDAI_FLAG_NONE,
   that callers can use to set the flags field when no store
   is desired.

  sys/cam/scsi/scsi_enc_ses.c:
   In ses_setphyspath_callback(), explicitly set the
   XPT_DEV_ADVINFO flags to CDAI_FLAG_NONE when fetching the
   physical path information.  Instead of ORing in the
   CDAI_FLAG_STORE flag when storing the physical path, set
   the flags field to CDAI_FLAG_STORE.

  sys/cam/scsi/scsi_sa.c:
   Set the XPT_DEV_ADVINFO flags field to CDAI_FLAG_NONE when
   fetching extended inquiry information.

  sys/cam/scsi/scsi_da.c:
   When storing extended READ CAPACITY information, set the
   XPT_DEV_ADVINFO flags field to CDAI_FLAG_STORE instead of
   ORing it into a field that isn't initialized.

  sys/dev/mpr/mpr_sas.c,
  sys/dev/mps/mps_sas.c:
   When fetching extended READ CAPACITY information, set the
   XPT_DEV_ADVINFO flags field to CDAI_FLAG_NONE instead of
   setting it to 0.

  sbin/camcontrol/camcontrol.c:
   When fetching a device ID, set the XPT_DEV_ADVINFO flags
   field to CDAI_FLAG_NONE instead of 0.

  sys/sys/param.h:
   Bump __FreeBSD_version to 1100061 for the new XPT_DEV_ADVINFO
   CCB flag, CDAI_FLAG_NONE.

  Sponsored by: Spectra Logic

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

9 years agoMFC r278933:
rpaulo [Thu, 26 Feb 2015 19:56:48 +0000 (19:56 +0000)]
MFC r278933:
  Fix a typo in ipv6_down().

  Submitted by: Ashutosh Kumar AK0037447 at TechMahindra.com

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

9 years agoImplement the -fuse-ld= option.
emaste [Wed, 25 Feb 2015 22:32:32 +0000 (22:32 +0000)]
Implement the -fuse-ld= option.

Merge upstream Clang revision 211785:
  This commit implements the -fuse-ld= option, so that the user
  can specify -fuse-ld=bfd to use ld.bfd.

  This commit re-applies r194328 with some test case changes.
  It seems that r194328 was breaking macosx or mingw build
  because clang can't find ld.bfd or ld.gold in the given sysroot.
  We should use -B to specify the executable search path instead.

  Patch originally by David Chisnall.

This is a direct commit to stable/10 as this is change is already
included in Clang 3.5 in HEAD. The patch is also reworked slightly for
Clang 3.4.1.

Reviewed by: dim
Sponsored by: The FreeBSD Foundation

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

9 years agoAdd clang patches corresponding to r279289.
dim [Wed, 25 Feb 2015 17:54:18 +0000 (17:54 +0000)]
Add clang patches corresponding to r279289.

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

9 years agoPull in r199571 from upstream clang trunk (by Ted Kremenek):
dim [Wed, 25 Feb 2015 17:27:02 +0000 (17:27 +0000)]
Pull in r199571 from upstream clang trunk (by Ted Kremenek):

  Harden InitListExpr::isStringLiteralInit() against getInit()
  returning null.

  This led to a crash on invalid code (sorry, no good test case).

  Fixes <rdar://problem/15831804>.

This fixes an assertion when compiling certain incorrect code, as
reported upstream in http://llvm.org/PR22684 .

Direct commit to stable/10 and stable/9, since head has clang 3.5.1,
which already includes this change.

Reported by: hbowden@securelabsllc.com

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

9 years agoBump __FreeBSD_version after FreeBSD-EN-15:01.vt,
gjb [Wed, 25 Feb 2015 16:44:40 +0000 (16:44 +0000)]
Bump __FreeBSD_version after FreeBSD-EN-15:01.vt,
FreeBSD-EN-15:02.openssl, FreeBSD-EN-15:03.freebsd-update,
FreeBSD-SA-15:04.igmp, FreeBSD-SA-15:05.bind

Sponsored by: The FreeBSD Foundation

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

9 years agoDocument FreeBSD-EN-15:01.vt, FreeBSD-EN-15:02.openssl,
gjb [Wed, 25 Feb 2015 16:36:44 +0000 (16:36 +0000)]
Document FreeBSD-EN-15:01.vt, FreeBSD-EN-15:02.openssl,
FreeBSD-EN-15:03.freebsd-update, FreeBSD-SA-15:04.igmp,
FreeBSD-SA-15:05.bind

Sponsored by: The FreeBSD Foundation

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

9 years agoMFC r278850:
hselasky [Wed, 25 Feb 2015 12:24:24 +0000 (12:24 +0000)]
MFC r278850:
Handle VBUS error interrupts.

PR: 190471

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

9 years agoMFC r278584: Add support for General Statistics and Performance log page.
mav [Wed, 25 Feb 2015 09:21:04 +0000 (09:21 +0000)]
MFC r278584: Add support for General Statistics and Performance log page.

CTL already collects most of statistics reported there, so why not.

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

9 years agoMFC r278963:
kib [Wed, 25 Feb 2015 09:19:26 +0000 (09:19 +0000)]
MFC r278963:
If malloc() sleeps, Giant is dropped.  Recheck for another thread
doing our work.

Remove unneeded check for failed M_WAITOK allocation.

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

9 years agoMFC r278586:
tijl [Wed, 25 Feb 2015 08:39:48 +0000 (08:39 +0000)]
MFC r278586:

Fix ldscripts such that ld(1) collects the .fini_array section in the same
order as the .init_array section.  Finalisation routines need to be called
in the opposite order as their corresponding initialisation routines but
rtld(1) handles that by calling the function pointers in .fini_array in
reverse order.

Reviewed by: kib

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

9 years agoInstant MFC:
delphij [Wed, 25 Feb 2015 05:43:02 +0000 (05:43 +0000)]
Instant MFC:

Fix integer overflow in IGMP protocol.

Security: FreeBSD-SA-15:04.igmp
Security: CVE-2015-1414
Found by: Mateusz Kocielski, Logicaltrust
Analyzed by: Marek Kroemeke, Mateusz Kocielski (shm@NetBSD.org) and
22733db72ab3ed94b5f8a1ffcde850251fe6f466
Submited by: Mariusz Zaborski <oshogbo@FreeBSD.org>
Reviewed by: bms
Approved by: so

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

9 years agoMFC: r278870
marius [Tue, 24 Feb 2015 22:28:44 +0000 (22:28 +0000)]
MFC: r278870

Unbreak sparc64 after r276630 (MFCed to stable/10 in r277317) by calling
__sparc_sigtramp_setup signal trampoline as part of the MD __sys_sigaction
again.

Submitted by: kib (initial versions)

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

9 years agoMFC part of r273865: fix boot1.efi for block size != 512
emaste [Tue, 24 Feb 2015 22:11:07 +0000 (22:11 +0000)]
MFC part of r273865: fix boot1.efi for block size != 512

r273865 is part of the work for supporting 4Kn drives, but it turns out
the underlying bug can actually cause corruption of the UEFI system
table in any case where block size is not 512.

Relevant portion of the original commit message:

  convert boot1.efi to corrrectly calculate the lba for what the
  media reports and convert the size based on what FreeBSD uses.
  existing code would use the 512 byte lba and convert the
  using 4K byte size.

PR: 197881
Reviewed by: Chris Ruffin

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

9 years agoMFC r278523:
kib [Tue, 24 Feb 2015 01:46:43 +0000 (01:46 +0000)]
MFC r278523:
In mountd, silence a race with the parallel unmount.

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

9 years agoMFC 275412:
jhb [Mon, 23 Feb 2015 21:16:02 +0000 (21:16 +0000)]
MFC 275412:
The runtime linker needs to include a path to itself in the link map
it exports to the debugger.  It currently has two choices: it can use
a compiled-in path (/libexec/ld-elf.so.1) or it can use the path stored
in the interpreter path in the binary being executed.  The runtime linker
currently prefers the second.  However, this is usually wrong for compat32
binaries since the binary specifies the path of rtld on a 32-bit system
(/libexec/ld-elf.so.1) instead of the actual path (/libexec/ld-elf32.so.1).
For now, always assume the compiled in path (/libexec/ld-elf32.so.1) as
the rtld path and ignore the path in the binary for the 32-bit runtime
linker.

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

9 years agoMFC 274817,274878,276801,276840,278976:
jhb [Mon, 23 Feb 2015 18:38:41 +0000 (18:38 +0000)]
MFC 274817,274878,276801,276840,278976:
Improve support for XSAVE with debuggers.
- Dump an NT_X86_XSTATE note if XSAVE is in use. This note is designed
  to match what Linux does in that 1) it dumps the entire XSAVE area
  including the fxsave state, and 2) it stashes a copy of the current
  xsave mask in the unused padding between the fxsave state and the
  xstate header at the same location used by Linux.
- Teach readelf() to recognize NT_X86_XSTATE notes.
- Change PT_GET/SETXSTATE to take the entire XSAVE state instead of
  only the extra portion. This avoids having to always make two
  ptrace() calls to get or set the full XSAVE state.
- Add a PT_GET_XSTATE_INFO which returns the length of the current
  XSTATE save area (so the size of the buffer needed for PT_GETXSTATE)
  and the current XSAVE mask (%xcr0).

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

9 years agoMFC r278857:
pluknet [Mon, 23 Feb 2015 08:45:42 +0000 (08:45 +0000)]
MFC r278857:
   kdump: sendfile(2) "flags" argument needs casting on 64-bit platforms.

Sponsored by: Nginx, Inc.

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

9 years agoMFC r278983:
markj [Mon, 23 Feb 2015 01:24:10 +0000 (01:24 +0000)]
MFC r278983:
Free the zlib stream once the CTF section is decompressed.

MFC r278984:
Remove unnecessary checks for a NULL return value from malloc.

MFC r279089:
Let vn_rdwr() check for short reads.

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

9 years agoMFC r278871:
kib [Mon, 23 Feb 2015 01:17:45 +0000 (01:17 +0000)]
MFC r278871:
Array cannot be NULL, remove always true comparision.

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

9 years agoMFC r278840:
kevlo [Sun, 22 Feb 2015 15:30:08 +0000 (15:30 +0000)]
MFC r278840:
Xref the following in wlan(4):

- rsu(4)
- urtwn(4)

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

9 years agoMFC r277481:
kevlo [Sun, 22 Feb 2015 15:28:49 +0000 (15:28 +0000)]
MFC r277481:
Typo: ivalid -> invalid.

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

9 years agoMFC r278551:
kevlo [Sun, 22 Feb 2015 15:27:02 +0000 (15:27 +0000)]
MFC r278551:
Add preliminary support for the Ralink RT5390 and RT5392 chipsets.
Committed over the D-Link DWA-525 rev A2 on amd64 with WPA.

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

9 years agoMFC r278790, r278802:
pfg [Sun, 22 Feb 2015 02:14:49 +0000 (02:14 +0000)]
MFC r278790, r278802:
Initialize the allocation of variables related to the ext2 allocator.

Use malloc to clear the values and initialize e2fs_contigdirs
during allocation.  free() e2fs_contigdirs upon error.

While here clean up small style issues.

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

9 years agoMFC r278791:
pfg [Sun, 22 Feb 2015 01:42:45 +0000 (01:42 +0000)]
MFC r278791:
Reuse value of cursize instead of recalculating.

Reported by: Clang static checker

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

9 years agoMFC r278803, r278905:
pfg [Sun, 22 Feb 2015 01:31:28 +0000 (01:31 +0000)]
MFC r278803, r278905:
ulimit(3): Fix broken check.

The existing implementation had a broken comparison that could
overflow and return confusing values.  Replace this with a check
that avoids the overflow before it happens.

Consistently return a maximum value also on the case of negative
arguments since negative is considered an overflow and means
infinity for our current setrlimit().

New revamped version is credited to Bruce Evans.

CID: 1199295

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

9 years agoUpdate commented last revision.
gjb [Fri, 20 Feb 2015 20:33:43 +0000 (20:33 +0000)]
Update commented last revision.

Sponsored by: The FreeBSD Foundation

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

9 years agoAdd 'Generic Storage' section.
gjb [Fri, 20 Feb 2015 20:30:04 +0000 (20:30 +0000)]
Add 'Generic Storage' section.

Document r279002, r279055:
 ctld(8) update to control non-iSCSI CTL ports
 CTL LUN mapping rewrite

Sponsored by: The FreeBSD Foundation

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

9 years agoDocument r277583, arc_meta_limit exposed via kstats.
gjb [Fri, 20 Feb 2015 20:30:01 +0000 (20:30 +0000)]
Document r277583, arc_meta_limit exposed via kstats.

Sponsored by: The FreeBSD Foundation

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

9 years agoDocument r277434, fstyp(8) addition.
gjb [Fri, 20 Feb 2015 20:29:59 +0000 (20:29 +0000)]
Document r277434, fstyp(8) addition.

Sponsored by: The FreeBSD Foundation

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

9 years agoMFC r278658:
rpaulo [Fri, 20 Feb 2015 20:02:47 +0000 (20:02 +0000)]
MFC r278658:

  Teach libproc how to find debugging symbols in /usr/lib/debug.

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

9 years agoDocument r278982, pmc callchain depths increased.
gjb [Fri, 20 Feb 2015 18:06:33 +0000 (18:06 +0000)]
Document r278982, pmc callchain depths increased.

Sponsored by: The FreeBSD Foundation

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

9 years agoMFC r278594: Add missing asprintf() status checks.
mav [Fri, 20 Feb 2015 17:10:46 +0000 (17:10 +0000)]
MFC r278594: Add missing asprintf() status checks.

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

9 years agoMFC r278354: Teach ctld(8) to control non-iSCSI CTL ports.
mav [Fri, 20 Feb 2015 17:09:49 +0000 (17:09 +0000)]
MFC r278354: Teach ctld(8) to control non-iSCSI CTL ports.

This change introduces new target option "port", that assigns current target
to specified CTL port.  On config application ctld(8) will apply LUN mapping
according to target configuration to specified port and bring the port up.
On shutdown cltd(8) will remove the mapping and put the port down.

This change allows to configure both iSCSI and FibreChannel targets in the
same configuration file in alike way.

Kernel side support was added earlier at r278037.

Relnotes: yes
Sponsored by: iXsystems, Inc.

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

9 years agoMFC r278311: Some NetGraph debug polishing.
mav [Fri, 20 Feb 2015 11:52:46 +0000 (11:52 +0000)]
MFC r278311: Some NetGraph debug polishing.

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

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

9 years agoMFC r278889:
kib [Fri, 20 Feb 2015 09:25:13 +0000 (09:25 +0000)]
MFC r278889:
Restore the extern qualifier on __cleanup.

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

9 years agoMFC r278856:
hselasky [Thu, 19 Feb 2015 17:42:12 +0000 (17:42 +0000)]
MFC r278856:
The "frag_info" pointer is already pointing to an array index.
Don't index twice.

Sponsored by: Mellanox Technologies

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

9 years agoMFC r278301, r278315:
pfg [Thu, 19 Feb 2015 16:24:27 +0000 (16:24 +0000)]
MFC r278301, r278315:
tdelete(3): don't delete the node we are about to return.

CID: 272528
Obtained from: NetBSD (CVS rev. 1.4)

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

9 years agoMFC r278300, r278314:
pfg [Thu, 19 Feb 2015 16:17:44 +0000 (16:17 +0000)]
MFC r278300, r278314:
getdiskbyname(): plug resource leak

Variable cq going out of scope leaks the storage it points to.

CID: 270511
Phabric: D1775
Reviewed by: imp
Obtained from: NetBSD (CVS rev. 1.34)

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

9 years agoMFC r278322: Add support for multiple portal groups per target.
mav [Thu, 19 Feb 2015 14:52:01 +0000 (14:52 +0000)]
MFC r278322: Add support for multiple portal groups per target.

This change allows multiple "portal-group" options to be specified per
target.  Each of them may include new optional auth-group name parameter
to override per-target auth parameters for specific portal group.

Kernel side support was added earlier at r278161.

Sponsored by: iXsystems, Inc.

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

9 years agoMFC r278672: Teach CTL to ask GEOM devices about BIO_DELETE support.
mav [Thu, 19 Feb 2015 14:40:50 +0000 (14:40 +0000)]
MFC r278672: Teach CTL to ask GEOM devices about BIO_DELETE support.

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

9 years agoMFC r278625: Make XCOPY and WUT commands respect physical block size/offset.
mav [Thu, 19 Feb 2015 14:36:03 +0000 (14:36 +0000)]
MFC r278625: Make XCOPY and WUT commands respect physical block size/offset.

This change by 2-3 times improves performance of misaligned XCOPY and WUT
commands by avoiding unneeded read-modify-write cycles inside ZFS.

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

9 years agoMFC r278161: Bring some more order into iSCSI portal group tags support.
mav [Thu, 19 Feb 2015 14:33:46 +0000 (14:33 +0000)]
MFC r278161: Bring some more order into iSCSI portal group tags support.

While ctld(8) still does not allow multiple portal groups per target
to be configured, kernel should now be able to handle it.

Sponsored by: iXsystems, Inc.

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