]> CyberLeo.Net >> Repos - FreeBSD/stable/9.git/log
FreeBSD/stable/9.git
10 years agoMFC r262577: MFV r262570:
delphij [Fri, 14 Mar 2014 01:10:54 +0000 (01:10 +0000)]
MFC r262577: MFV r262570:

4626 libzfs memleak in zpool_in_use()

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

10 years agoMFC r262572:
delphij [Fri, 14 Mar 2014 01:05:32 +0000 (01:05 +0000)]
MFC r262572:

Get rid of the 'chan' from softc structure and use the latter
directly as sleep channel.

PR: kern/174684
Submitted by: jmg

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

10 years agoMFC changes to atomic.h usage in DRM code
dumbbell [Thu, 13 Mar 2014 21:06:13 +0000 (21:06 +0000)]
MFC changes to atomic.h usage in DRM code

This commit follows the merge of atomic.h changes in r262807 and r262823.
The original work is from Jung-uk Kim (jkim@).

The following revisions were merged in this single commit:

r255009:
  Fix a compiler warning.  With this fix, a negative time can be converted to
  a struct timeval and back to the original nanoseconds correctly.

r255012:
  Fix a compiler warning and add couple of VM map types.

r255013:
  Correct atomic operations in i915.

r255037:
  Fix atomic operations on context_flag without altering semantics.

r255039:
  - Remove test_and_set_bit() macro.  It is unused since r255037.
  - Relax atomic_read() and atomic_set() macros.  Linux does not require any
  memory barrier.  Also, these macros may be even reordered or optimized away
  according to the API documentation:

  https://www.kernel.org/doc/Documentation/atomic_ops.txt

r255041:
  Clarify confusions between atomic_t and bitmap.  Fix bitmap operations
  accordingly.

r255042:
  Fix the incomplete conversion from atomic_t to long for test_bit().

r255044:
  Partially revert r254880.  The bitmap operations actually use long type now.

r255045:
  'u_long' is consistently spelled 'unsigned long' in this file.  Fix it.

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

10 years agoMFC r262539:
eadler [Thu, 13 Mar 2014 03:57:33 +0000 (03:57 +0000)]
MFC r262539:
linprocfs: add support for /sys/kernel/random/uuid

PR: kern/186187

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

10 years agoMFC r262220:
bdrewery [Thu, 13 Mar 2014 01:14:37 +0000 (01:14 +0000)]
MFC r262220:

  Add missing Save Cursor support for VT520

PR: conf/174937

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

10 years agoMFC r262732:
hselasky [Wed, 12 Mar 2014 08:30:18 +0000 (08:30 +0000)]
MFC r262732:
Add new quirk.

PR: usb/187188

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

10 years agoMFC r262795:
hselasky [Wed, 12 Mar 2014 08:26:49 +0000 (08:26 +0000)]
MFC r262795:
- Temporary fix for race in RUN driver which can
cause freed memory to be accessed.
- Properly lock callout_reset()'s.

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

10 years agoMFC r262477:
hselasky [Wed, 12 Mar 2014 08:21:36 +0000 (08:21 +0000)]
MFC r262477:
Updates for WSP driver.

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

10 years agoMFC: r261710
brueffer [Wed, 12 Mar 2014 08:16:17 +0000 (08:16 +0000)]
MFC: r261710

Only count table lookups when we're actually processing packets.

PR:             183462
Submitted by:   Sven-Thorsten Dietrich <thebigcorporation at gmail.com>
Reviewed by:    bms

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

10 years agoMFC
hselasky [Wed, 12 Mar 2014 08:08:41 +0000 (08:08 +0000)]
MFC
Sync usbdevs file to head branch.

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

10 years agoMFC r262417, r262439, r262454, r262455 and r262478:
hselasky [Wed, 12 Mar 2014 07:18:39 +0000 (07:18 +0000)]
MFC r262417, r262439, r262454, r262455 and r262478:
- Several updates and improvements to ATP driver.
- Start effort merging WSP and ATP driver.

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

10 years agoRegen after r263053
gjb [Tue, 11 Mar 2014 23:54:13 +0000 (23:54 +0000)]
Regen after r263053

Sponsored by: The FreeBSD Foundation

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

10 years agoMFC r253304, r255964:
gjb [Tue, 11 Mar 2014 23:04:32 +0000 (23:04 +0000)]
MFC r253304, r255964:
r253304:
  Ensure the locale is LC_ALL=C when regenerating
  src.conf.5

r255964:
  Have makeman always use the mk files from the source
  tree it's operating on rather than those from the
  installed system.

Sponsored by: The FreeBSD Foundation

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

10 years agoMFC r237997, r238018, r238023, r257440, r258924:
gjb [Tue, 11 Mar 2014 22:11:45 +0000 (22:11 +0000)]
MFC r237997, r238018, r238023, r257440, r258924:
  Add WITHOUT_PKGBOOTSTRAP options file.

Sponsored by: The FreeBSD Foundation

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

10 years agoRevert r263047 now that the missing commit was merged for pkg(7)
gjb [Tue, 11 Mar 2014 21:48:30 +0000 (21:48 +0000)]
Revert r263047 now that the missing commit was merged for pkg(7)
updates.

Sponsored by: The FreeBSD Foundation

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

10 years agoMFC 238010:
gjb [Tue, 11 Mar 2014 21:46:26 +0000 (21:46 +0000)]
MFC 238010:
  Add PKGBOOTSTRAP to __DEFAULT_YES_OPTIONS to fix build.

Sponsored by: The FreeBSD Foundation

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

10 years agoTemporarily turn off MK_PKGBOOTSTRAP evaluation to fix build.
gjb [Tue, 11 Mar 2014 21:06:17 +0000 (21:06 +0000)]
Temporarily turn off MK_PKGBOOTSTRAP evaluation to fix build.

Discussed with: bapt
Sponsored by: The FreeBSD Foundation

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

10 years agoMFC of 263041, tzdata2014a:
edwin [Tue, 11 Mar 2014 20:34:29 +0000 (20:34 +0000)]
MFC of 263041, tzdata2014a:

- Fix historical info about asia/Zion, Ukraine
- Fiji starts DST at 02:00 instead of 03:00
- Turkey will move to DST at 31 March this year.

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

10 years agoMFC: r241737,r246790,r247060,r247841,r248033,r248133,r255468,r256450,r256770
bapt [Tue, 11 Mar 2014 18:15:05 +0000 (18:15 +0000)]
MFC: r241737,r246790,r247060,r247841,r248033,r248133,r255468,r256450,r256770
     r256971,r256978,r257051,r257142,r257145,r257146,r257147,r257148,r257149
     r257158,r257193,r257377,r257378,r257400,r257505,r257668,r257701,r257945
     r258020,r258226,r258348,r258550,r259266,r259773,r259774,r259775,r262400
     r262401,r262419

Sync pkg(7) with head:
- signature checking
- respecting and reading repository configurations
- support pkg bootstrap -f

Direct modifications:
- Support old libarchive
- Support old openssl API
- Define non yet existing elf macros

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

10 years agoMFC: r262398,r262399,r262410,r262975
bapt [Tue, 11 Mar 2014 16:24:54 +0000 (16:24 +0000)]
MFC: r262398,r262399,r262410,r262975

Import libucl into head

UCL is heavily infused by nginx configuration as the example of a convenient
configuration system. However, UCL is fully compatible with JSON format and is
able to parse json files.

UCL is used by pkg(8) for its configuration file as well for the manifest format
in packages, it will be used in base for the pkg boostrap (signature checking
and configuration file parsing.)

libucl has been developped and is maintained by vsevolod@

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

10 years agoMFH (r251810): fix installation from read-only .OBJDIR
des [Tue, 11 Mar 2014 16:13:03 +0000 (16:13 +0000)]
MFH (r251810): fix installation from read-only .OBJDIR
MFH (r255384): add PRIVATELIB for internal-use shred libraries
MFH (r255385, r255413): add a stock libmap32.conf
MFH (r255765): always support directory mapping; rewrite libmap man page

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

10 years agoMFC 261030:
jhb [Tue, 11 Mar 2014 15:28:41 +0000 (15:28 +0000)]
MFC 261030:
Similar to cap_mkdb(1), add endianness support to services_mkdb(1)
to support cross-builds once this is invoked during releases.

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

10 years agoMFC: r257145,r257147,r257150,r257159,r257164,r257168,r257344,r257667,r257668,
bapt [Tue, 11 Mar 2014 14:48:44 +0000 (14:48 +0000)]
MFC: r257145,r257147,r257150,r257159,r257164,r257168,r257344,r257667,r257668,
     r258227,r260605

Add default configuration for FreeBSD official pkg(8) repositories
Add fingerprint for the trusted keys

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

10 years agoMFC 261243:
jhb [Tue, 11 Mar 2014 14:33:42 +0000 (14:33 +0000)]
MFC 261243:
Some BIOSes incorrectly use standard memory resource ranges to list
the memory ranges that they decode for downstream devices rather than
creating ResourceProducer range resource entries.  The result is that
we allocate the full range to the PCI root bridge device causing
allocations in child devices to all fail.

As a workaround, ignore any standard memory resources on a PCI root
bridge device.  It is normal for a PCI root bridge to allocate an I/O
resource for the I/O ports used for PCI config access, but I have not
seen any PCI root bridges that legitimately allocate a memory resource.

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

10 years agoMFC r262020:
jhay [Tue, 11 Mar 2014 13:03:05 +0000 (13:03 +0000)]
MFC r262020:

Make it possible to use the env kernel config file option for AVILA
and CAMBRIA boards that does not use loader to load the kernel. This
is basically how it was done for i386. This way tunables can also be
set. For example in config file:

env "/conf/AVILA.env"

And in AVILA.env:

vfs.unmapped_buf_allowed=0

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

10 years agoMFC r262036:
jhay [Tue, 11 Mar 2014 12:24:19 +0000 (12:24 +0000)]
MFC r262036:

etcupdate should use the src tree from where the release is built, not
the default (/usr/src) tree.

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

10 years agoMFC TTM, a memory manager used by video drivers
dumbbell [Mon, 10 Mar 2014 23:16:19 +0000 (23:16 +0000)]
MFC TTM, a memory manager used by video drivers

This is the last step before the merge of the Radeon KMS driver. Other
changes to TTM will be merged with radeonkms.

The following revisions were merged in this single commit:

r247835:
  Import the preliminary port of the TTM.

  The early commit is done to facilitate the off-tree work on the
  porting of the Radeon driver.

  Sponsored by: The FreeBSD Foundation
  Debugged and tested by:     dumbbell
  MFC after: 1 month

r247848:
  Fix build with gcc, remove redundand declarations.

  Reported and tested by: gjb
  MFC after: 1 month

r247849:
  Fix build with gcc, do not use unnamed union.

  Reported and tested by: gjb
  MFC after: 1 month

r248060:
  drm: Fix a call to free(9) with an incorrect malloc type

  While here, the call to free(9) is moved to drm_global.c, near the
  initial malloc(9).

  Reviewed by: Konstantin Belousov (kib@)

r248657:
  drm/ttm: Fix TTM buffer object refcount

  This fixes memory leaks in the radeonkms driver.

  Reviewed by: Konstantin Belousov (kib@)
  Tested by: J.R. Oldroyd <jr@opal.com>

r248661:
  drm/ttm: Explain why we don't need to acquire a ref in ttm_bo_vm_ctor()

r248663:
  drm/ttm: Fix a typo: s/pTTM]/[TTM]/

r248666:
  Do not call malloc(M_WAITOK) while bodev->fence_lock mutex is
  held. The ttm_buffer_object_transfer() does not need the mutex locked
  at all, except for the call to the driver sync_obj_ref() method.

  Reported and tested by: dumbbell
  MFC after:   2 weeks

r252864:
  Remove unneeded page lock around vm_page_insert().

  Submitted by: alc

r253710:
  MFgem r251960: re-check the mgt device object for the requested page
  after the object was relocked.

  Tested by: dumbbell
  Sponsored by: The FreeBSD Foundation
  MFC after: 1 week

r254822:
  drm: In drm_mmap_single, try ttm_bo_mmap_single() before drm_gem_mmap_single()

  In drivers such as the Radeon driver, the DRIVER_GEM features flag is
  set but TTM is used to mmap buffer object.

r254858:
  drm: Add missing bits to drmP.h, required by the Radeon driver

  Some of the FreeBSD-specific definitions are moved to drm_os_freebsd.h.
  But there's still work to do to clean it up and reduce the diff with
  Linux' drmP.h.

r254860:
  drm: Update drm_atomic.h, now that projects/atomic64 is in HEAD

  Submitted by: jkim@

r254861:
  drm/ttm: Import Linux commit 63d0a4195560362e2e00a3ad38fc331d34e1da9b

  Author: Maarten Lankhorst <maarten.lankhorst@canonical.com>
  Date:   Tue Jan 15 14:56:37 2013 +0100

      drm/ttm: remove lru_lock around ttm_bo_reserve

      There should no longer be assumptions that reserve will always succeed
      with the lru lock held, so we can safely break the whole atomic
      reserve/lru thing. As a bonus this fixes most lockdep annotations for
      reservations.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Reviewed-by: Jerome Glisse <jglisse@redhat.com>
r254862:
  drm/ttm: Import Linux commit 7a1863084c9d90ce4b67d645bf9b0f1612e68f62

  Author: Maarten Lankhorst <maarten.lankhorst@canonical.com>
  Date:   Tue Jan 15 14:56:48 2013 +0100

      drm/ttm: cleanup ttm_eu_reserve_buffers handling

      With the lru lock no longer required for protecting reservations we
      can just do a ttm_bo_reserve_nolru on -EBUSY, and handle all errors
      in a single path.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Reviewed-by: Jerome Glisse <jglisse@redhat.com>
r254863:
  drm/ttm: Import Linux commit 5e45d7dfd74100d622f9cdc70bfd1f9fae1671de

  Author: Maarten Lankhorst <maarten.lankhorst@canonical.com>
  Date:   Tue Jan 15 14:57:05 2013 +0100

      drm/ttm: add ttm_bo_reserve_slowpath

      Instead of dropping everything, waiting for the bo to be unreserved
      and trying over, a better strategy would be to do a blocking wait.

      This can be mapped a lot better to a mutex_lock-like call.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Reviewed-by: Jerome Glisse <jglisse@redhat.com>
  Approved by: kib@

r254864:
  drm/ttm: Import Linux commit f2d476a110bc24fde008698ae9018c99e803e25c

  Author: Maarten Lankhorst <maarten.lankhorst@canonical.com>
  Date:   Tue Jan 15 14:57:10 2013 +0100

      drm/ttm: use ttm_bo_reserve_slowpath_nolru in ttm_eu_reserve_buffers, v2

      This requires re-use of the seqno, which increases fairness slightly.
      Instead of spinning with a new seqno every time we keep the current one,
      but still drop all other reservations we hold. Only when we succeed,
      we try to get back our other reservations again.

      This should increase fairness slightly as well.

      Changes since v1:
       - Increase val_seq before calling ttm_bo_reserve_slowpath_nolru and
 retrying to take all entries to prevent a race.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Reviewed-by: Jerome Glisse <jglisse@redhat.com>
  Approved by: kib@

r254865:
  drm/ttm: Import Linux commit cc4c0c4de3c775be22072ec3251f2e581b63d9a0

  Author: Maarten Lankhorst <maarten.lankhorst@canonical.com>
  Date:   Tue Jan 15 14:57:28 2013 +0100

      drm/ttm: unexport ttm_bo_wait_unreserved

      All legitimate users of this function outside ttm_bo.c are gone, now
      it's only an implementation detail.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Reviewed-by: Jerome Glisse <jglisse@redhat.com>
  Approved by: kib@

r254866:
  drm/ttm: Import Linux commit 630541863b29f88c7ab34e647758344e4cd1eafd

  Author: Dave Airlie <airlied@gmail.com>
  Date:   Wed Jan 16 14:25:44 2013 +1000

      ttm: don't destroy old mm_node on memcpy failure

      When we are using memcpy to move objects around, and we fail to memcpy
      due to lack of memory to populate or failure to finish the copy, we don't
      want to destroy the mm_node that has been copied into old_copy.

      While working on a new kms driver that uses memcpy, if I overallocated bo's
      up to the memory limits, and eviction failed, then machine would oops soon
      after due to having an active bo with an already freed drm_mm embedded in it,
      freeing it a second time didn't end well.

Reviewed-by: Jerome Glisse <jglisse@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
  Approved by: kib@

r254867:
  drm/ttm: Import Linux commit 014b34409fb2015f63663b6cafdf557fdf289628

  Author: Dave Airlie <airlied@gmail.com>
  Date:   Wed Jan 16 15:58:34 2013 +1000

      ttm: on move memory failure don't leave a node dangling

      if we have a move notify callback, when moving fails, we call move notify
      the opposite way around, however this ends up with *mem containing the mm_node
      from the bo, which means we double free it. This is a follow on to the previous
      fix.

Reviewed-by: Jerome Glisse <jglisse@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
  Approved by: kib@

r254868:
  drm/ttm: Import Linux commit ff7c60c580d9722f820d85c9c58ca55ecc1ee7c4

  Author: Daniel Vetter <daniel.vetter@ffwll.ch>
  Date:   Mon Jan 14 15:08:14 2013 +0100

      drm/ttm: fix fence locking in ttm_buffer_object_transfer, 2nd try

      This fixes up

      commit e8e89622ed361c46bf90ba4828e685a8b603f7e5
      Author: Daniel Vetter <daniel.vetter@ffwll.ch>
      Date:   Tue Dec 18 22:25:11 2012 +0100

  drm/ttm: fix fence locking in ttm_buffer_object_transfer

      which leaves behind a might_sleep in atomic context, since the
      fence_lock spinlock is held over a kmalloc(GFP_KERNEL) call. The fix
      is to revert the above commit and only take the lock where we need it,
      around the call to ->sync_obj_ref.

      v2: Fixup things noticed by Maarten Lankhorst:
      - Brown paper bag locking bug.
      - No need for kzalloc if we clear the entire thing on the next line.
      - check for bo->sync_obj (totally unlikely race, but still someone
else could have snuck in) and clear fbo->sync_obj if it's cleared
already.

Reported-by: Dave Airlie <airlied@gmail.com>
Cc: Jerome Glisse <jglisse@redhat.com>
Cc: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
  Approved by: kib@

r254870:
  drm/ttm: Make ttm_bo_wait() call uninterruptible in page fault handler

  This fixes a crash where a SIGLALRM, heavily used by X.Org, would
  interrupt the wait, causing the page fault to fail and the "Xorg"
  process to receive a SIGSEGV.

  Approved by: kib@

r254871:
  drm/ttm: Fix style errors

r254873:
  drm/ttm: When removing a range of pages from a pool, remove all of them

  Submitted by: Mark Kettenis and Jonathan Gray from OpenBSD
  Approved by: kib@

r254874:
  drm/ttm: Improve comment in ttm_bo_vm_ctor() about lack of ref acquisition

  Approved by: kib@

r254875:
  ttm: "to_page->valid = VM_PAGE_BITS_ALL" before vm_page_dirty(to_page)

  Approved by; kib@

r254876:
  drm/ttm: Fix unmap of buffer object

  Add a new ttm_bo_release_mmap() function to unmap pages in a
  vm_object_t. Pages are freed when the buffer object is later released.

  This function is called in ttm_bo_unmap_virtual_locked(), replacing
  Linux' unmap_mapping_range(). In particular this is called when a buffer
  object is about to be moved, so that its mapping is invalidated.

  However, we don't use this function in ttm_bo_vm_dtor(), because the
  vm_object_t is already marked as OBJ_DEAD and the pages will be
  unmapped.

  Approved by: kib@

r254877:
  drm/ttm: Fix style in ttm_bo_release_mmap()

r254878:
  drm/ttm: Fix a reversed condition and add missing locks

  This allows to run OpenGL applications on at least two test machines
  with the Radeon driver.

  Approved by: kib@

r254879:
  drm/ttm: Remove unused VM_ALLOC_DMA32 define

r254880:
  drm: Use the new drm_atomic.h, following the merge of projects/atomic64

  Submitted by: jkim@

r259612:
  ttm_bo_vm_lookup_rb: actually make use of the red-black tree

  Previously the code would just iterate over the whole tree as if it were
  just a list.

  Without this change I would observe X server becoming more and more
  jerky over time.

  MFC after: 5 days

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

10 years agoMFC: r262746, r262748, r262750, r262752
jkim [Mon, 10 Mar 2014 20:47:24 +0000 (20:47 +0000)]
MFC: r262746, r262748, r262750, r262752

Move fpusave() wrapper for suspend hander to sys/amd64/amd64/fpu.c.

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

10 years agoMFC r261535:
markj [Mon, 10 Mar 2014 02:38:41 +0000 (02:38 +0000)]
MFC r261535:
Add support for MegaRAID Fury cards. The main change needed to boot from a
9341-4i controller was to ensure that scatter/gather lists are ended with
an end-of-list marker. Both the mrsas and Linux megaraid_sas drivers use
this marker with Invader cards as well, so we do the same thing, though
it is apparently not strictly necessary.

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

10 years agoMFC r262805:
dim [Sun, 9 Mar 2014 21:02:23 +0000 (21:02 +0000)]
MFC r262805:

Pull in r199848 from upstream libc++ trunk:

  Const qualify __mem_fn call operator

  QOI improvement.

  Differential Revision: http://llvm-reviews.chandlerc.com/D2059

This should help with building recent versions of Mesa.  See also:
https://bugs.freedesktop.org/show_bug.cgi?id=75505

Reported by: dumbbell

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

10 years agoMFC r262869:
pfg [Sun, 9 Mar 2014 04:17:04 +0000 (04:17 +0000)]
MFC r262869:

ext2fs: Fix a bug when sorting htree entries.

This a typo introduced when bringing the original code from NetBSD.

Reported by: Mike Ma

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

10 years agoMFC vm_page_alloc_contig()
dumbbell [Sat, 8 Mar 2014 20:31:04 +0000 (20:31 +0000)]
MFC vm_page_alloc_contig()

This function will be used by TTM, a memory manager used by the Radeon
KMS driver.

Compared to HEAD, the type of the "boundary" argument to several functions
is left as "unsigned long" (instead of "vm_paddr_t" in HEAD) to prevent an
API change in a stable branch.

The following revisions were merged in this single commit:

MFC r226928:
  Eliminate vm_phys_bootstrap_alloc().  It was a failed attempt at
  eliminating duplicated code in the various pmap implementations.

  Micro-optimize vm_phys_free_pages().

  Introduce vm_phys_free_contig().  It is fast routine for freeing an
  arbitrary number of physically contiguous pages.  In particular, it
  doesn't require the number of pages to be a power of two.

  Use "u_long" instead of "unsigned long".

  Bruce Evans (bde@) has convinced me that the "boundary" parameters
  to kmem_alloc_contig(), vm_phys_alloc_contig(), and
  vm_reserv_reclaim_contig() should be of type "vm_paddr_t" and not
  "u_long".  Make this change.

MFC r227012:
  Add support for VM_ALLOC_WIRED and VM_ALLOC_ZERO to vm_page_alloc_freelist()
  and use these new options in the mips pmap.

  Wake up the page daemon in vm_page_alloc_freelist() if the number of free
  and cached pages becomes too low.

  Tidy up vm_page_alloc_init().  In particular, add a comment about an
  important restriction on its use.

  Tested by: jchandra@

MFC r227072:
  Simplify the implementation of the failure case in kmem_alloc_attr().

MFC r227127:
  Wake up the page daemon in vm_page_alloc_freelist() if it couldn't
  allocate the requested page because too few pages are cached or free.

  Document the VM_ALLOC_COUNT() option to vm_page_alloc() and
  vm_page_alloc_freelist().

  Make style changes to vm_page_alloc() and vm_page_alloc_freelist(),
  such as using a variable name that more closely corresponds to the
  comments.

MFC r227568:
  Refactor the code that performs physically contiguous memory allocation,
  yielding a new public interface, vm_page_alloc_contig().  This new function
  addresses some of the limitations of the current interfaces, contigmalloc()
  and kmem_alloc_contig().  For example, the physically contiguous memory that
  is allocated with those interfaces can only be allocated to the kernel vm
  object and must be mapped into the kernel virtual address space.  It also
  provides functionality that vm_phys_alloc_contig() doesn't, such as wiring
  the returned pages.  Moreover, unlike that function, it respects the low
  water marks on the paging queues and wakes up the page daemon when
  necessary.  That said, at present, this new function can't be applied to all
  types of vm objects.  However, that restriction will be eliminated in the
  coming weeks.

  From a design standpoint, this change also addresses an inconsistency
  between vm_phys_alloc_contig() and the other vm_phys_alloc*() functions.
  Specifically, vm_phys_alloc_contig() manipulated vm_page fields that other
  functions in vm/vm_phys.c didn't.  Moreover, vm_phys_alloc_contig() knew
  about vnodes and reservations.  Now, vm_page_alloc_contig() is responsible
  for these things.

  Reviewed by:         kib
  Discussed with: jhb

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

10 years agoMFC: r262333
brueffer [Sat, 8 Mar 2014 12:25:45 +0000 (12:25 +0000)]
MFC: r262333

Simplify the way the end of a singly linked list is followed (for adding
items), so it is more obvious that we aren't going to indirect through
a NULL pointer.

PR:             144723
Submitted by:   Garrett Cooper <yaneurabeya at gmail.com>
Obtained from:  NetBSD r1.19

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

10 years agoMFC: r262603
brueffer [Fri, 7 Mar 2014 12:21:51 +0000 (12:21 +0000)]
MFC: r262603

mdoc cleanup.

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

10 years agoMFC r260772:
gjb [Fri, 7 Mar 2014 00:38:29 +0000 (00:38 +0000)]
MFC r260772:
  Update the pkg-stage target to be more compatible with
  pkg-1.2:

  - Add a release-dvd.conf pkg(8) configuration file to override
    the default FreeBSD.conf configuration.
  - Remove architecture-specific pkg-stage.conf files, consolidate,
    and move their contents to scripts/pkg-stage.sh.
  - Use 'pkg -vv' to determine the ABI, which is used as the
    cache directory.

  Prior to these changes, it would be possible for pkg-stage to
  fetch conflicting binary packages from multiple repositories.

NOTE:  WITH_DVD=1 is broken on stable/9, pending updates to the
pkg(7) code.  The 'dvdrom' target on stable/9 is broken as-is,
so there is no harm merging this change now.  I think.

Sponsored by: The FreeBSD Foundation

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

10 years agoMFC r258305, r258770, r259400, r259426:
gjb [Fri, 7 Mar 2014 00:28:11 +0000 (00:28 +0000)]
MFC r258305, r258770, r259400, r259426:

r258305:
  Use the IMAGES variable to determine which image files to
  remove as part of 'make -C /usr/src/release clean'.

r258770 (hrs):
  Add NOPKG to disable pkg-stage.

r259400:
  Reduce disc1.iso size by 74MB by removing lib32 libraries,
  sendmail, and atf.

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.

Sponsored by: The FreeBSD Foundation

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

10 years agoMFC r225817 (des):
gjb [Thu, 6 Mar 2014 23:49:46 +0000 (23:49 +0000)]
MFC r225817 (des):
  Don't force active mode FTP.

Sponsored by: The FreeBSD Foundation

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

10 years agoRecord mergeinfo for r225757.
gjb [Thu, 6 Mar 2014 23:42:50 +0000 (23:42 +0000)]
Record mergeinfo for r225757.

Sponsored by: The FreeBSD Foundation

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

10 years agoMFC r226891:
dumbbell [Thu, 6 Mar 2014 23:17:38 +0000 (23:17 +0000)]
MFC r226891:

Use "u_long" instead of "unsigned long".

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

10 years agoMFC r226848:
dumbbell [Thu, 6 Mar 2014 23:06:47 +0000 (23:06 +0000)]
MFC r226848:

Tidy up the comment at the head of vm_page_alloc, and mention that the
returned page has the flag VPO_BUSY set.

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

10 years agoMFC r226824:
dumbbell [Thu, 6 Mar 2014 18:50:35 +0000 (18:50 +0000)]
MFC r226824:

contigmalloc(9) and contigfree(9) are now implemented in terms of other
more general VM system interfaces.  So, their implementation can now
reside in kern_malloc.c alongside the other functions that are declared
in malloc.h.

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

10 years agoMFC r262575:
mav [Thu, 6 Mar 2014 14:32:55 +0000 (14:32 +0000)]
MFC r262575:
Restore SIM freeze/release match, broken at r253549.

This fixes problem with SIM left in frozen state after reinit, for example,
after firmware update.

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

10 years agoMFC r262553:
mav [Thu, 6 Mar 2014 13:25:21 +0000 (13:25 +0000)]
MFC r262553:
Pass proper pointer to bus_dmamem_free() in mps_iocfacts_free().

Passing there pointer into the middle of allocated area caused kernel
panic during reinit, for example, after firmware upgrade.

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

10 years agoMFC r261832-261834:
zeising [Thu, 6 Mar 2014 10:26:25 +0000 (10:26 +0000)]
MFC r261832-261834:

r261832:
    Add cross references between rc.conf(5) and jail.conf(5).

r261833:
    Add commas (,) to the list in the SEE ALSO section, to match most
    other manuals.

r261834:
    Bump .Dd forgotten in r261832.

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

10 years agoMFC r254623:
dumbbell [Thu, 6 Mar 2014 07:42:27 +0000 (07:42 +0000)]
MFC r254623:

Reimplement atomic operations on PDEs and PTEs in pmap.h.  This change
significantly reduces duplicate code and make it easier to read.

Note: This merge fixes the build of i386's PAE kernel, broken in r262807.

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

10 years agoMFC r254610, r254611, r254617, r254620:
dumbbell [Wed, 5 Mar 2014 21:33:11 +0000 (21:33 +0000)]
MFC r254610, r254611, r254617, r254620:

Implement atomic_swap() and atomic_testandset().
Implement atomic_cmpset_64() and atomic_swap_64() for i386.

The following revisions were merged at the same time, to avoid build
breakage:
    o  r256118
    o  r256119
    o  r256131

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

10 years agoMFC r253102:
dumbbell [Wed, 5 Mar 2014 19:48:47 +0000 (19:48 +0000)]
MFC r253102:

Remove redundant definitions to appease tinderbox.

Note: This MFC is required by a future merge of changes to amd64's and
i386's atomic.h.

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

10 years agoMFC r261283:
dim [Wed, 5 Mar 2014 19:30:36 +0000 (19:30 +0000)]
MFC r261283:

Import libc++ 3.4 release.  This contains a lot of bugfixes, and some
preliminary support for C++1y.

MFC r261604:

HEAD is not buildable for the past day.  Commit a 'quick fix' in order to permit
buildworld to complete.

Reviewed by: theraven

MFC r261608:

Apply a cleaner solution for the sign warnings that can occur when
compiling libc++'s <locale> header with -Wsystem-headers on.

This has also been submitted upstream.

Reported by: asomers

MFC r261801:

An ABI incompatibility crept into the libc++ 3.4 import in r261283.  It
was caused by upstream libc++ commit r194536, which aimed to make the
headers more standards-compliant, by making std::pair's copy constructor
trivial.  Unfortunately, this could cause certain C++ applications using
shared libraries built against the previous version of libc++ to crash.

Fix the ABI incompatibility by making std::pair's copy constructor
non-trivial again.

Please note: Any C++ applications or shared libraries built with libc++
between r261283 and this revision should be recompiled.

Reported by: stefanf

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

10 years agoMFC r262513:
gjb [Wed, 5 Mar 2014 17:23:38 +0000 (17:23 +0000)]
MFC r262513:
 Update release/release.conf.sample to reflect changes in r262509.

Sponsored by: The FreeBSD Foundation

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

10 years agoMFC: r262494
brueffer [Wed, 5 Mar 2014 13:28:02 +0000 (13:28 +0000)]
MFC: r262494

Rough cleanup (new sentence -> new line, grammar, spelling, mdoc).
This could use more work.

PR:             187035 (in part)
Submitted by:   Bjorn Heidotting

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

10 years agoMFC r262678;
pfg [Wed, 5 Mar 2014 04:27:15 +0000 (04:27 +0000)]
MFC r262678;
ufs: small formatting fixes.

Cleanup some extra space.
Use of tabs vs. spaces.
No functional change.

Reviewed by: mckusick

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

10 years agoMFC r262499, r262505, r262507, r262509:
gjb [Wed, 5 Mar 2014 00:48:11 +0000 (00:48 +0000)]
MFC r262499, r262505, r262507, r262509:

r262499:
  release.sh:
  - Add a VCSCMD variable that defaults to 'svn checkout',
    and update places 'svn co' is used directly.
  - After sourcing a configuration file, prefix SRCBRANCH,
    PORTBRANCH, and DOCBRANCH with the SVNROOT.
  - Properly capitalize 'FreeBSD.org' in the default SVNROOT.
  - Update Copyright.

  release.conf.sample:
  - Add an example to use git instead of svn, by nullifying
    SVNROOT, and setting SRCBRANCH, DOCBRANCH, and PORTBRANCH
    to the URL fo a git repository.

  release.7:
  - Document VCSCMD.

r262505:
  In release/Makefile, remove exclusion of CVS directories in the
  src/ and ports/ distributions.

  While I am thinking about it, exclude .git directories for src/
  and ports/, as somewhat of a followup to r262499.

r262507:
  Chase r262505, and remove CVS exclusion from picobsd builds.

r262509:
  Rework how WORLD_FLAGS and KERNEL_FLAGS are set, to remove an
  unnecessary expr(1) call.

Sponsored by: The FreeBSD Foundation

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

10 years agoMFC r254379:
dumbbell [Tue, 4 Mar 2014 20:21:43 +0000 (20:21 +0000)]
MFC r254379:

Avoid potential redefinition of the macro.

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

10 years agoMFC r232365:
dumbbell [Tue, 4 Mar 2014 18:27:00 +0000 (18:27 +0000)]
MFC r232365:

Provide pre/post transfer method callbacks for icbbb
clients.

These are helful when making certain drivers work on both Linux
and FreeBSD without changing the code flow too much.

Reviewed by: kib, wlosh
Approved by: kan@

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

10 years agoMFC r262623, r262667:
pfg [Tue, 4 Mar 2014 03:14:09 +0000 (03:14 +0000)]
MFC r262623, r262667:

ext2fs: use of tab vs spaces.

Consistently use a single tab after a #define as mentioned in style(9).
Use tabs instead of space for indenting.
Fix a typo: "hash_vesion".

No functional change.

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

10 years agoMFV 262445:
erwin [Mon, 3 Mar 2014 09:18:19 +0000 (09:18 +0000)]
MFV 262445:
Update BIND to 9.9.5

Release note:
https://lists.isc.org/pipermail/bind-announce/2013-September/000871.html
https://lists.isc.org/pipermail/bind-announce/2014-January/000896.html

Note this is a commit straight to stable as BIND no longer exists in head.

Sponsored by: DK Hostmaster A/S

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

10 years agoMFC: r262574
brueffer [Sun, 2 Mar 2014 12:13:54 +0000 (12:13 +0000)]
MFC: r262574

Add tws(4) to the hardware notes.

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

10 years agoMFC r261068
jhibbits [Sun, 2 Mar 2014 00:20:00 +0000 (00:20 +0000)]
MFC r261068

Properly sort the arguments to mtx_init(9).

PR: misc/186020
Submitted by: alfred

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

10 years agoMFC r262472:
dim [Fri, 28 Feb 2014 20:31:07 +0000 (20:31 +0000)]
MFC r262472:

Make sure a for loop in fire_alloc_msix() terminates, by making the loop
counter signed.

Reviewed by: marius

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

10 years agoMFC r262471:
dim [Fri, 28 Feb 2014 20:22:48 +0000 (20:22 +0000)]
MFC r262471:

In sys/sparc64/sparc64/spitfire.c, prevent signed shift overflow by
casting to the appropriate type.  (Note this fix cannot be done in
sys/sparc64/sparc64/spitfire.c, since that file is also included by
assembly source files.)

Reviewed by: marius

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

10 years agoMFC r262465:
kevlo [Fri, 28 Feb 2014 16:11:43 +0000 (16:11 +0000)]
MFC r262465:

Add a flag to run's device list which uses a standard scsi eject.
The flag indicates that the mcu doesn't need to load firmware.

Tested by: Alex Deiter <alex dot deiter at gmail.com>, myself
Tested on: ASUS USB-N66

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

10 years agoMFC r262142:
rodrigc [Fri, 28 Feb 2014 01:35:24 +0000 (01:35 +0000)]
MFC r262142:

   In ue_attach_post_task(), initialize curvnet to vnet0 before calling if_attach().
   Before this patch, curvnet was NULL.
   When the VIMAGE kernel option is enabled, this eliminates
   kernel panics when USB ethernet devices are plugged in.

PR: 183835
Submitted by: Hiroo Oono <hiroo.ono at gmail dot com>

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

10 years agoMFC: r262296
brueffer [Fri, 28 Feb 2014 00:44:41 +0000 (00:44 +0000)]
MFC: r262296

Match the correct variable to the variable description.

PR: 121173
Submitted by: Thomas Mueller <tmueller at sysgo.com>

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

10 years agoMFC r257472
hiren [Thu, 27 Feb 2014 22:36:16 +0000 (22:36 +0000)]
MFC r257472

Rate limit (to once per minute) "Listen queue overflow" message in
sonewconn().

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

10 years agoMFC r262346:
pfg [Thu, 27 Feb 2014 16:07:12 +0000 (16:07 +0000)]
MFC r262346:
ext2fs: fully enable ext4 read-only support.

The ext4 developers tend to tag Ext4-specific flags as
"incompatible" even when such features are not relevant for
read-only support.  This is a consequence of the process
though which this filesystem is implemented without design
and the fact that some new features are not extensible to
ext2/3.

Organize the features according to what we support and sort
them so that we can now read-only mount filesystems with
some features that may be found in newly formatted ext4 fs.

Submitted by: Zheng Liu

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

10 years agoMFC r262277:
davidxu [Thu, 27 Feb 2014 02:41:41 +0000 (02:41 +0000)]
MFC r262277:

malloc_aligned() may not leave enough space for pointer to allocated memory,
saving the pointer will overwrite bytes belongs to another memory block
unexpectly, to fix the problem, use (allocated address + sizeof(void *)) as
initial value, and slip to next aligned address, so maximum extra bytes is
sizeof(void *) + align - 1.

Tested by: Andre Albsmeier < mail at ma17 dot ata dot myota dot orgndre >

MFC r262334:

Increase alignment to size of pointer if the alignment is too small.
Some modules do not align data at least to size of pointer, they uses a
smaller alignment, but our pointer should be aligned to its native
boundary, otherwise on some platforms, hardware alignment checking
will cause bus error.

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

10 years agoMFC: r261773
brueffer [Tue, 25 Feb 2014 07:57:17 +0000 (07:57 +0000)]
MFC: r261773

In acline_init(), initialize ac_line to SRC_UNKNOWN.  Previously
this could lead to the -n option effectively being ignored (in case
ac_line happened to be 0 aka SRC_AC), or other undefined behaviour.

PR: 169779
Submitted by: Alex Gonzalez <loox at e-shell.com>
Reviewed by: jhb

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

10 years agoMFC r262467: sh: Add -h option to SYNOPSIS
daichi [Tue, 25 Feb 2014 04:19:15 +0000 (04:19 +0000)]
MFC r262467: sh: Add -h option to SYNOPSIS

Reviewed by: jilles

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

10 years agoMFC r262310:
dim [Mon, 24 Feb 2014 21:22:44 +0000 (21:22 +0000)]
MFC r262310:

Move the part in bsd.own.mk that sets -Wno-c++11-extensions for clang to
bsd.sys.mk, where it really belongs.  This also causes the flag to get
added when clang is *not* the default system compiler, but is still
used, e.g. by setting WITH_CLANG_IS_CC manually.

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

10 years agoMFC r262125:
dim [Mon, 24 Feb 2014 20:29:39 +0000 (20:29 +0000)]
MFC r262125:

In sys/dev/usb/controller/uss820dci.c, similar to r261977, fix a warning
about uss820dci_odevd being unused, by adding it to the part that
handles getting descriptors.

Reported by: loos
Reviewed by: hselasky

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

10 years agoMFC r261774 by feld:
eadler [Mon, 24 Feb 2014 17:01:06 +0000 (17:01 +0000)]
MFC r261774 by feld:

Add caveat to zpool manpage indicating that we do not automatically activate
hot spares. This should be MFC'd to all STABLE branches.

Upon the availability of zfsd, the zpool manpage on relevant branches should
be updated to remove this caveat and document hot spare's reliance on zfsd.

Requested by: feld

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

10 years agoMFC: r261531
marius [Sun, 23 Feb 2014 21:08:48 +0000 (21:08 +0000)]
MFC: r261531

- Implement the RX EARLYOFF and RXDV GATED bits as done by RealTek's Linux
  driver as of version 8.037.00 for RTL8168{E-VL,EP,F,G,GU} and RTL8411B.
  This makes reception of packets work with the RTL8168G (HW rev. 0x4c000000)
  in my Shuttle DS47.
- Consistently use RL_MSI_MESSAGES.
In joint forces with: yongari

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

10 years agoMFC: r261529
marius [Sun, 23 Feb 2014 21:03:32 +0000 (21:03 +0000)]
MFC: r261529

Try to make the style used here consistent.

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

10 years agoMFC: r261549
brueffer [Sun, 23 Feb 2014 20:14:38 +0000 (20:14 +0000)]
MFC: r261549

Add a manpage for the urndis driver.

Obtained from: OpenBSD

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

10 years agoMFC r261872:
hselasky [Sun, 23 Feb 2014 13:37:45 +0000 (13:37 +0000)]
MFC r261872:
Fix minor logical error in the XHCI driver. Set correct SETUP packet
direction value.

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

10 years agoMFC r261827:
hselasky [Sun, 23 Feb 2014 13:31:39 +0000 (13:31 +0000)]
MFC r261827:
- Remove not needed definitions from driver.
- Get USB input report length from HID descriptor.
- Use 1 finger TAP for devices which has no integrated button.
- Move data buffer to softc instead of allocating it.

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

10 years agoMFC r261981:
hselasky [Sun, 23 Feb 2014 13:27:19 +0000 (13:27 +0000)]
MFC r261981:
Add new PCI ID for hardware which needs port routing for USB 3.0.

PR: usb/186811

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

10 years agoMFC r261541, r261543 and r261544:
hselasky [Sun, 23 Feb 2014 13:20:08 +0000 (13:20 +0000)]
MFC r261541, r261543 and r261544:
Import USB RNDIS driver to FreeBSD from OpenBSD.
Useful for so-called USB tethering.
- Imported code from OpenBSD
- Adapted code to FreeBSD
- Removed some unused functions
- Fixed some buffer encoding and decoding issues
- Optimised data transport path a bit, by sending multiple packets at a time
- Increased receive buffer to 16K

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

10 years agoMFC r261795:
hselasky [Sun, 23 Feb 2014 13:08:18 +0000 (13:08 +0000)]
MFC r261795:
Issue doorbell twice before finally freeing the DMA descriptors. This
should fix DMA descriptor caching issues seen with the EHCI controller
found in Google Chromebook C720 during removal and insertion of USB
devices.

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

10 years agoMFC r261620: MFV r261619:
delphij [Sat, 22 Feb 2014 01:13:48 +0000 (01:13 +0000)]
MFC r261620: MFV r261619:

4574 get_clones_stat does not call zap_count in non-debug kernel

zap_count(...) is never called in non-DEBUG kernel.
As result "count" variable is always 0, and "goto fail" is always
reached.  This means get_clones_stat function never makes up list
of clones for "clones" properties.

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

10 years agoMFC r261618:
delphij [Sat, 22 Feb 2014 00:41:03 +0000 (00:41 +0000)]
MFC r261618:

In g_eli_crypto_hmac_init(), zero out after using the ipad buffer,
k_ipad.

Note that the two consumers in geli(4) are not affected by this
issue because the way the code is constructed and as such, we
believe there is no security impact with or without this change
with geli(4)'s usage.

Reported by: Serge van den Boom <serge vdboom.org>
Reviewed by: pjd

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

10 years agoMFC r261538:
mav [Fri, 21 Feb 2014 18:33:54 +0000 (18:33 +0000)]
MFC r261538:
Make CTL block backend return proper error code for operations unsupposed
by the underlying device.

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

10 years agoMFC: r261900
brueffer [Fri, 21 Feb 2014 09:26:51 +0000 (09:26 +0000)]
MFC: r261900

In chat_UpdateSet(), initialize the input buffer to prevent stale data
from previous timed out commands.

PR: 186530
Submitted by: Alexander Zagrebin <alexz at visp.ru>
Reviewed by: brian

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

10 years agoMFC: r261885
brueffer [Fri, 21 Feb 2014 09:21:02 +0000 (09:21 +0000)]
MFC: r261885

In sgetpwnam(), save and free pw_class like all other char members
of struct passwd.  This fixes spurious "login_getclass: unknown class"
errors.

PR: 186439
Submitted by: UEMURA Tetsuya <t_uemura at macome.co.jp>

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

10 years agoMFC r261835:
ae [Thu, 20 Feb 2014 21:02:24 +0000 (21:02 +0000)]
MFC r261835:
  Drop packets to multicast address whose scop field contains the
  reserved value 0.

Sponsored by: Yandex LLC

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

10 years agoMFC: r261858
brueffer [Thu, 20 Feb 2014 08:58:05 +0000 (08:58 +0000)]
MFC: r261858

Fix a bug in be_uuid_dec(); it called le16dec() instead of be16dec(),
probably due to copy+pasting le_uuid_dec().

PR: 146588
Submitted by: Erwin Rol <erwin at erwinrol.com>
Reviewed by: marcel

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

10 years agomake this code compile with NOINET
luigi [Thu, 20 Feb 2014 04:50:13 +0000 (04:50 +0000)]
make this code compile with NOINET

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

10 years agoMFC r257883:
eadler [Wed, 19 Feb 2014 19:46:44 +0000 (19:46 +0000)]
MFC r257883:

Add support for SIIG x1 pci-e single parallel port card (JJ-E01211-S1)

PR: kern/182217

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

10 years agoMFC 261512,261514:
jhb [Wed, 19 Feb 2014 19:28:49 +0000 (19:28 +0000)]
MFC 261512,261514:
- Partially revert r52493 and change client side interval statistics to
  report the actual number of RPCs issued, not the theoretical number
  that would be issued if all caching was disabled.
- Use the DELTA() macro to tidy the server-side interval stats code a bit.

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

10 years agoMFC 261780:
jhb [Wed, 19 Feb 2014 19:11:14 +0000 (19:11 +0000)]
MFC 261780:
Expose OBJT_MGTDEVICE VM objects used for GEM/TTM with drm2 as an
explicit object type.

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

10 years agoMFC 261524,261526,261527:
jhb [Wed, 19 Feb 2014 18:34:47 +0000 (18:34 +0000)]
MFC 261524,261526,261527:
- Properly set the alignment flags when allocating the initial range for a
  BAR.  This only really matters when pci_do_realloc_bars is enabled and
  the initial allocation of a specific range fails.
- Simplify pci_reserve_map() by calling resource_list_reserve() to allocate
  the resource after creating a resource list entry rather than reimplementing
  it by hand.
- Add two tunables to ignore certain firmware-assigned resources.  These
  are mostly useful for debugging.
  - hw.pci.clear_bars ignores all firmware-assigned ranges for BARs when
    set.
  - hw.pci.clear_pcib ignores all firmware-assigned ranges for PCI-PCI
    bridge I/O windows when set.

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

10 years agoMFC 250691:
jhb [Wed, 19 Feb 2014 15:00:55 +0000 (15:00 +0000)]
MFC 250691:
Return one-based key so that user can check if the key is ever allocated
in the first place.

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

10 years agoMFC r261977:
dim [Wed, 19 Feb 2014 08:05:42 +0000 (08:05 +0000)]
MFC r261977:

In sys/dev/usb/controller/musb_otg.c, fix a warning about musbotg_odevd
being unused, by adding it to the part that handles getting descriptors.

Reviewed by: hselasky

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

10 years agoMFC r261916:
dim [Wed, 19 Feb 2014 07:59:50 +0000 (07:59 +0000)]
MFC r261916:

In sys/dev/xen/console/console.c, #if 0 an unused static function.

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

10 years agoMFC r261915:
dim [Wed, 19 Feb 2014 07:51:58 +0000 (07:51 +0000)]
MFC r261915:

Under sys/netpfil/ipfw, surround two IPv6-specific static functions with
#ifdef INET6, since they are unused when INET6 is disabled.

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

10 years agoMFC 261517,261520:
jhb [Tue, 18 Feb 2014 20:27:17 +0000 (20:27 +0000)]
MFC 261517,261520:
Convert the license on files where I am the sole copyright holder to
2 clause BSD licenses.

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

10 years agoMFC 261518:
jhb [Tue, 18 Feb 2014 20:16:32 +0000 (20:16 +0000)]
MFC 261518:
- Update a few places to account for va_copy().
- Create a separate 'return values' section and move some statements about
  return values to that section.
- Note that each invocation of va_start() and va_copy() must be paired with
  va_end() in the same function.

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

10 years agoMFC r259576: MFV r258923: 4188 assertion failed in dmu_tx_hold_free():
avg [Tue, 18 Feb 2014 15:45:02 +0000 (15:45 +0000)]
MFC r259576: MFV r258923: 4188 assertion failed in dmu_tx_hold_free():
dn_datablkshift != 0

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

10 years agoMFC r259052: Expose spa_asize_inflation
avg [Tue, 18 Feb 2014 15:38:43 +0000 (15:38 +0000)]
MFC r259052: Expose spa_asize_inflation

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

10 years agoMFC r258294: Fix ZFS deadlock when sending a snapshot which is mounted
avg [Tue, 18 Feb 2014 15:29:53 +0000 (15:29 +0000)]
MFC r258294: Fix ZFS deadlock when sending a snapshot which is mounted

MFC slacker: smh

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