]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
5 years agoMFV r337197: 9456 ztest failure in zil_commit_waiter_timeout
Alexander Motin [Thu, 2 Aug 2018 23:25:49 +0000 (23:25 +0000)]
MFV r337197: 9456 ztest failure in zil_commit_waiter_timeout

illumos/illumos-gate@b6031810da58df96413bf76e068638fcab1f228a

Reviewed by: Matt Ahrens <matt@delphix.com>
Reviewed by: Serapheim Dimitropoulos <serapheim.dimitro@delphix.com>
Approved by: Matt Ahrens <mahrens@delphix.com>
Author:     Prakash Surya <prakash.surya@delphix.com>

5 years ago9456 ztest failure in zil_commit_waiter_timeout
Alexander Motin [Thu, 2 Aug 2018 23:24:40 +0000 (23:24 +0000)]
9456 ztest failure in zil_commit_waiter_timeout

illumos/illumos-gate@b6031810da58df96413bf76e068638fcab1f228a

Reviewed by: Matt Ahrens <matt@delphix.com>
Reviewed by: Serapheim Dimitropoulos <serapheim.dimitro@delphix.com>
Approved by: Matt Ahrens <mahrens@delphix.com>
Author:     Prakash Surya <prakash.surya@delphix.com>

5 years agoMFV r337195: 9454 ::zfs_blkstats should count embedded blocks
Alexander Motin [Thu, 2 Aug 2018 23:23:10 +0000 (23:23 +0000)]
MFV r337195: 9454 ::zfs_blkstats should count embedded blocks

illumos/illumos-gate@dec267e7ea9828898b1c64462daa6636c4ef5e29

Reviewed by: Dan Kimmel <dan.kimmel@delphix.com>
Reviewed by: George Wilson <george.wilson@delphix.com>
Approved by: Robert Mustacchi <rm@joyent.com>
Author:     Matthew Ahrens <mahrens@delphix.com>

5 years ago9454 ::zfs_blkstats should count embedded blocks
Alexander Motin [Thu, 2 Aug 2018 23:17:10 +0000 (23:17 +0000)]
9454 ::zfs_blkstats should count embedded blocks

illumos/illumos-gate@dec267e7ea9828898b1c64462daa6636c4ef5e29

Reviewed by: Dan Kimmel <dan.kimmel@delphix.com>
Reviewed by: George Wilson <george.wilson@delphix.com>
Approved by: Robert Mustacchi <rm@joyent.com>
Author:     Matthew Ahrens <mahrens@delphix.com>

5 years agoMFV r337193:
Alexander Motin [Thu, 2 Aug 2018 23:15:10 +0000 (23:15 +0000)]
MFV r337193:
9424 ztest failure: "unprotected error in call to Lua API (Invalid value type 'f
unction' for key 'error')"

illumos/illumos-gate@fe3ba4d1227d8746116ece7240682b13595c3142

Reviewed by: Sebastien Roy <sebastien.roy@delphix.com>
Reviewed by: Paul Dagnelie <pcd@delphix.com>
Reviewed by: Don Brady <don.brady@delphix.com>
Approved by: Robert Mustacchi <rm@joyent.com>
Author:     Matthew Ahrens <mahrens@delphix.com>

5 years ago9424 ztest failure: "unprotected error in call to Lua API (Invalid value type 'functi...
Alexander Motin [Thu, 2 Aug 2018 23:13:40 +0000 (23:13 +0000)]
9424 ztest failure: "unprotected error in call to Lua API (Invalid value type 'function' for key 'error')"

illumos/illumos-gate@fe3ba4d1227d8746116ece7240682b13595c3142

Reviewed by: Sebastien Roy <sebastien.roy@delphix.com>
Reviewed by: Paul Dagnelie <pcd@delphix.com>
Reviewed by: Don Brady <don.brady@delphix.com>
Approved by: Robert Mustacchi <rm@joyent.com>
Author:     Matthew Ahrens <mahrens@delphix.com>

5 years agocxgbe(4): Improvements in TID management.
Navdeep Parhar [Thu, 2 Aug 2018 22:52:05 +0000 (22:52 +0000)]
cxgbe(4): Improvements in TID management.

- Ignore any type of TID where the start/end values are not in the
  correct order.  There are situations where the firmware isn't able to
  reserve room for the number requested in the config file but doesn't
  report a failure during configuration and instead sets end <= start.

- Track start/end in tid_tab and remove some redundant copies from
  adapter->params.

- Move all the start/end and other read-only parameters to a quiet part
  of tid_tab, away from the tid locks.

MFC after: 1 week
Sponsored by: Chelsio Communications

5 years agoMFV r337190: 9486 reduce memory used by device removal on fragmented pools
Alexander Motin [Thu, 2 Aug 2018 21:59:46 +0000 (21:59 +0000)]
MFV r337190: 9486 reduce memory used by device removal on fragmented pools

In the most fragmented real-world cases, this reduces memory used by the
mapping from ~1GB to ~50MB of RAM per 1TB of storage removed. Less
fragmented cases will typically also see around 50-100MB of RAM per 1TB
of storage.

illumos/illumos-gate@cfd63e1b1bcf7ba4bf72f55ddbd87ce008d2986d

Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Serapheim Dimitropoulos <serapheim.dimitro@delphix.com>
Reviewed by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed by: Tim Chase <tim@chase2k.com>
Approved by: Robert Mustacchi <rm@joyent.com>
Author:     Matthew Ahrens <mahrens@delphix.com>

5 years ago9486 reduce memory used by device removal on fragmented pools
Alexander Motin [Thu, 2 Aug 2018 21:57:59 +0000 (21:57 +0000)]
9486 reduce memory used by device removal on fragmented pools

In the most fragmented real-world cases, this reduces memory used by the
mapping from ~1GB to ~50MB of RAM per 1TB of storage removed. Less
fragmented cases will typically also see around 50-100MB of RAM per 1TB
of storage.

illumos/illumos-gate@cfd63e1b1bcf7ba4bf72f55ddbd87ce008d2986d

Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Serapheim Dimitropoulos <serapheim.dimitro@delphix.com>
Reviewed by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed by: Tim Chase <tim@chase2k.com>
Approved by: Robert Mustacchi <rm@joyent.com>
Author:     Matthew Ahrens <mahrens@delphix.com>

5 years agobhyve: set title before entering capability mode
Mariusz Zaborski [Thu, 2 Aug 2018 21:54:34 +0000 (21:54 +0000)]
bhyve: set title before entering capability mode

PR: 230082
Submitted by: Yuichiro NAITO <naito.yuichiro@gmail.com>

5 years ago9479 fix wrong format specifier for vdev_id
Alexander Motin [Thu, 2 Aug 2018 21:52:47 +0000 (21:52 +0000)]
9479 fix wrong format specifier for vdev_id

illumos/illumos-gate@c7a7b2fa084facd68c3d1e860dfabe20c713877b

Reviewed by: Matt Ahrens <matt@delphix.com>
Approved by: Robert Mustacchi <rm@joyent.com>
Author:     Andriy Gapon <avg@FreeBSD.org>

5 years agoUpdate dirdeps.mk et al to latest
Simon J. Gerraty [Thu, 2 Aug 2018 21:33:45 +0000 (21:33 +0000)]
Update dirdeps.mk et al to latest

dirdeps.mk and meta.autodep.mk will now look for
Makefile.depend.options
to handle optional dependencies, the work is all done by
dirdeps-options.mk

Also update to latest meta.stage.mk and gendirdeps.mk

Reviewed by: bdrewery
Differential Revision: https://reviews.freebsd.org/D15701

5 years agoMFV r337184: 9457 libzfs_import.c:add_config() has a memory leak
Alexander Motin [Thu, 2 Aug 2018 21:25:32 +0000 (21:25 +0000)]
MFV r337184: 9457 libzfs_import.c:add_config() has a memory leak

A memory leak occurs on lines 209 and 213 because the config is not freed
in the error case.  The interface to add_config() seems less than ideal -
it would be better if it copied any data necessary from the config and the
caller freed it.

illumos/illumos-gate@ddfe901b12348d31c500fb57f9174e88860a4061

Reviewed by: Matt Ahrens <matt@delphix.com>
Reviewed by: Serapheim Dimitropoulos <serapheim.dimitro@delphix.com>
Approved by: Robert Mustacchi <rm@joyent.com>
Author:     sara hartse <sara.hartse@delphix.com>

5 years ago9457 libzfs_import.c:add_config() has a memory leak
Alexander Motin [Thu, 2 Aug 2018 21:24:04 +0000 (21:24 +0000)]
9457 libzfs_import.c:add_config() has a memory leak

A memory leak occurs on lines 209 and 213 because the config is not freed
in the error case.  The interface to add_config() seems less than ideal -
it would be better if it copied any data necessary from the config and the
caller freed it.

illumos/illumos-gate@ddfe901b12348d31c500fb57f9174e88860a4061

Reviewed by: Matt Ahrens <matt@delphix.com>
Reviewed by: Serapheim Dimitropoulos <serapheim.dimitro@delphix.com>
Approved by: Robert Mustacchi <rm@joyent.com>
Author:     sara hartse <sara.hartse@delphix.com>

5 years agoMFV r337182: 9330 stack overflow when creating a deeply nested dataset
Alexander Motin [Thu, 2 Aug 2018 21:19:35 +0000 (21:19 +0000)]
MFV r337182: 9330 stack overflow when creating a deeply nested dataset

Datasets that are deeply nested (~100 levels) are impractical. We just put
a limit of 50 levels to newly created datasets. Existing datasets should
work without a problem.

illumos/illumos-gate@5ac95da7d61660aa299c287a39277cb0372be959

Reviewed by: John Kennedy <john.kennedy@delphix.com>
Reviewed by: Matt Ahrens <matt@delphix.com>
Approved by: Garrett D'Amore <garrett@damore.org>
Author:     Serapheim Dimitropoulos <serapheim.dimitro@delphix.com>

5 years ago9330 stack overflow when creating a deeply nested dataset
Alexander Motin [Thu, 2 Aug 2018 21:12:52 +0000 (21:12 +0000)]
9330 stack overflow when creating a deeply nested dataset

Datasets that are deeply nested (~100 levels) are impractical. We just put
a limit of 50 levels to newly created datasets. Existing datasets should
work without a problem.

illumos/illumos-gate@5ac95da7d61660aa299c287a39277cb0372be959

Reviewed by: John Kennedy <john.kennedy@delphix.com>
Reviewed by: Matt Ahrens <matt@delphix.com>
Approved by: Garrett D'Amore <garrett@damore.org>
Author:     Serapheim Dimitropoulos <serapheim.dimitro@delphix.com>

5 years ago9539 Make zvol operations use _by_dnode routines
Alexander Motin [Thu, 2 Aug 2018 21:07:04 +0000 (21:07 +0000)]
9539 Make zvol operations use _by_dnode routines

Continues what was started in 7801 add more by-dnode routines by fully
converting zvols to avoid unnecessary dnode_hold() calls. This saves a
small amount of CPU time and slightly improves latencies of operations
on zvols.

illumos/illumos-gate@8dfe5547fbf0979fc1065a8b6fddc1e940a7cf4f

Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed by: Rick McNeal <rick.mcneal@nexenta.com>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Richard Yao <richard.yao@prophetstor.com>

5 years ago9539 Make zvol operations use _by_dnode routines
Alexander Motin [Thu, 2 Aug 2018 20:49:08 +0000 (20:49 +0000)]
9539 Make zvol operations use _by_dnode routines

Continues what was started in 7801 add more by-dnode routines by fully
converting zvols to avoid unnecessary dnode_hold() calls. This saves a
small amount of CPU time and slightly improves latencies of operations
on zvols.

illumos/illumos-gate@8dfe5547fbf0979fc1065a8b6fddc1e940a7cf4f

Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed by: Rick McNeal <rick.mcneal@nexenta.com>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Richard Yao <richard.yao@prophetstor.com>

5 years ago9523 Large alloc in zdb can cause trouble
Alexander Motin [Thu, 2 Aug 2018 20:44:07 +0000 (20:44 +0000)]
9523 Large alloc in zdb can cause trouble

16MB alloc in zdb_embedded_block() can cause cores in certain situations
(clang, gcc55).

OsX commit: https://github.com/openzfsonosx/zfs/commit/ced236a5da6e72ea7bf6d2919fe14e17cffe10f1
FreeBSD commit: https://svnweb.freebsd.org/base?view=revision&revision=326150
illumos/illumos-gate@03a4c2f4bfaca30115963b76445279b36468a614

Reviewed by: Igor Kozhukhov <igor@dilos.org>
Reviewed by: Andriy Gapon <avg@FreeBSD.org>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Jorgen Lundman <lundman@lundman.net>

This is an update for r326150 (by avg), where this change comes from.

5 years ago9523 Large alloc in zdb can cause trouble
Alexander Motin [Thu, 2 Aug 2018 20:37:53 +0000 (20:37 +0000)]
9523 Large alloc in zdb can cause trouble

16MB alloc in zdb_embedded_block() can cause cores in certain situations
(clang, gcc55).

OsX commit: https://github.com/openzfsonosx/zfs/commit/ced236a5da6e72ea7bf6d2919fe14e17cffe10f1
FreeBSD commit: https://svnweb.freebsd.org/base?view=revision&revision=326150
illumos/illumos-gate@03a4c2f4bfaca30115963b76445279b36468a614

Reviewed by: Igor Kozhukhov <igor@dilos.org>
Reviewed by: Andriy Gapon <avg@FreeBSD.org>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Jorgen Lundman <lundman@lundman.net>

5 years agoMFV r337175: 9487 Free objects when receiving full stream as clone
Alexander Motin [Thu, 2 Aug 2018 20:33:13 +0000 (20:33 +0000)]
MFV r337175: 9487 Free objects when receiving full stream as clone

All objects after the last written or freed object are not supposed to
exist after receiving the stream. We should free them accordingly, as if
a freeobjects record for them had been included in the stream.

zfsonlinux/zfs@48fbb9ddbf2281911560dfbc2821aa8b74127315
illumos/illumos-gate@7864b8192b8d30471fa2240466d516292e5765b8

Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Paul Dagnelie <pcd@delphix.com>

5 years ago9487 Free objects when receiving full stream as clone
Alexander Motin [Thu, 2 Aug 2018 20:29:58 +0000 (20:29 +0000)]
9487 Free objects when receiving full stream as clone

All objects after the last written or freed object are not supposed to
exist after receiving the stream. We should free them accordingly, as if
a freeobjects record for them had been included in the stream.

zfsonlinux/zfs@48fbb9ddbf2281911560dfbc2821aa8b74127315
illumos/illumos-gate@7864b8192b8d30471fa2240466d516292e5765b8

Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Paul Dagnelie <pcd@delphix.com>

5 years agoMFV r337171:
Alexander Motin [Thu, 2 Aug 2018 20:18:49 +0000 (20:18 +0000)]
MFV r337171:
9464 txg_kick() fails to see that we are quiescing, forcing transactions
to their next stages without leaving them accumulate changes

Ideally we would like txg_kick() to get triggered only when we are sure
that we are not syncing AND not quiescing any txg. This way we can kick
an open TXG to the quiescing state when we are sure that there is nothing
going on and we would benefit from the different states running
concurrently.

illumos/illumos-gate@fa41d87de9ec9000964c605eb01d6dc19e4a1abe

Reviewed by: Matt Ahrens <matt@delphix.com>
Reviewed by: Brad Lewis <brad.lewis@delphix.com>
Reviewed by: Andriy Gapon <avg@FreeBSD.org>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Serapheim Dimitropoulos <serapheim@delphix.com>

5 years ago9464 txg_kick() fails to see that we are quiescing, forcing transactions
Alexander Motin [Thu, 2 Aug 2018 20:17:37 +0000 (20:17 +0000)]
9464 txg_kick() fails to see that we are quiescing, forcing transactions
to their next stages without leaving them accumulate changes

Ideally we would like txg_kick() to get triggered only when we are sure
that we are not syncing AND not quiescing any txg. This way we can kick
an open TXG to the quiescing state when we are sure that there is nothing
going on and we would benefit from the different states running
concurrently.

illumos/illumos-gate@fa41d87de9ec9000964c605eb01d6dc19e4a1abe

Reviewed by: Matt Ahrens <matt@delphix.com>
Reviewed by: Brad Lewis <brad.lewis@delphix.com>
Reviewed by: Andriy Gapon <avg@FreeBSD.org>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Serapheim Dimitropoulos <serapheim@delphix.com>

5 years agoSilence newer gcc warnings.
Rick Macklem [Thu, 2 Aug 2018 20:10:59 +0000 (20:10 +0000)]
Silence newer gcc warnings.

Newer versions of gcc generate "might not be initialized" warnings for
several variables in nfsrpc_doiods().  I have checked and all of these
variables are assigned values before they are used.
In the one case of "tdrpc", it could have passed garbage as an argument
to nfscl_dofflayoutio() when mirrorcnt is one. However nfscl_dofflayoutio() only
uses the argument when mirrorcnt > 1, so it wasn't actually broken.
This patch initializes "tdrpc" to avoid confusion and initializes the rest
to make the compiler happy.

Requested by: mmacy

5 years agoMFV r337167: 9442 decrease indirect block size of spacemaps
Alexander Motin [Thu, 2 Aug 2018 20:06:46 +0000 (20:06 +0000)]
MFV r337167: 9442 decrease indirect block size of spacemaps

Updates to indirect blocks of spacemaps can contribute significantly to
write inflation.  Therefore we want to reduce the indirect block size of
spacemaps from 128K to 16K.

illumos/illumos-gate@221813c13b43ef48330b03725e00edee85108cf1

Reviewed by: Serapheim Dimitropoulos <serapheim.dimitro@delphix.com>
Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Albert Lee <trisk@forkgnu.org>
Reviewed by: Igor Kozhukhov <igor@dilos.org>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Matthew Ahrens <mahrens@delphix.com>

5 years agocxgbe(4): Use the tx credit limit for ethofld rather than TOE when
Navdeep Parhar [Thu, 2 Aug 2018 19:50:12 +0000 (19:50 +0000)]
cxgbe(4): Use the tx credit limit for ethofld rather than TOE when
initializing the softc for a per-flow rate limiter.  The limit happens
to be the same for both and the existing code worked by accident for
common configurations.

Reported by: gallatin@
Sponsored by: Chelsio Communications

5 years ago9442 decrease indirect block size of spacemaps
Alexander Motin [Thu, 2 Aug 2018 19:37:13 +0000 (19:37 +0000)]
9442 decrease indirect block size of spacemaps

Updates to indirect blocks of spacemaps can contribute significantly to
write inflation.  Therefore we want to reduce the indirect block size of
spacemaps from 128K to 16K.

illumos/illumos-gate@221813c13b43ef48330b03725e00edee85108cf1

Reviewed by: Serapheim Dimitropoulos <serapheim.dimitro@delphix.com>
Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Albert Lee <trisk@forkgnu.org>
Reviewed by: Igor Kozhukhov <igor@dilos.org>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Matthew Ahrens <mahrens@delphix.com>

5 years agoFUSE: Bump maximum IO size to enable more performant operation
Conrad Meyer [Thu, 2 Aug 2018 19:25:43 +0000 (19:25 +0000)]
FUSE: Bump maximum IO size to enable more performant operation

Various components restrict size of IO passed up to the userspace filesystem
based on the mount's f_iosize value.  The previous default of PAGE_SIZE
is anemic, even for normal filesystems, but especially considering every
FUSE operation involves a kernel <-> userspace IPC upcall.

Bump to DFLTPHYS (currently 64kB) to match other FUSE implementations.

Anecdotally, Jakub reports IO read performance increased from 600 MB/s ->
2700 MB/s with a basic RAM-backed FUSE filesystem.

PR: 230260
Reported by: Peter (MooseFS) <freebsd AT moosefs.com>
Tested by: Jakub Kruszona-Zawadzki <acid AT moosefs.com>
MFC after: 3 days

5 years agoMFV r337161: 9512 zfs remap poolname@snapname coredumps
Alexander Motin [Thu, 2 Aug 2018 19:13:45 +0000 (19:13 +0000)]
MFV r337161: 9512 zfs remap poolname@snapname coredumps

Only filesystems and volumes are valid "zfs remap" parameters: when passed
a snapshot name zfs_remap_indirects() does not handle the EINVAL returned
from libzfs_core, which results in failing an assertion and consequently
crashing.

illumos/illumos-gate@0b2e8253986c5c761129b58cfdac46d204903de1

Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: John Wren Kennedy <john.kennedy@delphix.com>
Reviewed by: Sara Hartse <sara.hartse@delphix.com>
Approved by: Matt Ahrens <mahrens@delphix.com>
Author:     loli10K <ezomori.nozomu@gmail.com>

5 years ago9512 zfs remap poolname@snapname coredumps
Alexander Motin [Thu, 2 Aug 2018 19:09:13 +0000 (19:09 +0000)]
9512 zfs remap poolname@snapname coredumps

Only filesystems and volumes are valid "zfs remap" parameters: when passed
a snapshot name zfs_remap_indirects() does not handle the EINVAL returned
from libzfs_core, which results in failing an assertion and consequently
crashing.

illumos/illumos-gate@0b2e8253986c5c761129b58cfdac46d204903de1

Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: John Wren Kennedy <john.kennedy@delphix.com>
Reviewed by: Sara Hartse <sara.hartse@delphix.com>
Approved by: Matt Ahrens <mahrens@delphix.com>
Author:     loli10K <ezomori.nozomu@gmail.com>

5 years agoDo not blindly include illumos kernel headers instead of user-space.
Alexander Motin [Thu, 2 Aug 2018 18:55:55 +0000 (18:55 +0000)]
Do not blindly include illumos kernel headers instead of user-space.
It is not needed now, and I doubt it much helped at all, creating more
confusions then good.

5 years agoFix the ftp-stage target for arm embedded builds.
Glen Barber [Thu, 2 Aug 2018 18:51:44 +0000 (18:51 +0000)]
Fix the ftp-stage target for arm embedded builds.

The images were renamed from KERNCONF to BOARDNAME when
specified, which would result in an image name of:

 12.0-CURRENT-arm-armv7-GENERIC.img

which would then be renamed to use the BOARDNAME for the
SoC the image is targeted to use.  BOARDNAME was specified
for all images as of r336994, which now causes the ftp-stage
target to fail, as the rename is no longer necessary.

Sponsored by: The FreeBSD Foundation

5 years agoRemove spuriously added svn properties
Ben Widawsky [Thu, 2 Aug 2018 18:37:02 +0000 (18:37 +0000)]
Remove spuriously added svn properties

5 years agotools: Add a git-svn bootstrap script
Ben Widawsky [Thu, 2 Aug 2018 18:28:02 +0000 (18:28 +0000)]
tools: Add a git-svn bootstrap script

codified version of https://wiki.freebsd.org/GitWorkflow/GitSvn#Using_git-svn

Approved by: emaste (mentor)
Suggested by: Warner Losh (imp)
Differential Revision:  https://reviews.freebsd.org/D16528

5 years agoAdd a rudimentary test for procstat kstack.
Mark Johnston [Thu, 2 Aug 2018 16:03:47 +0000 (16:03 +0000)]
Add a rudimentary test for procstat kstack.

MFC after: 1 week

5 years agoloader.efi: efipart_inithandles() failure should not prevent devsw initialization
Toomas Soome [Thu, 2 Aug 2018 12:43:40 +0000 (12:43 +0000)]
loader.efi: efipart_inithandles() failure should not prevent devsw initialization

The efipart_inithandles() can return error code when there are no block devices,
however, we still should walk and initialize devsw.

5 years agoRegen src.conf.5 after r337057, LLD_BOOTSTRAP on armv7
Ed Maste [Thu, 2 Aug 2018 12:39:23 +0000 (12:39 +0000)]
Regen src.conf.5 after r337057, LLD_BOOTSTRAP on armv7

5 years agoImplement pt_fpreg_to_ucontext(), pt_ucontext_to_fpreg().
Ruslan Bukin [Thu, 2 Aug 2018 12:24:34 +0000 (12:24 +0000)]
Implement pt_fpreg_to_ucontext(), pt_ucontext_to_fpreg().

Sponsored by: DARPA, AFRL

5 years agoSave and restore floating-point arguments.
Ruslan Bukin [Thu, 2 Aug 2018 12:21:39 +0000 (12:21 +0000)]
Save and restore floating-point arguments.

Sponsored by: DARPA, AFRL

5 years agoDon't overwrite tp in set_mcontext().
Ruslan Bukin [Thu, 2 Aug 2018 12:13:52 +0000 (12:13 +0000)]
Don't overwrite tp in set_mcontext().

This makes libthr/swapcontext_test:swapcontext1 happy.

Sponsored by: DARPA, AFRL

5 years agoo Don't overwrite tp in fork_trampoline().
Ruslan Bukin [Thu, 2 Aug 2018 12:12:13 +0000 (12:12 +0000)]
o Don't overwrite tp in fork_trampoline().
o Save and restore tp in cpu_switch().
o Restore tp in cpu_throw().
o Save tp in savectx().

This makes libthr tests happy. In particular fork_test:fork.

Sponsored by: DARPA, AFRL

5 years agoo Correctly set user tls base: consider TP_OFFSET.
Ruslan Bukin [Thu, 2 Aug 2018 12:08:52 +0000 (12:08 +0000)]
o Correctly set user tls base: consider TP_OFFSET.
o Ensure tp (thread pointer) saved before copying the pcb.

Sponsored by: DARPA, AFRL

5 years agoFix regression tests broken by r337067.
Edward Tomasz Napierala [Thu, 2 Aug 2018 11:55:16 +0000 (11:55 +0000)]
Fix regression tests broken by r337067.

MFC after: 2 weeks
Sponsored by: DARPA, AFRL

5 years agofix a typo resulting in a wrong variable in kern_syscall_deregister
Andriy Gapon [Thu, 2 Aug 2018 09:41:55 +0000 (09:41 +0000)]
fix a typo resulting in a wrong variable in kern_syscall_deregister

The difference is between sysent, a global, and sysents, a function
parameter.

5 years agoMake sure the rtld(1) error messages go to stderr, not stdout.
Edward Tomasz Napierala [Thu, 2 Aug 2018 07:43:28 +0000 (07:43 +0000)]
Make sure the rtld(1) error messages go to stderr, not stdout.
While here fix capitalization of a few nearby strings, add the
rtld's file name prefix so it's obvious where the message come
from, and return zero when "-h" is used.

Reviewed by: kib
MFC after: 2 weeks
Sponsored by: DARPA, AFRL
Differential Revision: https://reviews.freebsd.org/D16530

5 years agolibsa: dereferencing type-punned pointer in cd9660
Toomas Soome [Thu, 2 Aug 2018 06:22:10 +0000 (06:22 +0000)]
libsa: dereferencing type-punned pointer in cd9660

The warning is given by gcc build, but it is good to fix anyhow.
use bcopy instead of direct assignment.

5 years agoMFV r316926:
Alexander Motin [Wed, 1 Aug 2018 21:51:49 +0000 (21:51 +0000)]
MFV r316926:
7955 libshare needs to initialize only those datasets being modified by the consumer

illumos/illumos-gate@8a981c3356b194b3b5c0ae9276a9cc31cd2f93a3
https://github.com/illumos/illumos-gate/commit/8a981c3356b194b3b5c0ae9276a9cc31cd2f93a3

https://www.illumos.org/issues/7955
  Libshare currently initializes all available filesystems when doing any
  libshare operation. This requires iterating through all the filesystem
  multiple times, which is a huge performance problem for sharing and
  unsharing operations.

Reviewed by: Steve Gonczi <steve.gonczi@delphix.com>
Reviewed by: Sebastien Roy <sebastien.roy@delphix.com>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Pavel Zakharov <pavel.zakharov@delphix.com>
Reviewed by: Yuri Pankov <yuri.pankov@gmail.com>
Approved by: Gordon Ross <gordon.w.ross@gmail.com>
Author: Daniel Hoffman <dj.hoffman@delphix.com>

For FreeBSD this is practically a NOP, just a diff reduction.

5 years agoubldr: Bump heap size, 1MB -> 2MB
Kyle Evans [Wed, 1 Aug 2018 20:08:20 +0000 (20:08 +0000)]
ubldr: Bump heap size, 1MB -> 2MB

1MB was leaving very little margin in some of the worse-case scenarios with
lualoader. 2MB is still low enough that we shouldn't have any problems with
UBoot-supported boards.

MFC after: 1 week

5 years agoFix some nits in the unix_passfd tests.
Mark Johnston [Wed, 1 Aug 2018 19:45:04 +0000 (19:45 +0000)]
Fix some nits in the unix_passfd tests.

- Remove return statements in functions with a void return type.
- Allocate enough space for the SCM_CREDS and SCM_RIGHTS messages
  received in the rights_creds_payload test.

MFC after: 1 week
Sponsored by: The FreeBSD Foundation

5 years agoUse lld as the bootstrap linker on armv7 by default
Ed Maste [Wed, 1 Aug 2018 19:17:55 +0000 (19:17 +0000)]
Use lld as the bootstrap linker on armv7 by default

As of r336972 lld is capable linking the armv7 kernel and userland,
so enable it by default.

PR: 229050
Reviewed by: kevans
Tested by: kevans
Relnotes: Yes
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D16528

5 years agoDon't refer to non-existing atomic functions, even though not compiled,
Hans Petter Selasky [Wed, 1 Aug 2018 19:10:46 +0000 (19:10 +0000)]
Don't refer to non-existing atomic functions, even though not compiled,
in the LinuxKPI.

Found by: rpolka @
MFC after: 1 week
Sponsored by: Mellanox Technologies

5 years agoAvoid assertion in /dev/ufssuspend when the suspend ioctl is
Konstantin Belousov [Wed, 1 Aug 2018 19:06:55 +0000 (19:06 +0000)]
Avoid assertion in /dev/ufssuspend when the suspend ioctl is
(incorrectly) called while another suspension is already active.

PR: 230220
Reported by: dexuan
Tested by: pho
Sponsored by: The FreeBSD Foundation
MFC after: 1 week

5 years agoAdd -D option to pciconf(8) to mmap and dump content of the device BAR.
Konstantin Belousov [Wed, 1 Aug 2018 19:02:05 +0000 (19:02 +0000)]
Add -D option to pciconf(8) to mmap and dump content of the device BAR.

Discussed with: imp, jhb
Sponsored by: The FreeBSD Foundation, Mellanox Technologies
MFC after: 2 weeks
Differential revision: https://reviews.freebsd.org/D15583

5 years agoAdd ioctl to conveniently mmap a PCI device BAR into userspace.
Konstantin Belousov [Wed, 1 Aug 2018 18:58:24 +0000 (18:58 +0000)]
Add ioctl to conveniently mmap a PCI device BAR into userspace.

Add the ioctl PCIOCBARMMAP on /dev/pci to conveniently create
userspace mapping of a PCI device BAR.  This is enormously superior to
read the BAR value with PCIOCREAD and then try to mmap /dev/mem, and
should allow to automatically activate the mapped BARs when needed in
future.

Current implementation creates new sg pager for each user mmap
request.  If the pointer (and reference) to a managed device pager is
stored in pci_map, we would be able to revoke all mappings on the BAR
deactivation or relocation.  This is related to the unimplemented BAR
activation on mmap, and is postponed for the future.

Discussed with: imp, jhb
Sponsored by: The FreeBSD Foundation, Mellanox Technologies
MFC after: 2 weeks
Differential revision: https://reviews.freebsd.org/D15583

5 years agoRemove ARGS_NUM, accidentally left over after r337050.
Mark Johnston [Wed, 1 Aug 2018 18:49:40 +0000 (18:49 +0000)]
Remove ARGS_NUM, accidentally left over after r337050.

5 years agoAdd pmap_is_valid_memattr(9).
Konstantin Belousov [Wed, 1 Aug 2018 18:45:51 +0000 (18:45 +0000)]
Add pmap_is_valid_memattr(9).

Discussed with: alc
Sponsored by: The FreeBSD Foundation, Mellanox Technologies
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D15583

5 years agoDon't hard-code the number of compression utility arguments.
Mark Johnston [Wed, 1 Aug 2018 18:45:33 +0000 (18:45 +0000)]
Don't hard-code the number of compression utility arguments.

The zstd invocation constructed by newsyslog contains one more parameter
than invocations for the other supported compression utilities.  However,
the maximum number of arguments was hard-coded, leading to an
out-of-bounds array access when using zstd compression.

5 years agoAdjust the number of tests after r336913.
Mark Johnston [Wed, 1 Aug 2018 18:41:43 +0000 (18:41 +0000)]
Adjust the number of tests after r336913.

5 years agoMake cache coherency attributes definitions available in machine/vm.h on MIPS.
Konstantin Belousov [Wed, 1 Aug 2018 18:35:17 +0000 (18:35 +0000)]
Make cache coherency attributes definitions available in machine/vm.h on MIPS.

Move definitions from cpuregs.h into the cca.h, and include cca.h into vm.h.
This is required to make MIPS MD memattr definitions usable in userspace.

Sponsored by: The FreeBSD Foundation, Mellanox Technologies
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D15583

5 years ago8115 parallel zfs mount
Alexander Motin [Wed, 1 Aug 2018 18:28:17 +0000 (18:28 +0000)]
8115 parallel zfs mount

Mounting of filesystems in "filesystem/local" is done using `zfs mount -a`,
which mounts each filesystems serially. The bottleneck for each mount is
the I/O done to load metadata for each filesystem. As such, mounting
filesystems using a parallel algorithm should be a big win, and bring down
the runtime of "filesystem/local"'s start method.

illumos/illumos-gate@591e0e133f9980083db5d64ac33a30bcc3382ff7

Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Pavel Zakharov <pavel.zakharov@delphix.com>
Reviewed by: Brad Lewis <brad.lewis@delphix.com>
Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Paul Dagnelie <pcd@delphix.com>
Reviewed by: Prashanth Sreenivasa <pks@delphix.com>
Approved by: Matt Ahrens <mahrens@delphix.com>
Author:     Sebastien Roy <seb@delphix.com>

5 years agolibelf: reload section headers after update with ELF_C_WRITE
Ed Maste [Wed, 1 Aug 2018 15:55:14 +0000 (15:55 +0000)]
libelf: reload section headers after update with ELF_C_WRITE

These issues (PR 218860 and PR 218861) are still undergoing additional
discussion in the upstream context and there may be additional changes
to come.

PR: 218860
Submitted by: Eric McCorkle
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D10486

5 years agoMake sure that ENTRY() and END() refer to the same symbol.
Mark Johnston [Wed, 1 Aug 2018 15:50:42 +0000 (15:50 +0000)]
Make sure that ENTRY() and END() refer to the same symbol.

X-MFC with: r336876

5 years agosnd_hda: Synchronize DMA buffers for the control path
Justin Hibbits [Wed, 1 Aug 2018 14:50:41 +0000 (14:50 +0000)]
snd_hda: Synchronize DMA buffers for the control path

Make sure both sides of the DMA buffer memory accesses for the CORB and RIRB
(control buffers) in snd_hda (device and CPU) can see coherent memory.  This
is needed on weakly ordered architectures including PowerPC and ARM.  Patch
originally by mmel, with small changes.

This does not cover the data path of snd_hda.  We don't have sync operations
for in-progress DMA buffers, to sync ranges of a map.

Reviewed By: mmel
Differential Revision: https://reviews.freebsd.org/D16517

5 years agoAdd a missing "Ar" macro to the description of the -R flag in the manpage.
Mateusz Piotrowski [Wed, 1 Aug 2018 12:18:52 +0000 (12:18 +0000)]
Add a missing "Ar" macro to the description of the -R flag in the manpage.

Approved by: bjk (doc committer), krion (mentor)
Differential Revision: https://reviews.freebsd.org/D16520

5 years agolibsa: assignment to char * from u_char *
Toomas Soome [Wed, 1 Aug 2018 12:14:10 +0000 (12:14 +0000)]
libsa: assignment to char * from u_char *

Cast to char * instead of u_char *

5 years agolibsa: bootp is using pointers with different sign
Toomas Soome [Wed, 1 Aug 2018 12:06:39 +0000 (12:06 +0000)]
libsa: bootp is using pointers with different sign

Just change bp_file to char and same for variable s.

5 years agolibsa: pointer differs in signedness
Toomas Soome [Wed, 1 Aug 2018 11:40:52 +0000 (11:40 +0000)]
libsa: pointer differs in signedness

A small cleanup, fix the argument type and while there, replace (char *)0 with
NULL.

5 years agoRemove jedec_ts(4)
Ravi Pokala [Wed, 1 Aug 2018 08:24:34 +0000 (08:24 +0000)]
Remove jedec_ts(4)

The jedec_ts(4) driver has been marked as deprecated in stable/11, and is
now being removed from -HEAD. Add a notice in UPDATING, and update the few
remaining references (regarding jedec_dimm(4)'s compatibility and history)
to reflect the fact that jedec_ts(4) is now deleted.

Reviewed by: avg
Relnotes: yes
Differential Revision: https://reviews.freebsd.org/D16537

5 years agoRemove MT_NTYPES.
Mark Johnston [Wed, 1 Aug 2018 03:52:48 +0000 (03:52 +0000)]
Remove MT_NTYPES.

Its last reference was removed in r253361.

5 years agoRequire that MAC label buffers be able to store a non-empty string.
Mark Johnston [Wed, 1 Aug 2018 03:46:07 +0000 (03:46 +0000)]
Require that MAC label buffers be able to store a non-empty string.

The buffer size may be used to initialize an sbuf in
MAC_POLICY_EXTERNALIZE, and without this constraint it's possible to
trigger an assertion failure in the sbuf code.  With INVARIANTS
disabled, the first attempt to write to the sbuf will fail.

Reported by: pho
Reviewed by: delphij
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D16527

5 years agoMFV r337029:
Alexander Motin [Wed, 1 Aug 2018 03:21:17 +0000 (03:21 +0000)]
MFV r337029:
9426 metaslab size can exceed offset addressable by spacemap

metaslab size can exceed offset addressable by spacemap. The vdev can
address up to 2^63 * SPA_MAXBLOCKSIZE (512). A metaslab can address up to
2^47 * 2^vdev_ashift. Therefore we may need to increase the number of
metaslabs so that the maximum metaslab size is capped at the amount that
can be addressed by the spacemap. This should happen in
vdev_metaslab_set_size().

illumos/illumos-gate@b4bf0cf0458759c67920a031021a9d96cd683cfe

Reviewed by: Paul Dagnelie <pcd@delphix.com>
Reviewed by: Matt Ahrens <matt@delphix.com>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Don Brady <don.brady@delphix.com>

5 years ago9426 metaslab size can exceed offset addressable by spacemap
Alexander Motin [Wed, 1 Aug 2018 03:19:30 +0000 (03:19 +0000)]
9426 metaslab size can exceed offset addressable by spacemap

metaslab size can exceed offset addressable by spacemap. The vdev can
address up to 2^63 * SPA_MAXBLOCKSIZE (512). A metaslab can address up to
2^47 * 2^vdev_ashift. Therefore we may need to increase the number of
metaslabs so that the maximum metaslab size is capped at the amount that
can be addressed by the spacemap. This should happen in
vdev_metaslab_set_size().

illumos/illumos-gate@b4bf0cf0458759c67920a031021a9d96cd683cfe

Reviewed by: Paul Dagnelie <pcd@delphix.com>
Reviewed by: Matt Ahrens <matt@delphix.com>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Don Brady <don.brady@delphix.com>

5 years agoMFV r337027:
Alexander Motin [Wed, 1 Aug 2018 03:07:33 +0000 (03:07 +0000)]
MFV r337027:
9328 zap code can take advantage of c99
9329 panic in zap_leaf_lookup() due to concurrent zapification

illumos/illumos-gate@bf26014c5541b6119f34e0d95294b7f2eb105ac2

Reviewed by: Steve Gonczi <steve.gonczi@delphix.com>
Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Pavel Zakharov <pavel.zakharov@delphix.com>
Reviewed by: Brad Lewis <brad.lewis@delphix.com>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Matthew Ahrens <mahrens@delphix.com>

5 years ago9328 zap code can take advantage of c99
Alexander Motin [Wed, 1 Aug 2018 03:03:15 +0000 (03:03 +0000)]
9328 zap code can take advantage of c99
9329 panic in zap_leaf_lookup() due to concurrent zapification

illumos/illumos-gate@bf26014c5541b6119f34e0d95294b7f2eb105ac2

Reviewed by: Steve Gonczi <steve.gonczi@delphix.com>
Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Pavel Zakharov <pavel.zakharov@delphix.com>
Reviewed by: Brad Lewis <brad.lewis@delphix.com>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Matthew Ahrens <mahrens@delphix.com>

5 years agoAs non-sparc64 undconditionally returns 1, simplify #ifdefs.
Cy Schubert [Wed, 1 Aug 2018 02:59:56 +0000 (02:59 +0000)]
As non-sparc64 undconditionally returns 1, simplify #ifdefs.

MFC after: 1 week

5 years agoMFV r337022:
Alexander Motin [Wed, 1 Aug 2018 02:39:44 +0000 (02:39 +0000)]
MFV r337022:
9403 assertion failed in arc_buf_destroy() when concurrently reading block with checksum error

This assertion (VERIFY) failure was reported when reading a block. Turns out
the problem is that if we get an i/o error (ECKSUM in this case), and there
are multiple concurrent ARC reads of the same block (from different clones),
then the ARC will put multiple buf's on the same ANON hdr, which isn't
supposed to happen, and then causes a panic when we try to arc_buf_destroy()
the buf.

illumos/illumos-gate@fa98e487a9619b7902f218663be219e787a57dad

Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Paul Dagnelie <pcd@delphix.com>
Reviewed by: Pavel Zakharov <pavel.zakharov@delphix.com>
Approved by: Matt Ahrens <mahrens@delphix.com>
Author:     Matthew Ahrens <mahrens@delphix.com>

5 years ago- Add the ability to run bhyve(8) within a jail(8).
Marcelo Araujo [Wed, 1 Aug 2018 00:39:21 +0000 (00:39 +0000)]
- Add the ability to run bhyve(8) within a jail(8).

This patch adds a new sysctl(8) knob "security.jail.vmm_allowed",
by default this option is disable.

Submitted by: Shawn Webb <shawn.webb____hardenedbsd.org>
Reviewed by: jamie@ and myself.
Relnotes: Yes.
Sponsored by: HardenedBSD and G2, Inc.
Differential Revision: https://reviews.freebsd.org/D16057

5 years ago9403 assertion failed in arc_buf_destroy() when concurrently reading block with check...
Alexander Motin [Tue, 31 Jul 2018 23:44:13 +0000 (23:44 +0000)]
9403 assertion failed in arc_buf_destroy() when concurrently reading block with checksum error

This assertion (VERIFY) failure was reported when reading a block. Turns out
the problem is that if we get an i/o error (ECKSUM in this case), and there
are multiple concurrent ARC reads of the same block (from different clones),
then the ARC will put multiple buf's on the same ANON hdr, which isn't
supposed to happen, and then causes a panic when we try to arc_buf_destroy()
the buf.

illumos/illumos-gate@fa98e487a9619b7902f218663be219e787a57dad

Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Paul Dagnelie <pcd@delphix.com>
Reviewed by: Pavel Zakharov <pavel.zakharov@delphix.com>
Approved by: Matt Ahrens <mahrens@delphix.com>
Author:     Matthew Ahrens <mahrens@delphix.com>

5 years agoMFV r337020:9443 panic when scrub a v10 pool
Alexander Motin [Tue, 31 Jul 2018 23:00:58 +0000 (23:00 +0000)]
MFV r337020:9443 panic when scrub a v10 pool

illumos/illumos-gate@bb1f424574ac8e08069d0ba993c2a41ffe796794

Reviewed by: Serapheim Dimitropoulos <serapheim.dimitro@delphix.com>
Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Andriy Gapon <avg@FreeBSD.org>
Reviewed by: Igor Kozhukhov <igor@dilos.org>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Matthew Ahrens <mahrens@delphix.com>

5 years ago9443 panic when scrub a v10 pool
Alexander Motin [Tue, 31 Jul 2018 22:59:48 +0000 (22:59 +0000)]
9443 panic when scrub a v10 pool

illumos/illumos-gate@bb1f424574ac8e08069d0ba993c2a41ffe796794

Reviewed by: Serapheim Dimitropoulos <serapheim.dimitro@delphix.com>
Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Andriy Gapon <avg@FreeBSD.org>
Reviewed by: Igor Kozhukhov <igor@dilos.org>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Matthew Ahrens <mahrens@delphix.com>

5 years agoAdd a dtrace provider for UDP-Lite.
Michael Tuexen [Tue, 31 Jul 2018 22:56:03 +0000 (22:56 +0000)]
Add a dtrace provider for UDP-Lite.

The dtrace provider for UDP-Lite is modeled after the UDP provider.
This fixes the bug that UDP-Lite packets were triggering the UDP
provider.
Thanks to dteske@ for providing the dwatch module.

Reviewed by: dteske@, markj@, rrs@
Relnotes: yes
Differential Revision: https://reviews.freebsd.org/D16377

5 years agoMFV r337014:
Alexander Motin [Tue, 31 Jul 2018 22:50:50 +0000 (22:50 +0000)]
MFV r337014:
9421 zdb should detect and print out the number of "leaked" objects
9422 zfs diff and zdb should explicitly mark objects that are on the deleted queue

illumos/illumos-gate@20b5dafb425396adaebd0267d29e1026fc4dc413

Reviewed by: Matt Ahrens <matt@delphix.com>
Reviewed by: Pavel Zakharov <pavel.zakharov@delphix.com>
Approved by: Matt Ahrens <mahrens@delphix.com>
Author:     Paul Dagnelie <pcd@delphix.com>

5 years ago9237 "zpool add" fails for very large pools
Alexander Motin [Tue, 31 Jul 2018 21:42:31 +0000 (21:42 +0000)]
9237 "zpool add" fails for very large pools

illumos/illumos-gate@ae5ee1bd5e54409b4589217b160c8cf4b81e2fb8

Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Andriy Gapon <avg@FreeBSD.org>
Approved by: Matt Ahrens <mahrens@delphix.com>
Author:     Alan Somers <asomers@gmail.com>

5 years agoCOMPAT_LINUX32 has not depended on COMPAT_43 in some time.
Mark Johnston [Tue, 31 Jul 2018 21:40:13 +0000 (21:40 +0000)]
COMPAT_LINUX32 has not depended on COMPAT_43 in some time.

MFC after: 3 days

5 years ago9421 zdb should detect and print out the number of "leaked" objects
Alexander Motin [Tue, 31 Jul 2018 21:31:24 +0000 (21:31 +0000)]
9421 zdb should detect and print out the number of "leaked" objects
9422 zfs diff and zdb should explicitly mark objects that are on the deleted queue

illumos/illumos-gate@20b5dafb425396adaebd0267d29e1026fc4dc413

Reviewed by: Matt Ahrens <matt@delphix.com>
Reviewed by: Pavel Zakharov <pavel.zakharov@delphix.com>
Approved by: Matt Ahrens <mahrens@delphix.com>
Author:     Paul Dagnelie <pcd@delphix.com>

5 years ago9194 mechanism to override ashift at pool creation time
Alexander Motin [Tue, 31 Jul 2018 21:26:03 +0000 (21:26 +0000)]
9194 mechanism to override ashift at pool creation time

illumos/illumos-gate@93a1902e519bf492c071b48ffb93e5c1c7b53fb9

Reviewed by: Serapheim Dimitropoulos <serapheim@delphix.com>
Reviewed by: Prakash Surya <prakash.surya@delphix.com>
Reviewed by: Allan Jude <allanjude@freebsd.org>
Reviewed by: Igor Kozhukhov <igor@dilos.org>
Reviewed by: Richard Elling <Richard.Elling@RichardElling.com>
Approved by: Dan McDonald <danmcd@joyent.com>
Author:     Matthew Ahrens <mahrens@delphix.com>

5 years agobump lld version number after r336972 arm(v7) VFP tag support
Ed Maste [Tue, 31 Jul 2018 21:06:28 +0000 (21:06 +0000)]
bump lld version number after r336972 arm(v7) VFP tag support

Reported by: kevans
Sponsored by: The FreeBSD Foundation

5 years agoMFV r336991, r337001:
Alexander Motin [Tue, 31 Jul 2018 21:06:04 +0000 (21:06 +0000)]
MFV r336991, r337001:
9102 zfs should be able to initialize storage devices

The first access to a disk block can incur a performance penalty on some
platforms (e.g. AWS's EBS, VMware VMDKs). Therefore it is recommended that
volumes be "thick provisioned", where supported by the platform (VMware).
Thick provisioning is time consuming and often is ignored. If the thick
provision step is omitted, customers will see suboptimal performance until
we have written to all parts of the LUN. ZFS should be able to initialize
any unused storage to remove any first-write penalty that exists.

illumos/illumos-gate@094e47e980b0796b94b1b8f51f462a64d246e516

Reviewed by: John Wren Kennedy <john.kennedy@delphix.com>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Pavel Zakharov <pavel.zakharov@delphix.com>
Reviewed by: Prakash Surya <prakash.surya@delphix.com>
Approved by: Richard Lowe <richlowe@richlowe.net>
Author:     George Wilson <george.wilson@delphix.com>

5 years agoofw_cpu: Add support for getting cpu clock via clock property
Emmanuel Vadot [Tue, 31 Jul 2018 20:50:50 +0000 (20:50 +0000)]
ofw_cpu: Add support for getting cpu clock via clock property

Nominal Mhz is either expressed via the clock-frequency property
or can be get via the clock property that holds the cpu clock.
Add support for the later.

Reviewed by: nwhitehorn
Differential Revision: https://reviews.freebsd.org/D16346

5 years ago9434 Speculative prefetch is blocked by device removal code
Alexander Motin [Tue, 31 Jul 2018 19:30:08 +0000 (19:30 +0000)]
9434 Speculative prefetch is blocked by device removal code

illumos/illumos-gate@47b8d4b884f2dab4e4c6952b40fd740a8fc4ab32

Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Prashanth Sreenivasa <pks@delphix.com>
Approved by: Matt Ahrens <mahrens@delphix.com>
Author:     Alexander Motin <mav@FreeBSD.org>

5 years agoAdd new files missed in r336991.
Alexander Motin [Tue, 31 Jul 2018 19:23:27 +0000 (19:23 +0000)]
Add new files missed in r336991.

5 years agorelease: arm64: Add PINE64-LTS configuration file
Emmanuel Vadot [Tue, 31 Jul 2018 19:14:52 +0000 (19:14 +0000)]
release: arm64: Add PINE64-LTS configuration file

Pine64 isn't produced anymore but Pine64-LTS is.
This image works on the LTS release and the Sopine module.

Reviewed by: gjb
Relnotes: yes
Differential Revision: https://reviews.freebsd.org/D16487

5 years agorelease: arm: Enable multicons for arm64
Emmanuel Vadot [Tue, 31 Jul 2018 19:13:50 +0000 (19:13 +0000)]
release: arm: Enable multicons for arm64

Since we have now EFI framebuffer enabled for ARM64 if we boot on a board
with an screen, u-boot will set up a EFI GOP framebuffer and we won't boot
using the serial console.
Also on RPI3 the firmware always setup the framebuffer area resulting in u-boot
always setup the EFI GOP and FreeBSD never using the serial console.

Reviewed by: gjb, lwshu (previous version)
Differential Revision: https://reviews.freebsd.org/D16472

5 years agorelease: arm: Always boot armv6/v7 image with EFI
Emmanuel Vadot [Tue, 31 Jul 2018 19:12:31 +0000 (19:12 +0000)]
release: arm: Always boot armv6/v7 image with EFI

boot.scr is a u-boot script that loads and execute ubldr.bin
If not present u-boot will automatically boot loader.efi which
is already installed.

This means that all armv6/armv7 images are now booted via EFI

Tested-On: RPI-B
Tested-On: RPI2
Tested-On: OrangePi One
Tested-On: All lot of other boards
MFC after: Never
Relnotes: yes

5 years agorelease: Restore copy of boot.scr for some board
Emmanuel Vadot [Tue, 31 Jul 2018 19:10:50 +0000 (19:10 +0000)]
release: Restore copy of boot.scr for some board

This is not a problem for 12-CURRENT as EFI boot works but it doesn't
for 11.
While here some board arm_install_uboot also copy ubldr.bin et create
firstboot files but it's already done in arm_install_boot

Reviewed by: gjb
MFC after: 3 days
Differential Revision: https://reviews.freebsd.org/D16481

5 years agonvmem: Add nvmem interface and helpers
Emmanuel Vadot [Tue, 31 Jul 2018 19:08:24 +0000 (19:08 +0000)]
nvmem: Add nvmem interface and helpers

The nvmem interface helps provider of nvmem data to expose themselves to consumer.
NVMEM is generally present on some embedded board in a form of eeprom or fuses.
The nvmem api are helpers for consumer to read/write the cell data from a provider.

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

5 years agorelease: Deinstall u-boot ports before installing
Emmanuel Vadot [Tue, 31 Jul 2018 18:57:11 +0000 (18:57 +0000)]
release: Deinstall u-boot ports before installing

FORCE_PKG_REGISTER is broken so multiple invocation of release.sh for the
same board will fails if /scratch isn't cleaned.
Leave it but deinstall the package first.

Reviewed by: gjb
Differential Revision: https://reviews.freebsd.org/D16513

5 years agorelease: arm: Use BOARDNAME in the image name
Emmanuel Vadot [Tue, 31 Jul 2018 18:55:44 +0000 (18:55 +0000)]
release: arm: Use BOARDNAME in the image name

Using KERNEL made sense when all boards had different kernel configuration.
Now that all of them are using GENERIC use the board name instead

Reviewed by: gjb
Differential Revision: https://reviews.freebsd.org/D16512

5 years agorelease: rpi-b: add BOARDNAME variable
Emmanuel Vadot [Tue, 31 Jul 2018 18:54:06 +0000 (18:54 +0000)]
release: rpi-b: add BOARDNAME variable

Reviewed by: gjb
Differential Revision: https://reviews.freebsd.org/D16514