<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/sys/modules/dtrace, branch release/13.1.0</title>
<subtitle>FreeBSD source tree</subtitle>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/'/>
<entry>
<title>Export symbols from opensolaris.ko and dtrace.ko</title>
<updated>2021-11-24T15:55:37+00:00</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2021-11-17T16:01:59+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=f69572733023aa8017bddc5bed24358d3bc14847'/>
<id>f69572733023aa8017bddc5bed24358d3bc14847</id>
<content type='text'>
Both modules provide many symbols used by various DTrace provider
modules, so just export everything.

Sponsored by:	The FreeBSD Foundation

(cherry picked from commit 8a693ccf86f90469910c5b2425ddb8a75e298487)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Both modules provide many symbols used by various DTrace provider
modules, so just export everything.

Sponsored by:	The FreeBSD Foundation

(cherry picked from commit 8a693ccf86f90469910c5b2425ddb8a75e298487)
</pre>
</div>
</content>
</entry>
<entry>
<title>dtrace: Fix /"string" == NULL/ comparisons using an uninitialized value.</title>
<updated>2021-01-08T22:37:17+00:00</updated>
<author>
<name>Bryan Drewery</name>
<email>bdrewery@FreeBSD.org</email>
</author>
<published>2020-12-18T17:58:03+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=f222a6b88614db13ae83c8110281e690d1381a4c'/>
<id>f222a6b88614db13ae83c8110281e690d1381a4c</id>
<content type='text'>
A test of this is funcs/tst.strtok.d which has this filter:

    BEGIN
    /(this-&gt;field = strtok(this-&gt;str, ",")) == NULL/
    {
            exit(1);
    }
The test will randomly fail with exit status of 1 indicating that this-&gt;field
was NULL even though printing it out shows it is not.

This is compiled to the DTrace instruction set:
    // Pushed arguments not shown here
    // call strtok() and set result into %r1
    07: 2f001f01    call DIF_SUBR(31), %r1          ! strtok
    // set thread local scalar this-&gt;field from %r1
    08: 39050101    stls %r1, DT_VAR(1281)          ! DT_VAR(1281) = "field"
    // Prepare for the == comparison
    // Set right side of %r2 to NULL
    09: 25000102    setx DT_INTEGER[1], %r2         ! 0x0
    // string compare %r1 (strtok result) to %r2
    10: 27010200    scmp %r1, %r2

In this case only %r1 is loaded with a string limit set to lim1.  %r2 being
NULL does not get loaded and does not set lim2.  Then we call dtrace_strncmp()
with MIN(lim1, lim2) resulting in passing 0 and comparing neither side.
dtrace_strncmp() handles this case fine and it already has been while
being lucky with what lim2 was [un]initialized as.

Reviewed by:	markj, Don Morris &lt;dgmorris AT earthlink.net&gt;
Sponsored by:	Dell EMC
Differential Revision:	https://reviews.freebsd.org/D27671
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
A test of this is funcs/tst.strtok.d which has this filter:

    BEGIN
    /(this-&gt;field = strtok(this-&gt;str, ",")) == NULL/
    {
            exit(1);
    }
The test will randomly fail with exit status of 1 indicating that this-&gt;field
was NULL even though printing it out shows it is not.

This is compiled to the DTrace instruction set:
    // Pushed arguments not shown here
    // call strtok() and set result into %r1
    07: 2f001f01    call DIF_SUBR(31), %r1          ! strtok
    // set thread local scalar this-&gt;field from %r1
    08: 39050101    stls %r1, DT_VAR(1281)          ! DT_VAR(1281) = "field"
    // Prepare for the == comparison
    // Set right side of %r2 to NULL
    09: 25000102    setx DT_INTEGER[1], %r2         ! 0x0
    // string compare %r1 (strtok result) to %r2
    10: 27010200    scmp %r1, %r2

In this case only %r1 is loaded with a string limit set to lim1.  %r2 being
NULL does not get loaded and does not set lim2.  Then we call dtrace_strncmp()
with MIN(lim1, lim2) resulting in passing 0 and comparing neither side.
dtrace_strncmp() handles this case fine and it already has been while
being lucky with what lim2 was [un]initialized as.

Reviewed by:	markj, Don Morris &lt;dgmorris AT earthlink.net&gt;
Sponsored by:	Dell EMC
Differential Revision:	https://reviews.freebsd.org/D27671
</pre>
</div>
</content>
</entry>
<entry>
<title>openzfs: fix gcc kernel module builds</title>
<updated>2020-12-27T22:33:13+00:00</updated>
<author>
<name>Ryan Libby</name>
<email>rlibby@FreeBSD.org</email>
</author>
<published>2020-12-27T22:33:13+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=d021434a796008efbb93616f5297ed2f55a1a230'/>
<id>d021434a796008efbb93616f5297ed2f55a1a230</id>
<content type='text'>
 - Suppress -Wredundant-decls.  Ultimately this warning is harmless in
   any case, and it does not look like there is a simple way to avoid
   redundant declarations in this case without a lot of header pollution
   (e.g. having openzfs's shim param.h pulling in sys/kernel.h for hz).
 - Suppress -Wnested-externs, which is useless anyway.

Unfortunately it was not sufficient just to modify OPENZFS_CFLAGS,
because the warning suppressions need to appear on the command line
after they are explicitly enabled by CWARNFLAGS from sys/conf/kern.mk,
but OPENZFS_CFLAGS get added before due to use of -I for the shims.

Reviewed by:	markj
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D27685
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
 - Suppress -Wredundant-decls.  Ultimately this warning is harmless in
   any case, and it does not look like there is a simple way to avoid
   redundant declarations in this case without a lot of header pollution
   (e.g. having openzfs's shim param.h pulling in sys/kernel.h for hz).
 - Suppress -Wnested-externs, which is useless anyway.

Unfortunately it was not sufficient just to modify OPENZFS_CFLAGS,
because the warning suppressions need to appear on the command line
after they are explicitly enabled by CWARNFLAGS from sys/conf/kern.mk,
but OPENZFS_CFLAGS get added before due to use of -I for the shims.

Reviewed by:	markj
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D27685
</pre>
</div>
</content>
</entry>
<entry>
<title>Update OpenZFS to 2.0.0-rc3-gfc5966</title>
<updated>2020-10-17T01:06:04+00:00</updated>
<author>
<name>Matt Macy</name>
<email>mmacy@FreeBSD.org</email>
</author>
<published>2020-10-17T01:06:04+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=180f822596ecc49d3074dcc9dfea9628aae1d48d'/>
<id>180f822596ecc49d3074dcc9dfea9628aae1d48d</id>
<content type='text'>
- fix panic due to tqid overflow
- Improve libzfs_error_init messages
- Expose zfetch_max_idistance tunable
- Make dbufstat work on FreeBSD
- Fix EIO after resuming receive of new dataset over an existing one
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- fix panic due to tqid overflow
- Improve libzfs_error_init messages
- Expose zfetch_max_idistance tunable
- Make dbufstat work on FreeBSD
- Fix EIO after resuming receive of new dataset over an existing one
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge OpenZFS support in to HEAD.</title>
<updated>2020-08-25T02:21:27+00:00</updated>
<author>
<name>Matt Macy</name>
<email>mmacy@FreeBSD.org</email>
</author>
<published>2020-08-25T02:21:27+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=9e5787d2284e187abb5b654d924394a65772e004'/>
<id>9e5787d2284e187abb5b654d924394a65772e004</id>
<content type='text'>
The primary benefit is maintaining a completely shared
code base with the community allowing FreeBSD to receive
new features sooner and with less effort.

I would advise against doing 'zpool upgrade'
or creating indispensable pools using new
features until this change has had a month+
to soak.

Work on merging FreeBSD support in to what was
at the time "ZFS on Linux" began in August 2018.
I first publicly proposed transitioning FreeBSD
to (new) OpenZFS on December 18th, 2018. FreeBSD
support in OpenZFS was finally completed in December
2019. A CFT for downstreaming OpenZFS support in
to FreeBSD was first issued on July 8th. All issues
that were reported have been addressed or, for
a couple of less critical matters there are
pull requests in progress with OpenZFS. iXsystems
has tested and dogfooded extensively internally.
The TrueNAS 12 release is based on OpenZFS with
some additional features that have not yet made
it upstream.

Improvements include:
  project quotas, encrypted datasets,
  allocation classes, vectorized raidz,
  vectorized checksums, various command line
  improvements, zstd compression.

Thanks to those who have helped along the way:
Ryan Moeller, Allan Jude, Zack Welch, and many
others.

Sponsored by:	iXsystems, Inc.
Differential Revision:	https://reviews.freebsd.org/D25872
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The primary benefit is maintaining a completely shared
code base with the community allowing FreeBSD to receive
new features sooner and with less effort.

I would advise against doing 'zpool upgrade'
or creating indispensable pools using new
features until this change has had a month+
to soak.

Work on merging FreeBSD support in to what was
at the time "ZFS on Linux" began in August 2018.
I first publicly proposed transitioning FreeBSD
to (new) OpenZFS on December 18th, 2018. FreeBSD
support in OpenZFS was finally completed in December
2019. A CFT for downstreaming OpenZFS support in
to FreeBSD was first issued on July 8th. All issues
that were reported have been addressed or, for
a couple of less critical matters there are
pull requests in progress with OpenZFS. iXsystems
has tested and dogfooded extensively internally.
The TrueNAS 12 release is based on OpenZFS with
some additional features that have not yet made
it upstream.

Improvements include:
  project quotas, encrypted datasets,
  allocation classes, vectorized raidz,
  vectorized checksums, various command line
  improvements, zstd compression.

Thanks to those who have helped along the way:
Ryan Moeller, Allan Jude, Zack Welch, and many
others.

Sponsored by:	iXsystems, Inc.
Differential Revision:	https://reviews.freebsd.org/D25872
</pre>
</div>
</content>
</entry>
<entry>
<title>Stop compiling dtrace modules with -DSMP.</title>
<updated>2020-02-05T19:08:45+00:00</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2020-02-05T19:08:45+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=858e8e41ddb35687dfffc8067472dda9a4d3a46a'/>
<id>858e8e41ddb35687dfffc8067472dda9a4d3a46a</id>
<content type='text'>
I believe this is left over from when dtrace was being ported and
developed out-of-tree.  Now it just ensures that dtrace.ko and a non-SMP
kernel have incompatible KBIs.

PR:		243711
Sponsored by:	The FreeBSD Foundation
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
I believe this is left over from when dtrace was being ported and
developed out-of-tree.  Now it just ensures that dtrace.ko and a non-SMP
kernel have incompatible KBIs.

PR:		243711
Sponsored by:	The FreeBSD Foundation
</pre>
</div>
</content>
</entry>
<entry>
<title>Disconnect fasttrap from the 32-bit powerpc build.</title>
<updated>2019-02-21T22:49:21+00:00</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2019-02-21T22:49:21+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=efe88d92da775d8f13287251b0cc9993b1410be0'/>
<id>efe88d92da775d8f13287251b0cc9993b1410be0</id>
<content type='text'>
An upcoming bug fix requires 64-bit atomics, which aren't implemented on
powerpc.  The powerpc port of fasttrap is incomplete anyway and doesn't
get loaded by dtraceall.ko on powerpc because of a missing dependency;
it's presumed that it's effectively unused.

Discussed with:	jhibbits
MFC after:	2 weeks
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
An upcoming bug fix requires 64-bit atomics, which aren't implemented on
powerpc.  The powerpc port of fasttrap is incomplete anyway and doesn't
get loaded by dtraceall.ko on powerpc because of a missing dependency;
it's presumed that it's effectively unused.

Discussed with:	jhibbits
MFC after:	2 weeks
</pre>
</div>
</content>
</entry>
<entry>
<title>Move most of the contents of opt_compat.h to opt_global.h.</title>
<updated>2018-04-06T17:35:35+00:00</updated>
<author>
<name>Brooks Davis</name>
<email>brooks@FreeBSD.org</email>
</author>
<published>2018-04-06T17:35:35+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=6469bdcdb6a5968dc7edfcfb495d427b4bfdb3dd'/>
<id>6469bdcdb6a5968dc7edfcfb495d427b4bfdb3dd</id>
<content type='text'>
opt_compat.h is mentioned in nearly 180 files. In-progress network
driver compabibility improvements may add over 100 more so this is
closer to "just about everywhere" than "only some files" per the
guidance in sys/conf/options.

Keep COMPAT_LINUX32 in opt_compat.h as it is confined to a subset of
sys/compat/linux/*.c.  A fake _COMPAT_LINUX option ensure opt_compat.h
is created on all architectures.

Move COMPAT_LINUXKPI to opt_dontuse.h as it is only used to control the
set of compiled files.

Reviewed by:	kib, cem, jhb, jtl
Sponsored by:	DARPA, AFRL
Differential Revision:	https://reviews.freebsd.org/D14941
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
opt_compat.h is mentioned in nearly 180 files. In-progress network
driver compabibility improvements may add over 100 more so this is
closer to "just about everywhere" than "only some files" per the
guidance in sys/conf/options.

Keep COMPAT_LINUX32 in opt_compat.h as it is confined to a subset of
sys/compat/linux/*.c.  A fake _COMPAT_LINUX option ensure opt_compat.h
is created on all architectures.

Move COMPAT_LINUXKPI to opt_dontuse.h as it is only used to control the
set of compiled files.

Reviewed by:	kib, cem, jhb, jtl
Sponsored by:	DARPA, AFRL
Differential Revision:	https://reviews.freebsd.org/D14941
</pre>
</div>
</content>
</entry>
<entry>
<title>Rename assym.s to assym.inc</title>
<updated>2018-03-20T17:58:51+00:00</updated>
<author>
<name>Ed Maste</name>
<email>emaste@FreeBSD.org</email>
</author>
<published>2018-03-20T17:58:51+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=fc2a8776a2f9945f22301cd92ec6d3ac1f817028'/>
<id>fc2a8776a2f9945f22301cd92ec6d3ac1f817028</id>
<content type='text'>
assym is only to be included by other .s files, and should never
actually be assembled by itself.

Reviewed by:	imp, bdrewery (earlier)
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D14180
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
assym is only to be included by other .s files, and should never
actually be assembled by itself.

Reviewed by:	imp, bdrewery (earlier)
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D14180
</pre>
</div>
</content>
</entry>
<entry>
<title>Build systrace_freebsd32 on arm64.</title>
<updated>2018-01-11T21:17:05+00:00</updated>
<author>
<name>Michael Tuexen</name>
<email>tuexen@FreeBSD.org</email>
</author>
<published>2018-01-11T21:17:05+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=05f08f29789c78b799cd363594eba841cd7d811f'/>
<id>05f08f29789c78b799cd363594eba841cd7d811f</id>
<content type='text'>
Since r326501 which added COMPAT_FREEBSD32 to the GENERIC config for arm64,
we need to build systrace_freebsd32, since dtraceall depends on it.

Reviewed by:		ed, gnn
Differential Revision:	https://reviews.freebsd.org/D13670
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Since r326501 which added COMPAT_FREEBSD32 to the GENERIC config for arm64,
we need to build systrace_freebsd32, since dtraceall depends on it.

Reviewed by:		ed, gnn
Differential Revision:	https://reviews.freebsd.org/D13670
</pre>
</div>
</content>
</entry>
</feed>
