Commit Graph

18537 Commits

Author SHA1 Message Date
Fabien Thomas 39bbca6ffd crypto(9) is called from ipsec in CRYPTO_F_CBIFSYNC mode. This is working
fine when a lot of different flows to be ciphered/deciphered are involved.

However, when a software crypto driver is used, there are
situations where we could benefit from making crypto(9) multi threaded:
- a single flow is to be ciphered: only one thread is used to cipher it,
- a single ESP flow is to be deciphered: only one thread is used to
decipher it.

The idea here is to call crypto(9) using a new mode (CRYPTO_F_ASYNC) to
dispatch the crypto jobs on multiple threads, if the underlying crypto
driver is working in synchronous mode.

Another flag is added (CRYPTO_F_ASYNC_KEEPORDER) to make crypto(9)
dispatch the crypto jobs in the order they are received (an additional
queue/thread is used), so that the packets are reinjected in the network
using the same order they were posted.

A new sysctl net.inet.ipsec.async_crypto can be used to activate
this new behavior (disabled by default).

Submitted by:	Emeric Poupon <emeric.poupon@stormshield.eu>
Reviewed by:	ae, jmg, jhb
Differential Revision:    https://reviews.freebsd.org/D10680
Sponsored by:	Stormshield
2017-11-03 10:27:22 +00:00
Bryan Drewery 40a54c51c9 AUTO_OBJ: If the wanted .OBJDIR was not used then disable the feature.
This is to prevent downstream checks from assuming they can trust .OBJDIR when
MK_AUTO_OBJ is yes, such as the bsd.obj.mk checks.

Pointyhat to:	bdrewery
Sponsored by:	Dell EMC Isilon
2017-11-03 01:09:35 +00:00
Bryan Drewery 5fecb1f1d6 AUTO_OBJ is unsafe at the moment as it is for some reason removing /etc with _cleanobj. 2017-11-02 23:00:04 +00:00
Bryan Drewery 89bd07e927 DIRDEPS_BUILD: Cleanup leftover WORLDTMP files.
This will force any existing objects to rebuild if their .meta
files reference files from WORLDTMP.  This is a problem after
the UNIFIED_OBJDIR effort caused buildworld and DIRDEPS_BUILD
to share an OBJDIR.  Without cleaning these files the
Makefile.depend files end up with odd tmp/legacy/... entries
since some bootstrap-tools linger from there and otherwise
don't rebuild.  Removing the files causes anything having
used WORLDTMP to rebuild.

Sponsored by:	Dell EMC Isilon
2017-11-02 20:45:04 +00:00
Bryan Drewery 906a1c6c40 Regenerate for AUTO_OBJ.
Sponsored by:	Dell EMC Isilon
2017-11-02 18:09:10 +00:00
Bryan Drewery 615a1e70b0 Enable AUTO_OBJ by default if the OBJDIR is writable, only for in-tree builds.
This can be disabled by putting WITHOUT_AUTO_OBJ=yes in /etc/src-env.conf, not
/etc/src.conf, or passing it in the environment.

The purpose of this rather than simply flipping the default of AUTO_OBJ to yes
is to avoid hassling users with auto.obj.mk failures if the wanted OBJDIR is
not writable. It will fallback to writing to the source directory like it does
today if MAKEOBJDIRPREFIX is not writable.

The act of enabling MK_AUTO_OBJ disables all 'make obj' treewalks since
previous work has made those not run if MK_AUTO_OBJ==yes in Makefile.inc1.

Relnotes:	yes
Reviewed by:	sjg
Discussed at:	https://lists.freebsd.org/pipermail/freebsd-arch/2016-May/017805.html
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D12841
2017-11-02 18:09:07 +00:00
Justin Hibbits 73e23ad462 Actually add the dtsec(4) man page to the build 2017-11-02 04:17:10 +00:00
Bryan Drewery fbb74b0ee7 Don't propagate MAKEOBJDIRPREFIX changes to environment.
A makefile may use this variable later for its own reasons,
don't infect sub-makes with that value.

Sponsored by:	Dell EMC Isilon
2017-11-02 04:05:03 +00:00
Bryan Drewery efb949a699 Regenerate for UNIFIED_OBJDIR.
Sponsored by:	Dell EMC Isilon
2017-11-01 21:22:23 +00:00
Bryan Drewery 718edb1577 META_MODE: Respect make -s.
MFC after:	2 weeks
Sponsored by:	Dell EMC Isilon
2017-11-01 21:22:19 +00:00
Bryan Drewery f8b15066f2 make obj: Skip treewalk if AUTO_OBJ is enabled.
Sponsored by:	Dell EMC Isilon
2017-11-01 21:22:16 +00:00
Bryan Drewery c10062b9bf Add a 'make cleanuniverse'.
This will remove all build files for the source directory
when MK_UNIFIED_OBJDIR is enabled.

Sponsored by:	Dell EMC Isilon
2017-11-01 21:22:10 +00:00
Bryan Drewery dfa099890c Add option UNIFIED_OBJDIR, on by default, which moves the default build OBJDIR.
This changes the build OBJDIR from the older style of /usr/obj/<srcdir> for
native builds, and /usr/obj/<target>.<target_arch>/<srcdir> for cross builds to
a new simpler format of /usr/obj/<srcdir>/<target>.<target_arch>.  This
new format is used regardless of cross or native build.  It allows
easier management of multiple source tree object directories.

The UNIFIED_OBJDIR option will be removed and its feature made permanent
for the 12.0 release.

Relnotes:	yes (don't note UNIFIED_OBJDIR option since it will be removed)
Prior work:	D3711 D874
Reviewed by:	gjb, sjg
Discussed at:	https://lists.freebsd.org/pipermail/freebsd-arch/2016-May/017805.html
Discussed with:	emaste
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D12840
2017-11-01 21:22:05 +00:00
Eitan Adler 1888bce26a Remove 'adding_user.7'
Not to be confused with adduser.
Not to be confused with useful information.

Differential Revision: https://reviews.freebsd.org/D12848
2017-11-01 01:22:33 +00:00
Justin Hibbits 1c41f28f7c Remove a singleton in the DPAA driver, to allow multiple fman instances
Some devices (P5040, P4080) have multiple frame managers in their DPAA
subsystems.  This was prevented by use of a softc singleton in the DPAA
driver.  Since if_dtsec(4) has moved to be a child of fman, it can access
the fman device data via the parent object.
2017-11-01 00:46:48 +00:00
Yuri Victorovich 896b68b936 Add myself as a new committer
Reviewed by:	tcberner
Approved by:	tcberner (mentor)
Differential Revision:	https://reviews.freebsd.org/D12845
2017-10-31 07:47:57 +00:00
Eitan Adler 424b4e738a Fix '\' in binary ascii table 2017-10-31 06:43:37 +00:00
Eitan Adler fc82a9aa1c Also bump Dd 2017-10-31 06:36:33 +00:00
Eitan Adler c580de1476 Update tuning(7) some more
At this point its unclear how much help tuning(7) is whatsoever
but leave it around in case someone decides to spend some time on
it.
2017-10-31 06:35:17 +00:00
Bryan Drewery 89dd2beb7e Regenerate after r325180 2017-10-31 02:29:30 +00:00
Bryan Drewery bec340c8f8 This check is not ready here yet.
Keeping for blame purposes, it will be enabled soon.
2017-10-31 02:25:47 +00:00
Bryan Drewery 32e7d9d0d9 AUTO_OBJ can work for crunchgen build-tools.
Sponsored by:	Dell EMC Isilon
2017-10-31 02:12:13 +00:00
Bryan Drewery 579deb45c1 Disable MK_AUTO_OBJ as a make argument like r325078.
This avoids needlessly trying to enable it opportunistically.

Sponsored by:	Dell EMC Isilon
2017-10-31 02:12:09 +00:00
Bryan Drewery 0dd60f15a5 Move some objdir handling (OBJROOT/OBJTOP) out of DIRDEPS_BUILD-only files.
Sponsored by:	Dell EMC Isilon
2017-10-31 00:26:42 +00:00
Bryan Drewery 95137b228e Add RELOBJTOP and RELSRCTOP for relative paths.
RELSRCTOP is likely not as useful since make will always be running from
inside of .OBJDIR and using something like ${.CURDIR}/${RELSRCTOP} is
not redundant for ${SRCTOP}.

Sponsored by:	Dell EMC Isilon
2017-10-31 00:07:41 +00:00
Bryan Drewery ea825d0274 DIRDEPS_BUILD: Update dependencies.
Sponsored by:	Dell EMC Isilon
2017-10-31 00:07:04 +00:00
Bryan Drewery 3806950135 DIRDEPS_BUILD: Connect new directories.
Sponsored by:	Dell EMC Isilon
2017-10-31 00:04:07 +00:00
Bryan Drewery a160cbfa07 DIRDEPS_BUILD: libgcc now depends on MK_LLVM_LIBUNWIND
The dependency on gnu/lib/libgcc or lib/libgcc* is determined
at 'make dirdeps' time.

Sponsored by:	Dell EMC Isilon
2017-10-31 00:03:36 +00:00
Bryan Drewery 83f4f35130 Follow-up r320149: Enable GPL_DTC if we're using GCC as the cross-compiler.
This fixes object files landing in the source tree in gnu/usr.bin/dtc
for GCC platforms.

We cannot reliably detect if an external compiler is used here, and the
default YES option does include GCC_BOOTSTRAP which implies that GCC may
be used for the build.

The problem manifests when not using an external compiler, and the host
compiler is clang.  When a fresh build is done (no OBJDIR yet) the
'make obj' treewalk is done before 'make cross-tools', so
COMPILER_FEATURES at this point contains 'c++11' since the host compiler
was used for COMPILER_FEATURES.  Once cross-tools builds the GCC
bootstrap compiler and then descends into 'make everything',
COMPILER_FEATURES no longer contains 'c++11' and MK_GPL_DTC defaults to
enabled.  Now it builds in gnu/usr.bin/dtc without an OBJDIR preset and
drops files into the source tree.

The COMPILER_FEATURES check here is useful for knowing if we can *bootstrap*
C++11 things.  Indeed we do bootstrap dtc as a build tool so it is
useful for enabling the BSD dtc for the build, but we end up needing the
GPL dtc for installation anyway.

Reviewed by:	manu, emaste
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D12817
2017-10-31 00:03:32 +00:00
Alex Richardson f3ae9b5cee Add myself to committers-src.dot
Reviewed by:	jhb (mentor)
Approved by:	jhb (mentor)
2017-10-30 18:17:02 +00:00
Enji Cooper d406452673 Reference iwm8265fw support in iwm(4) as well
This documentation update is similar to what was done in iwmfw(4) in r325121.

MFC after:	1 month
MFC with:	r325121
2017-10-30 06:43:40 +00:00
Enji Cooper 555695a545 iwmfw(4): update support info
- Document iwm8265fw firmware knobs.
- Note that 8000 series cards are also covered by the iwmfw(4) firmware module
  set.
2017-10-30 06:06:37 +00:00
Eitan Adler 8fb93a0c95 Unbreak install
Reported by:	cy
2017-10-30 04:30:34 +00:00
Eitan Adler af28292c02 Remove now bogus README
The SGML referenced was removed in r4719 of the doc repo.
2017-10-30 00:36:08 +00:00
Eitan Adler a2aef24aa3 Update several more URLs
- Primarily http -> https
- Primarily FreeBSD project URLs
2017-10-29 08:17:03 +00:00
Bryan Drewery 49c9ea8fe5 AUTO_OBJ: auto.obj.mk mkdir -p simplification
Sponsored by:	Dell EMC Isilon
2017-10-29 01:21:36 +00:00
Bryan Drewery 5bd47cc56f Change native-xtools to not install by default; add a native-xtools-install.
Without this the user has to mess with 'make -f Makefile.inc1 ...' to figure
out where the files are installed in the OBJDIR and then they need to copy them
to where they really wanted them. Using DESTDIR may be problematic after
r325001 as well.

The files will be installed to DESTDIR/NXTP where NXTP defaults to /nxb-bin.

MFC after:	2 weeks
Sponsored by:	Dell EMC Isilon
2017-10-29 01:21:29 +00:00
Bryan Drewery b135fb6ef4 build(7): Document xdev targets.
MFC after:	2 weeks
Sponsored by:	Dell EMC Isilon
2017-10-29 01:21:26 +00:00
Bryan Drewery 7441e255ed build(7): Document native-xtools.
MFC after:	2 weeks
Sponsored by:	Dell EMC Isilon
2017-10-29 01:21:22 +00:00
Bryan Drewery d3e478c4c3 MAKEOBJDIR should be an absolute path, not any path with a slash.
Using MAKEOBJDIR=foo did not work but MAKEOBJDIR=foo/ did, but
really it needs to be absolute.

Sponsored by:	Dell EMC Isilon
2017-10-29 01:21:12 +00:00
Mariusz Zaborski 23c5a51e92 Introduce cnvlist_name() and cnvlist_type() functions.
Those function can be used when we are iterating over nvlist to reduce
amount of extra variables we need to declare.

MFC after:	1 month
2017-10-26 20:44:42 +00:00
Warner Losh 2703928ae4 Fix typo and bump .Dd date.
Noticed by: Richard Tector
Sponsored by: Netflix
2017-10-25 23:24:30 +00:00
Warner Losh 1170c2fecc Implement IPMI support for RB_POWRECYCLE
Some BMCs support power cycling the chassis via the chassis control
command 2 subcommand 2 (ipmitool called it 'chassis power cycle').  If
the BMC supports the chassis device, register a shutdown_final handler
that sends the power cycle command if request and waits up to 10s for
it to take effect. To minimize stack strain, we preallocate a ipmi
request in the softc. At the moment, we're verbose about what we're
doing.

Sponsored by: Netflix
2017-10-25 15:30:53 +00:00
Mark Johnston 64a16434d8 Add support for compressed kernel dumps.
When using a kernel built with the GZIO config option, dumpon -z can be
used to configure gzip compression using the in-kernel copy of zlib.
This is useful on systems with large amounts of RAM, which require a
correspondingly large dump device. Recovery of compressed dumps is also
faster since fewer bytes need to be copied from the dump device.

Because we have no way of knowing the final size of a compressed dump
until it is written, the kernel will always attempt to dump when
compression is configured, regardless of the dump device size. If the
dump is aborted because we run out of space, an error is reported on
the console.

savecore(8) is modified to handle compressed dumps and save them to
vmcore.<index>.gz, as it does when given the -z option.

A new rc.conf variable, dumpon_flags, is added. Its value is added to
the boot-time dumpon(8) invocation that occurs when a dump device is
configured in rc.conf.

Reviewed by:	cem (earlier version)
Discussed with:	def, rgrimes
Relnotes:	yes
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D11723
2017-10-25 00:51:00 +00:00
Ruslan Bukin d27927f731 Extract a set of pmcstat functions and interfaces to the new internal
library -- libpmcstat.

This includes PMC logging module, symbols lookup functions,
ELF parsing, process management, PMC attachment, etc.

This allows to reuse code while building new hwpmc(4)-based applications.

Also add pmcstat_symbol_search_by_name() function that allows to find
mapped IP range for a given function name.

Reviewed by:	kib
Sponsored by:	DARPA, AFRL
Differential Revision:	https://reviews.freebsd.org/D12718
2017-10-24 16:28:00 +00:00
Ed Maste aa86fca1d1 uefi.8: mention use on (32-bit) arm
Sponsored by:	The FreeBSD Foundation
2017-10-23 20:32:18 +00:00
Konstantin Belousov c9b6b5826c Expand explanation of atomicity.
Mention per-location total order, out of thin air, and torn writes
guarantees.  Mention C11 standard' memory model and one most important
FreeBSD additional requirement, that is aligned ordinary loads and
stores are atomic on processors.

The text is introductional and informal.  Reference the C11 and
C++1{1,4,7} standards for authorative description.

In collaboration with:	alc
Sponsored by:	The FreeBSD Foundation (kib)
MFC after:	1 week
2017-10-23 16:14:55 +00:00
Enji Cooper 0c095a65a1 Fix an omission in a comment
Soft float API support applies to armv7 too after r324340
2017-10-23 07:56:56 +00:00
Bruce M Simpson ab28146b6c Modernise this man page somewhat.
1. Add a reference to a good 3rd party list of compatible cables, but
provide suggestions for 'known good' vendors.

2. Change IP-based USB host-host example to a modern Ethernet one which
works 'out of box' with current Linux systems.

3. Explain that USB 3.0 is host-host, even though point-to-point soft
Ethernet can be achieved.

MFC after:	3 weeks
2017-10-22 11:40:55 +00:00
Enji Cooper 7c6052349c Regenerate src.conf(5) after r324340 (armv7 addition) 2017-10-22 07:36:28 +00:00