]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/log
FreeBSD/stable/10.git
8 years agoMFC r296021 (by smh): Removed unused label and fix mutex_exit order
mav [Mon, 21 Mar 2016 00:09:56 +0000 (00:09 +0000)]
MFC r296021 (by smh): Removed unused label and fix mutex_exit order

Remove unused done label from zfs_setacl fixing PVS-Studio V729.

Fix mutex_exit order to mirror the mutex_enter order.

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

8 years agoMFC r295125: MFV r294821:
mav [Mon, 21 Mar 2016 00:07:56 +0000 (00:07 +0000)]
MFC r295125: MFV r294821:
6529 Properly handle updates of variably-sized SA entries.

Reviewed by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Ned Bass <bass6@llnl.gov>
Reviewed by: Tim Chase <tim@chase2k.com>
Approved by: Gordon Ross <gwr@nexenta.com>
Author: Andriy Gapon <avg@icyb.net.ua>

illumos/illumos-gate@e7e978b1f75353cb29673af9b35453c20c2827bf

During the update process in sa_modify_attrs(), the sizes of existing
variably-sized SA entries are obtained from sa_lengths[]. The case where
a variably-sized SA was being replaced neglected to increment the index
into sa_lengths[], so subsequent variable-length SAs would be rewritten
with the wrong length. This patch adds the missing increment operation
so all variably-sized SA entries are stored with their correct lengths.

Another problem was that index into attr_desc[] was increased even when
an attribute was removed. If that attribute was not the last attribute,
then the last attribute was lost.

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

8 years agoMFC r295047: MFV 295046:
mav [Mon, 21 Mar 2016 00:06:42 +0000 (00:06 +0000)]
MFC r295047: MFV 295046:
6358 A faulted pool with only unavailable vdevs triggers assertion
failure in libzfs

Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Andrew Stormont <andyjstormont@gmail.com>
Reviewed by: Serban Maduta <serban.maduta@gmail.com>
Approved by: Dan McDonald <danmcd@omniti.com>
Author: Dan Vatca <dan.vatca@gmail.com>

illumos/illumos-gate@b289d045e084af53efcc025255af8242e41f28fa

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

8 years agoMFC r294820: MFV r294819: 6495 Fix mutex leak in dmu_objset_find_dp
mav [Mon, 21 Mar 2016 00:04:53 +0000 (00:04 +0000)]
MFC r294820: MFV r294819: 6495 Fix mutex leak in dmu_objset_find_dp

Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Approved by: Albert Lee <trisk@omniti.com>
Author: Steven Hartland <steven.hartland@multiplay.co.uk>

illumos/illumos-gate@2bad22584defe4667f99737e3158d336e4dcca11

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

8 years agoMFC r294817: MFV r294816:
mav [Mon, 21 Mar 2016 00:03:55 +0000 (00:03 +0000)]
MFC r294817: MFV r294816:
4986 receiving replication stream fails if any snapshot exceeds refquota

Reviewed by: John Kennedy <john.kennedy@delphix.com>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Approved by: Gordon Ross <gordon.ross@nexenta.com>
Author: Dan McDonald <danmcd@omniti.com>

illumos/illumos-gate@5878fad70d76d8711f6608c1f80b0447601261c6

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

8 years agoMFC r294815: MFV r294814: 6393 zfs receive a full send as a clone
mav [Mon, 21 Mar 2016 00:01:59 +0000 (00:01 +0000)]
MFC r294815: MFV r294814: 6393 zfs receive a full send as a clone

Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Prakash Surya <prakash.surya@delphix.com>
Reviewed by: Richard Elling <Richard.Elling@RichardElling.com>
Approved by: Dan McDonald <danmcd@omniti.com>
Author: Paul Dagnelie <pcd@delphix.com>

illumos/illumos-gate@68ecb2ec930c4b0f00acaf8e0abb2b19c4b8b76f

This allows to do a full (non-incremental send) and receive it as a clone
of an existing dataset. It can leverage nopwrite to share blocks with the
origin. This can be used to change the relationship of datasets on the
target. For example, maybe on the source you have:

A ---- B ---- C

And you have sent to the target a full of B, and the incremental B->C:

B ---- C

You later realize that you want to have A on the target. You will have to
do a full send of A, but nopwrite can save you space on the target if you
receive it as a clone of B, assuming that A and B have some blocks inxi
common:

B ---- C
 \
  A

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

8 years agoMFC r294813: MFV r294812:
mav [Sun, 20 Mar 2016 23:58:44 +0000 (23:58 +0000)]
MFC r294813: MFV r294812:
6434 sa_find_sizes() may compute wrong SA header size

Reviewed-by: Ned Bass <bass6@llnl.gov>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed by: Andriy Gapon <avg@freebsd.org>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Approved by: Robert Mustacchi <rm@joyent.com>
Author: James Pan <jiaming.pan@yahoo.com>

illumos/illumos-gate@3502ed6e7cb3f3d2e781960ab8fe465fdc884834

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

8 years agoMFC r294811: MFV r294810: 6414 vdev_config_sync could be simpler
mav [Sun, 20 Mar 2016 23:57:46 +0000 (23:57 +0000)]
MFC r294811: MFV r294810: 6414 vdev_config_sync could be simpler

Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Approved by: Robert Mustacchi <rm@joyent.com>
Author: Will Andrews <will@firepipe.net>

illumos/illumos-gate@eb5bb58421f46cee79155a55688e6c675e7dd361

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

8 years agoMFC r294809: MFV r294808:
mav [Sun, 20 Mar 2016 23:56:59 +0000 (23:56 +0000)]
MFC r294809: MFV r294808:
6421 Add missing multilist_destroy calls to arc_fini

Reviewed by: Dan Kimmel <dan.kimmel@delphix.com>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Jorgen Lundman <lundman@lundman.net>
Approved by: Robert Mustacchi <rm@joyent.com>
Author: Prakash Surya <prakash.surya@delphix.com>

illumos/illumos-gate@57deb2328260c447bf1db25fe74e0eece102733e

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

8 years agoMFC r294807: MFV r294806:
mav [Sun, 20 Mar 2016 23:56:02 +0000 (23:56 +0000)]
MFC r294807: MFV r294806:
6388 Failure of userland copy should return EFAULT

Reviewed by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Dan Kimmel <dan.kimmel@delphix.com>
Approved by: Robert Mustacchi <rm@joyent.com>
Author: Richard Yao <ryao@gentoo.org>

illumos/illumos-gate@c71c00bbe8a9cdc7e3f4048b751f48e80441d506

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

8 years agoMFC r294805: MFV r294804:
mav [Sun, 20 Mar 2016 23:54:59 +0000 (23:54 +0000)]
MFC r294805: MFV r294804:
6386 Fix function call with uninitialized value in vdev_inuse

Reviewed by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Dan Kimmel <dan.kimmel@delphix.com>
Approved by: Robert Mustacchi <rm@joyent.com>
Author: Richard Yao <ryao@gentoo.org>

illumos/illumos-gate@5bdd995ddb777f538bfbcc5e2d5ff1bed07ae56e

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

8 years agoMFC r294803: MFV r294802: 6334 Cannot unlink files when over quota
mav [Sun, 20 Mar 2016 23:54:05 +0000 (23:54 +0000)]
MFC r294803: MFV r294802: 6334 Cannot unlink files when over quota

Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Toomas Soome <tsoome@me.com>
Approved by: Dan McDonald <danmcd@omniti.com>
Author: Simon Klinkert <simon.klinkert@gmail.com>

illumos/illumos-gate@6575bca01367958c7237253d88e5fa9ef0b1650a

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

8 years agoMFC r294801: MFV r294800: 6385 Fix unlocking order in zfs_zget
mav [Sun, 20 Mar 2016 23:52:45 +0000 (23:52 +0000)]
MFC r294801: MFV r294800: 6385 Fix unlocking order in zfs_zget

Reviewed by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Dan Kimmel <dan.kimmel@delphix.com>
Reviewed by: Andriy Gapon <avg@freebsd.org>
Approved by: Robert Mustacchi <rm@joyent.com>
Author: Richard Yao <ryao@gentoo.org>

illumos/illumos-gate@eaef6a96de3f6afbbccc69bd7a0aed4463689d0a

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

8 years agoMFC r294799: MFV r294798:
mav [Sun, 20 Mar 2016 23:51:56 +0000 (23:51 +0000)]
MFC r294799: MFV r294798:
6292 exporting a pool while an async destroy is running can leave entries
in the deferred tree

Reviewed by: Paul Dagnelie <pcd@delphix.com>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Andriy Gapon <avg@FreeBSD.org>
Reviewed by: Fabian Keil <fk@fabiankeil.de>
Approved by: Gordon Ross <gordon.ross@nexenta.com>

illumos/illumos-gate@a443cc80c742af740aa82130db840f02b4389365

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

8 years agoMFC r294797: MFV r294796:
mav [Sun, 20 Mar 2016 23:51:11 +0000 (23:51 +0000)]
MFC r294797: MFV r294796:
6319 assertion failed in zio_ddt_write: bp->blk_birth == txg

Reviewed by: George Wilson <george.wilson@delphix.com>
Approved by: Dan McDonald <danmcd@omniti.com>

illumos/illumos-gate@b39b744be78c6327db43c1f69d11c2f5909f73cb

This is revert of 5693.

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

8 years agoMFC r294794: MFV r294793:
mav [Sun, 20 Mar 2016 23:49:58 +0000 (23:49 +0000)]
MFC r294794: MFV r294793:
6367 spa_config_tryenter incorrectly handles the multiple-lock case

Reviewed by: Alek Pinchuk <alek.pinchuk@nexenta.com>
Reviewed by: Josef 'Jeff' Sipek <josef.sipek@nexenta.com>
Reviewed by: Prashanth Sreenivasa <prashksp@gmail.com>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Dan McDonald <danmcd@omniti.com>
Reviewed by: Steven Hartland <steven.hartland@multiplay.co.uk>
Approved by: Matthew Ahrens <mahrens@delphix.com>

illumos/illumos-gate@e495b6e6735b803e422025a630352ef9bba788c5

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

8 years agoMFC r294625 (by trasz):
mav [Sun, 20 Mar 2016 23:48:26 +0000 (23:48 +0000)]
MFC r294625 (by trasz):
Fix ru_oublocks accounting for ZFS. There are two code paths that can be
called from zfs_write() - one of them, through dmu_write(), was handled
correctly; the other wasn't.

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

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

8 years agoMFC r293677 (by asomers): Record physical path information in ZFS Vdevs
mav [Sun, 20 Mar 2016 23:43:26 +0000 (23:43 +0000)]
MFC r293677 (by asomers): Record physical path information in ZFS Vdevs

sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev_geom.c:
        If available, record the physical path of a vdev in ZFS meta-data.
        Do this both when opening the vdev, and when receiving an attribute
        change notification from GEOM.

        Make vdev_geom_close() synchronous instead of deferring its work to
        a GEOM event handler. There is no benefit to deferring the work and
        this prevents a future open call from referencing a consumer that is
        scheduled for destruction. The close followed by an immediate open
        will occur during a vdev reprobe triggered by any type of I/O error.

        Consolidate vdev_geom_close() and vdev_geom_detach() into
        vdev_geom_close() and vdev_geom_close_locked(). This also moves the
        cross linking operations between vdev and GEOM consumer into a
        single place (linking in vdev_geom_attach() and unlinking in
        vdev_geom_close_locked()).

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

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

8 years agoMFC r292653 (by bapt): Report an error if zdb cannot initialize zfs
mav [Sun, 20 Mar 2016 23:29:58 +0000 (23:29 +0000)]
MFC r292653 (by bapt): Report an error if zdb cannot initialize zfs

If the zfs module is not present and not loadable, report an error
to the user instead of crashing

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

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

8 years agoMFC r291637 (by bdrewery): Fix the build for non-amd64.
mav [Sun, 20 Mar 2016 23:26:52 +0000 (23:26 +0000)]
MFC r291637 (by bdrewery): Fix the build for non-amd64.

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

8 years agoMFC r290266 (by avg):
mav [Sun, 20 Mar 2016 23:20:16 +0000 (23:20 +0000)]
MFC r290266 (by avg):
zfs: allow the lookup of extended attributes of an unlinked file

That's required for extattr_get_fd(2) and the like to work properly.

PR: 203201

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

8 years agoMFC r274627 (by avg):
mav [Sun, 20 Mar 2016 20:37:26 +0000 (20:37 +0000)]
MFC r274627 (by avg):
Revert r269093 which introduced physical zio alignment transform

Size of physical ZIOs must never be implicitly adjusted, it's
a responsibility of a caller to make sure that such a ZIO has proper offset
and size.

Discussed with: delphij, gibbs

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

8 years agoMFV r258597 (by pjd):
mav [Sun, 20 Mar 2016 20:33:03 +0000 (20:33 +0000)]
MFV r258597 (by pjd):
When append-only, immutable or read-only flag is set don't allow for
hard links creation. This matches UFS behaviour.

Reported by:    Oleg Ginzburg <olevole@olevole.ru>

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

8 years agoMFC r262990: MFV r262983:
mav [Sun, 20 Mar 2016 20:31:30 +0000 (20:31 +0000)]
MFC r262990: MFV r262983:

4638 Panic in ZFS via rfs3_setattr()/rfs3_write(): dirtying snapshot!

illumos/illumos-gate@2144b121c08e0eb676cc6ca4662ebbc9f9c22fe3

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

8 years agoMFC r272359 (by will):
mav [Sun, 20 Mar 2016 20:27:52 +0000 (20:27 +0000)]
MFC r272359 (by will):
zfsvfs_create(): Refuse to mount datasets whose names are too long.

This is checked for in the zfs_snapshot_004_neg STF/ATF test (currently
still in projects/zfsd rather than head).

sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c:
- zfsvfs_create(): Check whether the objset name fits into
  statfs.f_mntfromname, and return ENAMETOOLONG if not.  Although
  the filesystem can be unmounted via the umount(8) command, any
  interface that relies on iterating on statfs (e.g. libzfs) will
  fail to find the filesystem by its objset name, and thus assume
  it's not mounted.  This causes "zfs unmount", "zfs destroy",
  etc. to fail on these filesystems, whether or not -f is passed.

MFSpectraBSD:   974872 on 2013/08/09

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

8 years agoMFC r277503 (by will): Ignore sync requests from the system syncher,
mav [Sun, 20 Mar 2016 20:25:36 +0000 (20:25 +0000)]
MFC r277503 (by will): Ignore sync requests from the system syncher,
i.e. VFS_SYNC(waitfor=MNT_LAZY).

ZFS already commits outstanding data every zfs_txg_timeout seconds, so these
syncs are unnecessarily intrusive.

MFSpectraBSD:   1105759 on 2014/12/11

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

8 years agoMFC r277501 (by will): Eliminate an #ifdef illumos for zfs_ioc_rename().
mav [Sun, 20 Mar 2016 20:23:20 +0000 (20:23 +0000)]
MFC r277501 (by will): Eliminate an #ifdef illumos for zfs_ioc_rename().

Since allow_mounted is a FreeBSD-specific change, default to B_TRUE, then
locally check for the magic bit.  Unconditionally check allow_mounted below.
Convert the setting of allow_mounted to an explicit boolean.

MFSpectraBSD:   672578 (in part) on 2013/07/19

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

8 years agoMFC r286223 (by smh): Fix KSTACK_PAGES check in ZFS module
mav [Sun, 20 Mar 2016 20:20:37 +0000 (20:20 +0000)]
MFC r286223 (by smh): Fix KSTACK_PAGES check in ZFS module

The check introduced by r285946 failed to add the dependency on
opt_kstack_pages.h which meant the default value for the platform instead
of the customised options KSTACK_PAGES=X was being tested.

Also wrap in #ifdef __FreeBSD__ for portability.

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

8 years agoMFC r274304 (by delphij): MFV r274272 and diff reduction with upstream.
mav [Sun, 20 Mar 2016 20:12:14 +0000 (20:12 +0000)]
MFC r274304 (by delphij): MFV r274272 and diff reduction with upstream.

Illumos issue:
    5244 zio pipeline callers should explicitly invoke next stage

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

8 years agoMFC r277300 (by smh): Mechanically convert cddl sun #ifdef's to illumos
mav [Sun, 20 Mar 2016 20:00:25 +0000 (20:00 +0000)]
MFC r277300 (by smh): Mechanically convert cddl sun #ifdef's to illumos

Since the upstream for cddl code is now illumos not sun, mechanically
convert all sun #ifdef's to illumos #ifdef's which have been used in all
newer code for some time.

Also do a manual pass to correct the use if #ifdef comments as per style(9)
as well as few uses of #if defined(__FreeBSD__) vs #ifndef illumos.

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

8 years agoMFC r271785:
mav [Sun, 20 Mar 2016 19:21:20 +0000 (19:21 +0000)]
MFC r271785:
Reorder sysctls for spa.c global tunables; add sysctl for ccw_retry_interval.

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

8 years agoMFC r269222: Reschedule the 'deadman' callout after handling, this makes our
mav [Sun, 20 Mar 2016 19:14:51 +0000 (19:14 +0000)]
MFC r269222: Reschedule the 'deadman' callout after handling, this makes our
code behave more like it is on Solaris.

Differential Revision: https://phabric.freebsd.org/D457

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

8 years agoMFC r271788 (by will):
mav [Sun, 20 Mar 2016 19:11:17 +0000 (19:11 +0000)]
MFC r271788 (by will):
Enable ZFS debug flags to be modified via vfs.zfs.debug_flags.

This is primarily only of interest to ZFS developers, but it makes it
easier to get additional debugging.

MFSpectraBSD:   517074 on 2011/12/15 (by will), 662343 on 2013/03/20 (by gibbs)

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

8 years agoMFC r277492 (by will): Add vfs.zfs.reference_tracking_enable sysctl/tunable.
mav [Sun, 20 Mar 2016 19:07:12 +0000 (19:07 +0000)]
MFC r277492 (by will): Add vfs.zfs.reference_tracking_enable sysctl/tunable.

This is primarily for developer/debugging use; it enables built-in tagged
tracking of refcounts inside ZFS.  It can only be enabled from the loader,
since it modifies how in-core state is managed.  Default remains disabled.

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

8 years agoMFC r271781i (by will):
mav [Sun, 20 Mar 2016 18:56:03 +0000 (18:56 +0000)]
MFC r271781i (by will):
bpobj_iterate_impl(): Close a refcount leak iterating on a sublist.

If bpobj_space() returned non-zero here, the sublist would have been
left open, along with the bonus buffer hold it requires.  This call
does not invoke any calls to bpobj_close() itself.

This bug doesn't have any known vector, but was found on inspection.

MFC after:      1 week
Sponsored by:   Spectra Logic
Affects:        All ZFS versions starting 21 May 2010 (illumos cde58dbc)
MFSpectraBSD:   r1050998 on 2014/03/26

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

8 years agoMFC r264670: MFV r264667:
mav [Sun, 20 Mar 2016 16:00:05 +0000 (16:00 +0000)]
MFC r264670: MFV r264667:

4752 fan out read zio taskqs

illumos/illumos-gate@1b497ab83e8f1c58bba5da59c649207a442a4720

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

8 years agoMFC r256613, r256862: MFprojects/camlock r254763:
mav [Sun, 20 Mar 2016 14:37:37 +0000 (14:37 +0000)]
MFC r256613, r256862: MFprojects/camlock r254763:
Move tq_enqueue() call out of the queue lock for known handlers (actually
I have found no others in the base system).  This reduces queue lock hold
time and congestion spinning under active multithreaded enqueuing.

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

8 years agoMFC r256612: MFprojects/camlock r254685:
mav [Sun, 20 Mar 2016 14:11:37 +0000 (14:11 +0000)]
MFC r256612: MFprojects/camlock r254685:
Remove TQ_FLAGS_PENDING flag, softly duplicating queue emptiness status.

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

8 years agoMFC r277759 (by jhb@)
np [Sun, 20 Mar 2016 05:01:40 +0000 (05:01 +0000)]
MFC r277759 (by jhb@)

Fix a couple of panics when detaching from a cxgbe/cxl interface that was
never brought up:
- Allow NULL to be passed to sglist_free().
- Don't try to stop an interface that was never fully initialized.

PR: 208136

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

8 years agoMFC r295822:
pfg [Sun, 20 Mar 2016 03:09:01 +0000 (03:09 +0000)]
MFC r295822:
qlxgb: fix mismatch.

Found by: PVS Static Analysis
Reviewed by: davidcs

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

8 years agoMFC r295811:
pfg [Sat, 19 Mar 2016 23:07:05 +0000 (23:07 +0000)]
MFC r295811:
Ext2: cleanup setting of ctime/mtime/birthtime.

This adopts the same change as r291936 for UFS.
Directly clear IN_ACCESS or IN_UPDATE when user supplied the time, and
copy the value into the inode.

This keeps the behaviour cleaner and is consistent with UFS.

Reviewed by: bde

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

8 years agoMFC: 296167
jgh [Sat, 19 Mar 2016 22:56:20 +0000 (22:56 +0000)]
MFC: 296167

- address obsolete Kerberos options

PR: 205168
Submitted by: kevin@bostoncrypto.com
Reviewed by: bjk
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D5430

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

8 years agoMFC r296922:
smh [Sat, 19 Mar 2016 11:35:53 +0000 (11:35 +0000)]
MFC r296922:

Prevent invalid ixgbe advertise setting warning

Sponsored by: Multiplay

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

8 years agodrm: Fix dev->ioctl_count references leak
dumbbell [Fri, 18 Mar 2016 22:52:11 +0000 (22:52 +0000)]
drm: Fix dev->ioctl_count references leak

This fixes the following error:
kernel: error: [drm:pid1167:drm_release] *ERROR* Device busy: 2

Because of that, drm_lastclose() was not called, leading to a few memory
leaks once the driver was unloaded.

MFC of: r296674

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

8 years agoMFC r296707:
bdrewery [Fri, 18 Mar 2016 18:26:07 +0000 (18:26 +0000)]
MFC r296707:

  Add missing CLEANFILES.

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

8 years agoMFC r296643:
bdrewery [Fri, 18 Mar 2016 18:24:36 +0000 (18:24 +0000)]
MFC r296643:

  Fix make -n upgrade_checks.

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

8 years agoMFC r296919: Fix small memory leak on attempt to access deleted snapshot.
mav [Fri, 18 Mar 2016 13:32:00 +0000 (13:32 +0000)]
MFC r296919: Fix small memory leak on attempt to access deleted snapshot.

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

8 years agoMFC r296653: Allow standard commands for "unknown" classes in RESCUE mode.
mav [Fri, 18 Mar 2016 13:29:43 +0000 (13:29 +0000)]
MFC r296653: Allow standard commands for "unknown" classes in RESCUE mode.

For example, it allows quite useful `geom disk list` command.

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

8 years agoMFC r296388:
kib [Fri, 18 Mar 2016 01:35:03 +0000 (01:35 +0000)]
MFC r296388:
Pass MNTK_NO_IOPF and MNTK_UNMAPPED_BUFS flags from the lower
filesystem to the nullfs mount.

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

8 years agoMFC: r296988
allanjude [Thu, 17 Mar 2016 21:00:43 +0000 (21:00 +0000)]
MFC: r296988
  Remove 50% ZFS conditional from bsdinstall/zfsboot

Approved by: re (marius)

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

8 years agoMFC r295900, r295768 to usr.sbin/iostat
asomers [Thu, 17 Mar 2016 20:29:10 +0000 (20:29 +0000)]
MFC r295900, r295768 to usr.sbin/iostat

r295768 | asomers | 2016-02-18 13:08:01 -0700 (Thu, 18 Feb 2016) | 14 lines

Fix compiler warnings in iostat

Raise WARNS from 1 to 6 (the default)
Fix warnings:
* Use C99 designated initializers for structs, and initialize all fields
* Mark global variables as static
* Mark unused function arguments
* Be careful about signed/unsigned comparisons

r295900 | asomers | 2016-02-22 14:40:53 -0700 (Mon, 22 Feb 2016) | 10 lines

Fix the usr.sbin/iostat build with GCC, broken by r295768

Renamed some local variables for compatibility with -Wshadow

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

8 years agoMFC r293229, r293833 to usr.sbin/rpcbind
asomers [Thu, 17 Mar 2016 20:00:49 +0000 (20:00 +0000)]
MFC r293229, r293833 to usr.sbin/rpcbind

r293833 | asomers | 2016-01-13 10:33:50 -0700 (Wed, 13 Jan 2016) | 16 lines

Fix Coverity warnings regarding r293229

rpcbind/check_bound.c
        Fix CID1347798, a memory leak in mergeaddr.

rpcbind/tests/addrmerge_test.c
        Fix CID1347800 through CID1347803, memory leaks in ATF tests.  They
        are harmless because each ATF test case runs in its own process, but
        they are trivial to fix.  Fix a few other leaks that Coverity didn't
        detect, too.

r293229 | asomers | 2016-01-05 17:00:11 -0700 (Tue, 05 Jan 2016) | 36 lines

"source routing" in rpcbind

Fix a bug in rpcbind for multihomed hosts. If the server had interfaces on
two separate subnets, and a client on the first subnet contacted rpcbind at
the address on the second subnet, rpcbind would advertise addresses on the
first subnet. This is a bug, because it should prefer to advertise the
address where it was contacted. The requested service might be firewalled
off from the address on the first subnet, for example.

usr.sbin/rpcbind/check_bound.c
        If the address on which a request was received is known, pass that
        to addrmerge as the clnt_uaddr parameter. That is what addrmerge's
        comment indicates the parameter is supposed to mean. The previous
        behavior is that clnt_uaddr would contain the address from which the
        client sent the request.

usr.sbin/rpcbind/util.c
        Modify addrmerge to prefer to use an IP that is equal to clnt_uaddr,
        if one is found. Refactor the relevant portion of the function for
        clarity, and to reduce the number of ifdefs.

etc/mtree/BSD.tests.dist
usr.sbin/rpcbind/tests/Makefile
usr.sbin/rpcbind/tests/addrmerge_test.c
        Add unit tests for usr.sbin/rpcbind/util.c:addrmerge.

usr.sbin/rpcbind/check_bound.c
usr.sbin/rpcbind/rpcbind.h
usr.sbin/rpcbind/util.c
        Constify some function arguments

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

8 years agoMFC r294504, r294652, r294653, r294655:
pfg [Thu, 17 Mar 2016 19:28:15 +0000 (19:28 +0000)]
MFC r294504, r294652, r294653, r294655:

ext2fs: Bring back the htree dir_index implementation.

The htree dir_index is perhaps one of the most characteristic
features of the linux ext3 implementation. It was removed
in r281670, due to repeated bug reports.

Damjan Jovanic detected and fixed three bugs and did some
stress testing by building Apache OpenOffice on top of it
so it is now in good shape to bring back.

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

Submitted by: Damjan Jovanovic
Reviewed by: pfg
RelNotes: yes

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

8 years agoMFC r296623:
bdrewery [Thu, 17 Mar 2016 01:02:34 +0000 (01:02 +0000)]
MFC r296623:

  Remove redundant files already tracked by
  tools/build/mk/OptionalObsoleteFiles.inc.

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

8 years agoMFC 296416:
mp [Thu, 17 Mar 2016 00:32:29 +0000 (00:32 +0000)]
MFC 296416:

Signal handling within tcsh vfork code path will conflict with some system
libraries (such as libthr) which maintain their own signal state. This
change adds the tcsh SAVESIGVEC option to save and restore the sigvecs for
the signals the child modifies before it execs.

Reviewed by: kib, rwatson
Reported by: kib

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

8 years agoMerge r296956:
glebius [Wed, 16 Mar 2016 22:35:55 +0000 (22:35 +0000)]
Merge r296956:

  Due to invalid use of a signed intermediate value in the bounds checking
  during argument validity verification, unbound zero'ing of the process LDT
  and adjacent memory can be initiated from usermode.

Submitted by:   CORE Security
Patch by:       kib
Security:       SA-16:15

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

8 years agoMFC r296807: (this time with 100% fewer unintended changes mixed in)...
ian [Wed, 16 Mar 2016 16:52:31 +0000 (16:52 +0000)]
MFC r296807: (this time with 100% fewer unintended changes mixed in)...

  Require firewall setup before running rc.d/netwait, otherwise the ping
  packets sent by netwait may not get through.

PR: 207916

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

8 years agoRevert r296940, it contained unintended changes, and will be redone.
ian [Wed, 16 Mar 2016 16:50:13 +0000 (16:50 +0000)]
Revert r296940, it contained unintended changes, and will be redone.

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

8 years agoMFC r296908:
kib [Wed, 16 Mar 2016 16:42:01 +0000 (16:42 +0000)]
MFC r296908:
Force the desired alignment of the user save area.

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

8 years agoMFC r296807:
ian [Wed, 16 Mar 2016 16:21:30 +0000 (16:21 +0000)]
MFC r296807:

  Require firewall setup before running rc.d/netwait, otherwise the ping
  packets sent by netwait may not get through.

PR: 207916

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

8 years agoMFC r296319:
kib [Wed, 16 Mar 2016 15:34:16 +0000 (15:34 +0000)]
MFC r296319:
Fix handling of DT_TEXTREL for an object with more than one read-only
segment.

PR: 207631

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

8 years agoMFC r296299 - Remove redundant NULL pointer comparison.
cy [Wed, 16 Mar 2016 01:48:32 +0000 (01:48 +0000)]
MFC r296299 - Remove redundant NULL pointer comparison.

Reported by: PVS-Studio (V595) in Differential Revision D5245

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

8 years agoMFC r296525:
bdrewery [Tue, 15 Mar 2016 17:06:40 +0000 (17:06 +0000)]
MFC r296525:

  Just exit in the child if execve(2) fails.

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

8 years agoMFC r296524:
bdrewery [Tue, 15 Mar 2016 17:05:28 +0000 (17:05 +0000)]
MFC r296524:

  Filemon: Attach from the child to avoid racing with the parent attach.

Relnotes: yes

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

8 years agoMFC r296320:
kib [Tue, 15 Mar 2016 10:45:55 +0000 (10:45 +0000)]
MFC r296320:
Adjust _callout_stop_safe() return value for the subr_sleepqueue.c needs
when migrating callout was blocked, but running one was not.

PR: 200992

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

8 years agoMFC r296579
davidcs [Mon, 14 Mar 2016 23:21:06 +0000 (23:21 +0000)]
MFC r296579
Fix code so that buf_ring allocation for Tx Queues and their mutexes
is done during during bxe_attach() and freed during bxe_detach()

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

8 years agoMFC r293878,r293880,r295116,r295117,r295477:
ngie [Mon, 14 Mar 2016 01:35:46 +0000 (01:35 +0000)]
MFC r293878,r293880,r295116,r295117,r295477:

r293878:

Remove unnecessary kldload logic added to geom_subr.sh in r293028

r293880:

PID file support hasn't been committed for ggated(8) yet. Unbreak running
the testcase more than once by restoring the "killall ggated"

r295116:

Add an additional 1 second sleep to after calling ggatec before calling
dd to defeat a race when writing out to the geom_gate(4) device

This will quell the Jenkins failure emails until I come up with a better
solution

r295117:

Use the pidfile support added to ggated(8) in r294973 to ensure that the
ggated(8) daemon used by the tests is the instance specifically invoked by
the tests instead of one or more daemon instances running on the system

r295477:

Similar to r295116, add an additional 1 second sleep after calling ggatel
before calling dd to defeat a race when writing out to the geom_gate(4)
device

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

8 years agoMFC r293821:
ngie [Mon, 14 Mar 2016 01:31:40 +0000 (01:31 +0000)]
MFC r293821:

Integrate
tools/regression/geom_{concat,eli,gate,mirror,nop,raid3,shsec,stripe,uzip}
in to the FreeBSD test suite as
tests/sys/geom/class/{concat,eli,gate,mirror,nop,raid3,shsec,stripe,uzip}

The tools/regression/geom and tools/regression/geom_part testcases are being
left alone because both test sets are both currently broken.

The majority of this work was done on ^/user/ngie/more-tests2 . The differences
are as follows:
- tests/sys/geom/class/Makefile.inc is not present; it was
  inlined into the class's Makefiles for explicitness.
- The testcases officially require root via kyua
- The geom_gate(4) tests don't use the pidfile changes proposed in
  https://reviews.freebsd.org/D4836 .

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

8 years agoMFC r294973:
ngie [Sun, 13 Mar 2016 23:32:59 +0000 (23:32 +0000)]
MFC r294973:

Add pidfile support to ggated(8)

The tests will manipulate the system daemon today, which can cause undesired
service interruption when the tests are run.

This change allows the geom_gate tests to be run with an arbitrary ggated(8)
daemon / geom_gate(4) device pairing.

Other changes:
- Sort #includes
- Use a more common idiom for parsing options with getopt(3)

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

8 years agoMFC r293621,r293622,r293815:
ngie [Sun, 13 Mar 2016 23:29:11 +0000 (23:29 +0000)]
MFC r293621,r293622,r293815:

r293621:

- Delete non-TAP testcases
- Add a conf.sh file for executing common functions with geom_gate
- Use attach_md for attaching md(4) devices
- Don't hardcode /tmp for temporary files, which violates the kyua sandbox
- Add/increase sleeps to try and improve synchronization
- Add debug output for when checksums fail

test-1.t:
- Use pkill for killing ggated

r293622:

Remove Makefile now that the testcases are all TAP based and
prove -rv can be used on them

r293815:

Add conf.sh file missed in r293621

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

8 years agoAdd patch corresponding to r296800.
dim [Sun, 13 Mar 2016 18:34:32 +0000 (18:34 +0000)]
Add patch corresponding to r296800.

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

8 years agoPull in r219512 from upstream llvm trunk (by Hal Finkel):
dim [Sun, 13 Mar 2016 18:32:10 +0000 (18:32 +0000)]
Pull in r219512 from upstream llvm trunk (by Hal Finkel):

  [MiSched] Fix a logic error in tryPressure()

  Fixes a logic error in the MachineScheduler found by Steve Montgomery
  (and confirmed by Andy). This has gone unfixed for months because the
  fix has been found to introduce some small performance regressions.
  However, Andy has recommended that, at this point, we fix this to
  avoid further dependence on the incorrect behavior (and then
  follow-up separately on any regressions), and I agree.

  Fixes PR18883.

This fixes a possible "ran out of registers" error when compiling
www/firefox 45.0 on i386.

Direct commit to stable/10, because head already has this fix since the
llvm/clang 3.6.0 import.

PR: 207837

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

8 years agoMFC r296542:
dchagin [Sun, 13 Mar 2016 08:19:27 +0000 (08:19 +0000)]
MFC r296542:
Load linux64 module for amd64 if Linux abi enabled.

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

8 years agoMFC r294891:
ngie [Sun, 13 Mar 2016 01:20:20 +0000 (01:20 +0000)]
MFC r294891:

Require /sbin/mount_cd9660 when running the cd9660 tests

In some cases the test system might not have mount_cd9660(8). Don't
implicitly rely on it while testing cd9660 support; explicitly rely
on it

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

8 years agoMFC r293443:
ngie [Sun, 13 Mar 2016 01:17:53 +0000 (01:17 +0000)]
MFC r293443:

- Make test-1.sh into a TAP testable testcase
- Delete test-2.sh as it was an incomplete testcase, and the contents were
  basically a subset of test-1.sh
- Add a conf.sh file for executing common functions with geom_uzip
- Use attach_md for attaching md(4) devices
- Don't hardcode /tmp for temporary files, which violates the kyua sandbox

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

8 years agoMFC r293442:
ngie [Sun, 13 Mar 2016 01:16:50 +0000 (01:16 +0000)]
MFC r293442:

- Add a geom_stripe specific cleanup function and trap on that function at
  exit so things are cleaned up properly
- Use attach_md for attaching md(4) devices
- Don't hardcode /tmp for temporary files, which violates the kyua sandbox

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

8 years agoMFC r293441:
ngie [Sun, 13 Mar 2016 01:15:34 +0000 (01:15 +0000)]
MFC r293441:

- Add a geom_shsec specific cleanup function and trap on that function at
  exit so things are cleaned up properly
- Use attach_md for attaching md(4) devices
- Don't hardcode /tmp for temporary files, which violates the kyua sandbox

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

8 years agoMFC r293438:
ngie [Sun, 13 Mar 2016 01:14:07 +0000 (01:14 +0000)]
MFC r293438:

- Add a geom_raid3 specific cleanup function and trap on that function at
  exit so things are cleaned up properly
- Use attach_md for attaching md(4) devices
- Don't hardcode /tmp for temporary files, which violates the kyua sandbox

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

8 years agoMFC r293437:
ngie [Sun, 13 Mar 2016 01:12:58 +0000 (01:12 +0000)]
MFC r293437:

- Add a conf.sh file for executing common functions with gnop
- Use attach_md for attaching md(4) devices
- Don't hardcode /tmp for temporary files, which violates the kyua sandbox

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

8 years agoMFC r293436:
ngie [Sun, 13 Mar 2016 01:08:10 +0000 (01:08 +0000)]
MFC r293436:

- Add a conf.sh file for executing common functions with geli
-- Use linear probing to find the first unique md(4) device, unlike the other
   code which uses attach_md, as geli(8) allocates the md(4) devices itself
- Don't hardcode /tmp for temporary files, which violates the kyua sandbox

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

8 years agoMFH (r296633): upgrade to 7.2p2 (fixes xauth command injection bug)
des [Sat, 12 Mar 2016 23:53:20 +0000 (23:53 +0000)]
MFH (r296633): upgrade to 7.2p2 (fixes xauth command injection bug)
MFH (r296634): re-add aes-cbc to server-side default cipher list
MFH (r296651, r296657): fix gcc build of pam_ssh

PR: 207679
Security:       CVE-2016-3115

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

8 years agoMFC r293434:
ngie [Sat, 12 Mar 2016 23:11:08 +0000 (23:11 +0000)]
MFC r293434:

- Use attach_md for memory disks so they can be tracked.
- Add a geom_concat specific cleanup function and trap on that function at
  exit so things are cleaned up properly
- Don't hardcode /tmp for temporary files, which violates the kyua sandbox

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

8 years agoMFC r295416:
bdrewery [Sat, 12 Mar 2016 19:55:22 +0000 (19:55 +0000)]
MFC r295416:

  Fix the gcc build after r295407.

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

8 years agoMFC r268620,r294876,r294877:
bdrewery [Sat, 12 Mar 2016 19:26:21 +0000 (19:26 +0000)]
MFC r268620,r294876,r294877:

  r268620:
    Make generation of nslexer.c more robust.
  r294876:
    nslexer.c does not depend on nsparser.h.
  r294877:
    Replace nslexer.l->nslexer.c custom rule with a -D CFLAG.

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

8 years agoMFC r294873:
bdrewery [Sat, 12 Mar 2016 19:22:19 +0000 (19:22 +0000)]
MFC r294873:

  Set a value for _RECURSING_PROGS for debugging.

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

8 years agoMFC r294878:
bdrewery [Sat, 12 Mar 2016 19:20:48 +0000 (19:20 +0000)]
MFC r294878:

  Revert yacc dependency back to pre-r241298.

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

8 years agoMFC r296148:
bdrewery [Sat, 12 Mar 2016 19:18:27 +0000 (19:18 +0000)]
MFC r296148:

  Remove old compatibility checks.

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

8 years agoMFC r294899:
ngie [Sat, 12 Mar 2016 19:15:09 +0000 (19:15 +0000)]
MFC r294899:

Add debug output via ATF_REQUIRE_MSG when the first call to
mlock(2) fails

This helps identify the problem with running this test on my VM
hosts (ENOMEM)

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

8 years agoMFC r296554:
bdrewery [Sat, 12 Mar 2016 19:14:21 +0000 (19:14 +0000)]
MFC r296554:

  Remove things set already by bsd.progs.mk.

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

8 years agoMFC r296122:
bdrewery [Sat, 12 Mar 2016 19:12:52 +0000 (19:12 +0000)]
MFC r296122:

  (partial) Move PROGS logic to proper place and remove redundant and unneeded
  logic.

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

8 years agoMFC r295079:
ngie [Sat, 12 Mar 2016 19:09:51 +0000 (19:09 +0000)]
MFC r295079:

Fix the type for hw.ncpu, so sysctlbyname doesn't consistently fail on
64-bit architectures where sizeof(int) != sizeof(size_t).

PR: 206758

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

8 years agoMFC r296322:
bdrewery [Sat, 12 Mar 2016 19:08:58 +0000 (19:08 +0000)]
MFC r296322:

  Remove self-reference to destroy_dev_drain(9).

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

8 years agoMFC r296286,r296470,r296472,r296473,r296575:
bdrewery [Sat, 12 Mar 2016 19:07:21 +0000 (19:07 +0000)]
MFC r296286,r296470,r296472,r296473,r296575:

  r296286:
    Remove filemon->lock wrappers.
  r296470:
    Only call bwillwrite() for logging to vnodes, as other fo_write() calls do.
  r296472:
    Require kldunload -f to unload.
  r296473:
    Add missing break for r296472.
  r296575:
    FILEMON_SET_FD: Disallow changing the fd.

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

8 years agoMFC r294894:
ngie [Sat, 12 Mar 2016 19:05:49 +0000 (19:05 +0000)]
MFC r294894:

Adjust vm.max_wired in order to avoid hitting EAGAIN artificially

Set vm.max_wired to INT_MAX in :mlock_err, :mlock_mmap, and :mlock_nested to
avoid hitting EAGAIN artificially on the system when running the tests

Require root privileges in order to set the sysctl

Add allow_sysctl_side_effects to require.config as this test is now adjusting
sysctls that can affect the global system state

Unlike the version submitted by cem in OneFS, this version uses a scratch file
to save/restore the previous value of the sysctl. I _really_, _really_ wish
there were better hooks in atf/kyua for per test suite setup/teardown -- using
a file is kludgy, but it's the best I can do to avoid situations where (for
instance), sysctl(3) may fail and drop a core outside the kyua sandbox.

Based on a patch submitted by cem, but modified to take business logic out of
ATF_TP_ADD_TCS(3).

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

8 years agoMFC r295161,r296014:
bdrewery [Sat, 12 Mar 2016 19:02:20 +0000 (19:02 +0000)]
MFC r295161,r296014:

  r295161:
    Add order for installworld/distribution.
  r296014:
    Add order for installworld/installkernel.

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

8 years agoMFC r295341,r295345:
ngie [Sat, 12 Mar 2016 19:00:42 +0000 (19:00 +0000)]
MFC r295341,r295345:

r295341:

Require /bin/getfacl and /bin/setfacl when running the acl tests

For cases where these utilities aren't installed, the tests would fail today
in a non-intuitive manner on sub-testcase #3 in each of the test scripts

r295345:

Use basenames for getfacl, setfacl, and zpool to work around the
fact that Jenkins hardcodes image sizes to 2GB with the FreeBSD_HEAD
job

This is to stop the unnecessary failure emails because we've gone
over the 2GB limit

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

8 years agoMFC r296002,r296012:
bdrewery [Sat, 12 Mar 2016 18:59:03 +0000 (18:59 +0000)]
MFC r296002,r296012:

  r296002:
    Don't hide AR command as bsd.lib.mk's r283925 changed as well.
  r296012:
    OBJS and POBJS have not been used since r215127.

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

8 years agoMFC r295994,r296000:
bdrewery [Sat, 12 Mar 2016 18:57:34 +0000 (18:57 +0000)]
MFC r295994,r296000:

  r295994:
    PROGS: Remove the 'build one' optimization since it breaks 'build multiple'
  r296000:
    PROGS: Only the main process will install INCS.

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

8 years agoMFC r295121:
ngie [Sat, 12 Mar 2016 18:55:48 +0000 (18:55 +0000)]
MFC r295121:

Delete argsize to fix a -Wunused-but-set-variable warning with gcc 4.9

The variable isn't actually checked -- just the end result which gets
returned from the function

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

8 years agoMFC r295980:
bdrewery [Sat, 12 Mar 2016 18:55:16 +0000 (18:55 +0000)]
MFC r295980:

  Support a WANT_MAKE_VERSION.

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