Export symbols from opensolaris.ko and dtrace.koBoth modules provide many symbols used by various DTrace providermodules, so just export everything.Sponsored by: The FreeBSD Foundation(cherry
Export symbols from opensolaris.ko and dtrace.koBoth modules provide many symbols used by various DTrace providermodules, so just export everything.Sponsored by: The FreeBSD Foundation(cherry picked from commit 8a693ccf86f90469910c5b2425ddb8a75e298487)
show more ...
dtrace: Fix /"string" == NULL/ comparisons using an uninitialized value.A test of this is funcs/tst.strtok.d which has this filter: BEGIN /(this->field = strtok(this->str, ",")) == NULL/
dtrace: Fix /"string" == NULL/ comparisons using an uninitialized value.A test of this is funcs/tst.strtok.d which has this filter: BEGIN /(this->field = strtok(this->str, ",")) == NULL/ { exit(1); }The test will randomly fail with exit status of 1 indicating that this->fieldwas 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->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, %r2In this case only %r1 is loaded with a string limit set to lim1. %r2 beingNULL 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 whilebeing lucky with what lim2 was [un]initialized as.Reviewed by: markj, Don Morris <dgmorris AT earthlink.net>Sponsored by: Dell EMCDifferential Revision: https://reviews.freebsd.org/D27671
openzfs: fix gcc kernel module builds - 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 declar
openzfs: fix gcc kernel module builds - 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 lineafter 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: markjSponsored by: Dell EMC IsilonDifferential Revision: https://reviews.freebsd.org/D27685
Update OpenZFS to 2.0.0-rc3-gfc5966- fix panic due to tqid overflow- Improve libzfs_error_init messages- Expose zfetch_max_idistance tunable- Make dbufstat work on FreeBSD- Fix EIO after resumi
Update OpenZFS to 2.0.0-rc3-gfc5966- 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
Merge OpenZFS support in to HEAD.The primary benefit is maintaining a completely sharedcode base with the community allowing FreeBSD to receivenew features sooner and with less effort.I would a
Merge OpenZFS support in to HEAD.The primary benefit is maintaining a completely sharedcode base with the community allowing FreeBSD to receivenew features sooner and with less effort.I would advise against doing 'zpool upgrade'or creating indispensable pools using newfeatures until this change has had a month+to soak.Work on merging FreeBSD support in to what wasat the time "ZFS on Linux" began in August 2018.I first publicly proposed transitioning FreeBSDto (new) OpenZFS on December 18th, 2018. FreeBSDsupport in OpenZFS was finally completed in December2019. A CFT for downstreaming OpenZFS support into FreeBSD was first issued on July 8th. All issuesthat were reported have been addressed or, fora couple of less critical matters there arepull requests in progress with OpenZFS. iXsystemshas tested and dogfooded extensively internally.The TrueNAS 12 release is based on OpenZFS withsome additional features that have not yet madeit 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 manyothers.Sponsored by: iXsystems, Inc.Differential Revision: https://reviews.freebsd.org/D25872
Stop compiling dtrace modules with -DSMP.I believe this is left over from when dtrace was being ported anddeveloped out-of-tree. Now it just ensures that dtrace.ko and a non-SMPkernel have incom
Stop compiling dtrace modules with -DSMP.I believe this is left over from when dtrace was being ported anddeveloped out-of-tree. Now it just ensures that dtrace.ko and a non-SMPkernel have incompatible KBIs.PR: 243711Sponsored by: The FreeBSD Foundation
Disconnect fasttrap from the 32-bit powerpc build.An upcoming bug fix requires 64-bit atomics, which aren't implemented onpowerpc. The powerpc port of fasttrap is incomplete anyway and doesn'tge
Disconnect fasttrap from the 32-bit powerpc build.An upcoming bug fix requires 64-bit atomics, which aren't implemented onpowerpc. The powerpc port of fasttrap is incomplete anyway and doesn'tget loaded by dtraceall.ko on powerpc because of a missing dependency;it's presumed that it's effectively unused.Discussed with: jhibbitsMFC after: 2 weeks
Move most of the contents of opt_compat.h to opt_global.h.opt_compat.h is mentioned in nearly 180 files. In-progress networkdriver compabibility improvements may add over 100 more so this isclose
Move most of the contents of opt_compat.h to opt_global.h.opt_compat.h is mentioned in nearly 180 files. In-progress networkdriver compabibility improvements may add over 100 more so this iscloser to "just about everywhere" than "only some files" per theguidance in sys/conf/options.Keep COMPAT_LINUX32 in opt_compat.h as it is confined to a subset ofsys/compat/linux/*.c. A fake _COMPAT_LINUX option ensure opt_compat.his created on all architectures.Move COMPAT_LINUXKPI to opt_dontuse.h as it is only used to control theset of compiled files.Reviewed by: kib, cem, jhb, jtlSponsored by: DARPA, AFRLDifferential Revision: https://reviews.freebsd.org/D14941
Rename assym.s to assym.incassym is only to be included by other .s files, and should neveractually be assembled by itself.Reviewed by: imp, bdrewery (earlier)Sponsored by: The FreeBSD Foundati
Rename assym.s to assym.incassym is only to be included by other .s files, and should neveractually be assembled by itself.Reviewed by: imp, bdrewery (earlier)Sponsored by: The FreeBSD FoundationDifferential Revision: https://reviews.freebsd.org/D14180
Build systrace_freebsd32 on arm64.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,
Build systrace_freebsd32 on arm64.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, gnnDifferential Revision: https://reviews.freebsd.org/D13670
sys: general adoption of SPDX licensing ID tags.Mainly focus on files that use BSD 2-Clause license, however the tool Iwas using misidentified many licenses so this was mostly a manual - errorpro
sys: general adoption of SPDX licensing ID tags.Mainly focus on files that use BSD 2-Clause license, however the tool Iwas using misidentified many licenses so this was mostly a manual - errorprone - task.The Software Package Data Exchange (SPDX) group provides a specificationto make it easier for automated tools to detect and summarize well knownopensource licenses. We are gradually adopting the specification, notingthat the tags are considered only advisory and do not, in any way,superceed or replace the license texts.No functional change intended.
Don't redefine _KERNEL.MFC after: 1 week
Enable dtrace support for mips64 and the ERL kernel configTurn on the required options in the ERL config file, and ensurethat the fbt module is listed as a dependency for mips inthe modules/dtrac
Enable dtrace support for mips64 and the ERL kernel configTurn on the required options in the ERL config file, and ensurethat the fbt module is listed as a dependency for mips inthe modules/dtrace/dtraceall/dtraceall.c file.PR: 220346Reviewed by: gnn, markjMFC after: 2 weeksDifferential Revision: https://reviews.freebsd.org/D12227
o Replace __riscv__ with __riscvo Replace __riscv64 with (__riscv && __riscv_xlen == 64)This is required to support new GCC 7.1 compiler.This is compatible with current GCC 6.1 compiler.RISC-V
o Replace __riscv__ with __riscvo Replace __riscv64 with (__riscv && __riscv_xlen == 64)This is required to support new GCC 7.1 compiler.This is compatible with current GCC 6.1 compiler.RISC-V is extensible ISA and the idea here is to have built-in defineper each extension, so together with __riscv we will have some subsetof these as well (depending on -march string passed to compiler):__riscv_compressed__riscv_atomic__riscv_mul__riscv_div__riscv_muldiv__riscv_fdiv__riscv_fsqrt__riscv_float_abi_soft__riscv_float_abi_single__riscv_float_abi_double__riscv_cmodel_medlow__riscv_cmodel_medany__riscv_cmodel_pic__riscv_xlenReviewed by: ngieSponsored by: DARPA, AFRLDifferential Revision: https://reviews.freebsd.org/D11901
Normalize SYSDIR on SRCTOP instead of .CURDIRThis is being done to simplify pathing for CFLAGS and source files.MFC after: 2 weeksSponsored by: Dell EMC Isilon
Stop building assym.o into the module.DTrace includes assym.s, to build this we build assym.o, howeverthis is unneeded as assym.s only contains macros.Remove the need to build this by removing i
Stop building assym.o into the module.DTrace includes assym.s, to build this we build assym.o, howeverthis is unneeded as assym.s only contains macros.Remove the need to build this by removing it from OBJS, but keep assym.sin the module dependencies via DPSRCS.This fixes the build when there is no assembler, e.g. on arm64 withoutthe external binutils.Submitted by: andrewMFC after: 2 weeksDifferential Revision: https://reviews.freebsd.org/D10041
Add an experimental DTrace audit provider, which allows users of DTrace toinstrument security event auditing rather than relying on conventional BSMtrail files or audit pipes:- Add a set of per-e
Add an experimental DTrace audit provider, which allows users of DTrace toinstrument security event auditing rather than relying on conventional BSMtrail files or audit pipes:- Add a set of per-event 'commit' probes, which provide access to particular auditable events at the time of commit in system-call return. These probes gain access to audit data via the in-kernel audit_record data structure, providing convenient access to system-call arguments and return values in a single probe.- Add a set of per-event 'bsm' probes, which provide access to particular auditable events at the time of BSM record generation in the audit worker thread. These probes have access to the in-kernel audit_record data structure and BSM representation as would be written to a trail file or audit pipe -- i.e., asynchronously in the audit worker thread.DTrace probe arguments consist of the name of the audit event (to supportfuture mechanisms of instrumenting multiple events via a single probe --e.g., using classes), a pointer to the in-kernel audit record, and anoptional pointer to the BSM data and its length. For human convenience,upper-case audit event names (AUE_...) are converted to lower case inDTrace.DTrace scripts can now cause additional audit-based data to be collectedon system calls, and inspect internal and BSM representations of the data.They do not affect data captured in the audit trail or audit pipesconfigured in the system. auditd(8) must be configured and running inorder to provide a database of event information, as well as other auditconfiguration parameters (e.g., to capture command-line arguments orenvironmental variables) for the provider to operate.Reviewed by: gnn, jonathan, markjSponsored by: DARPA, AFRLMFC after: 3 weeksDifferential Revision: https://reviews.freebsd.org/D10149
sys/modules: normalize .CURDIR-relative paths to SRCTOPThis simplifies make output/logicTested with: `cd sys/modules; make ALL_MODULES=` on amd64MFC after: 1 monthSponsored by: Dell EMC Isilon
Replace the implementation of DTrace's RAND subroutine for generatinglow-quality random numbers with a modern implementation (xoroshiro128+)that is capable of generating better quality randomness w
Replace the implementation of DTrace's RAND subroutine for generatinglow-quality random numbers with a modern implementation (xoroshiro128+)that is capable of generating better quality randomness without compromising performance.Submitted by: Graeme JenkinsonReviewed by: markjMFC after: 2 weeksSponsored by: DARPA, AFRLDifferential Revision: https://reviews.freebsd.org/D9051
Add full softfloat and hardfloat support for RISC-V.Hardfloat is now default (use riscv64sf as TARGET_ARCHfor softfloat).Sponsored by: DARPA, AFRLDifferential Revision: https://reviews.freebsd.
Add full softfloat and hardfloat support for RISC-V.Hardfloat is now default (use riscv64sf as TARGET_ARCHfor softfloat).Sponsored by: DARPA, AFRLDifferential Revision: https://reviews.freebsd.org/D8529
o Add support for long double.o Add support for latest RISC-V GNU toolchain.Sponsored by: DARPA, AFRLSponsored by: HEIF5
Revert r303911 "Remove extra -msoft-float flags settings."This was not properly tested.
Remove extra -msoft-float flags settings.This helps to build firmware modules.Sponsored by: DARPA, AFRLSponsored by: HEIF5
Include FBT to modules build on RISC-V.
Build DTrace assym.o with -msoft-float flag for RISC-V so we havecorrect flag in ELF file.Sponsored by: DARPA, AFRLSponsored by: HEIF5
1234