Commit Graph

249169 Commits

Author SHA1 Message Date
Ed Maste
15f16425e4 if_muge: use C99 bool for boolean vars 2020-03-18 14:16:14 +00:00
Leandro Lupori
e9f87d29a8 Add fsck_flags config option
On UFS with SU+J, sometimes fsck's default recovery from journal marks the
filesystem as clean but some errors remain.

With SU only, default fsck in preen mode sometimes thinks all errors have
been fixed but some still remain.

To address the issues above, this change adds a new config option:
fsck_flags.  By default it's set to -p, but the user may change it to -y
or -f -y, for instance, to force a full fsck after a system crash.

Submitted by:	jhibbits@ (original version)
Reviewed by:	mckusick
Differential Revision:	https://reviews.freebsd.org/D24087
2020-03-18 13:09:47 +00:00
Hiroki Sato
d80eccfc98 Remove /etc/host.conf, which was automatically generated from
nsswitch.conf for backward compatibility.  This file was used
over 19 years ago, before introducing nsdispatch() in the
name-service lookup APIs.

MFC after:	3 days
2020-03-18 08:17:24 +00:00
Hiroki Sato
c165f4ab69 -F is GNU diff specific, not implemented in BSD diff.
Reported by:	kouya@ryuhoku.jp
MFC after:	3 days
2020-03-18 08:00:46 +00:00
Jung-uk Kim
f22e76dc20 Remove wrong entries added in the previous commit.
Pointyhat to:	jkim
2020-03-18 05:28:36 +00:00
Rebecca Cran
a717adb5a0 Bhyve: log message when rfb client connects
Reviewed by:	jhb
Differential Revision:	https://reviews.freebsd.org/D24098
2020-03-18 03:17:15 +00:00
Rebecca Cran
cbd7ddcf65 Bhyve: DPRINTF already includes newline, so don't add another
Reviewed by:	jhb, vmaffione, emaste
Differential Revision:	https://reviews.freebsd.org/D24099
2020-03-18 03:15:57 +00:00
Rebecca Cran
7e03a82b63 ath_hal: fix typo in ath_hal_printf 2020-03-18 03:14:17 +00:00
Brandon Bergren
3069380898 [PowerPC][Book-E] Fix missing load base in elf_cpu_parse_dynamic().
When I implemented MD DYNAMIC parsing, I was originally passing a
linker_file_t so that the MD code could relocate pointers.

However, it turns out this isn't even filled in until later, so it was
always 0.

Just pass the load base (ef->address) directly, as that's really the only
thing we were interested in in the first place.

This fixes a crash on RB800 where it was trying to write to an unmapped
address when updating the GOT.

Reviewed by:	jhibbits
Sponsored by:	Tag1 Consulting, Inc.
Differential Revision:	https://reviews.freebsd.org/D24105
2020-03-18 02:58:18 +00:00
Jung-uk Kim
0a70e97c94 Reduce diff with the vendor version. No functional change. 2020-03-18 02:20:03 +00:00
Jung-uk Kim
17f01e9963 Merge OpenSSL 1.1.1e. 2020-03-18 02:13:12 +00:00
Justin Hibbits
889d304bb4 powerpc: Axe PPC4xx support.
Summary:
The support was added almost a decade ago, and never completed.  Just axe
it.  It was also inadvertently broken 5 years ago, and nobody noticed.

Reviewed by:	bdragon
Differential Revision:	https://reviews.freebsd.org/D23753
2020-03-18 01:09:43 +00:00
Navdeep Parhar
a8f48cf82f Remove spurious warning about invalid VPD data.
The warning used to be displayed for valid VPDs about 512B or above in
size.  Fix the size check and add a break while here so that the routine
stops if if detects any problem.

Tested with "pciconf -lV"

Reviewed by:	kib@, jhb@
MFC after:	1 week
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D23679
2020-03-18 01:09:40 +00:00
John Baldwin
7a9cfa086a Fix the workaround to ignore the #warning for GCC.
clang and gcc use different warning flags for #warning preprocessor
directives.

Reported by:	Jenkins
MFC after:	1 week
2020-03-17 23:22:07 +00:00
Conrad Meyer
34086d5bda Implement sysctl kern.boot_id
Boot IDs are random, opaque 128-bit identifiers that distinguish distinct
system boots.  A new ID is generated each time the system boots.  Unlike
kern.boottime, the value is not modified by NTP adjustments.  It remains fixed
until the machine is restarted.

PR:		244867
Reported by:	Ricardo Fraile <rfraile AT rfraile.eu>
MFC after:	I do not intend to, but feel free
2020-03-17 22:27:16 +00:00
Jung-uk Kim
aa144ced5d Import OpenSSL 1.1.1e. 2020-03-17 21:27:57 +00:00
John Baldwin
725cc1de9a Add missing DTrace files for WITHOUT_CDDL=yes.
Reviewed by:	dteske
MFC after:	1 week
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D24037
2020-03-17 21:11:38 +00:00
Michael Tuexen
0554e01d8b Handle the timers in a consistent sequence according to the definition
of the timer type.
Just a cleanup, no functional change intended.

MFC after:		1 week
2020-03-17 19:20:12 +00:00
John Baldwin
8d8a74e69e Mark procfs-based process debugging as deprecated for FreeBSD 13.
Attempting to use ioctls on /proc/<pid>/mem to control a process will
trigger warnings on the console.  The <sys/pioctl.h> include file will
also now emit a compile-time warning when used from userland.

Reviewed by:	emaste
MFC after:	1 week
Relnotes:	yes
Differential Revision:	https://reviews.freebsd.org/D23822
2020-03-17 18:44:03 +00:00
Brooks Davis
2e1dfb346f Support SUBDIR.${MK_FOO}.${MK_BAR} expresssions.
This allows simplification of Makefiles where some SUBDIR entries depend
on two things (e.g. something that depends on C++ and some other knob).

Discussed with:	imp, jhb
Obtained from:	CheriBSD
MFC after:	3 days
Sponsored by:	DARPA
2020-03-17 18:17:32 +00:00
Brooks Davis
564b9ff2a7 Add an internal liblua and use it in flua.
The new liblua will be used in a forthcoming import of kyua.

Reviewed by:	kevans
Obtained from:	CheriBSD
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D24090
2020-03-17 17:28:12 +00:00
Brooks Davis
08334c51db Import the kyua testing framework for infrastructure software
Imported at 0.13 plus assumulated changes to git hash a685f91.

Obtained from:	https://github.com/jmmv/kyua
Sponsored by:	DARPA
2020-03-17 16:56:50 +00:00
Brooks Davis
4b2c3eb9d4 Import lutok, a Lightweight C++ API for Lua.
This a snapshot of the latest version with git hash: 8f8eaef.

Obtained from:	https://github.com/jmmv/lutok
Sponsored by:	DARPA
2020-03-17 16:48:52 +00:00
Ed Maste
5a2c0ab18b ldd: add aout deprecation notice
Reported by:	kib
2020-03-17 16:42:25 +00:00
Ed Maste
2ee11faacf ldconfig: add aout deprecation notice
aout support in ldconfig hasn't been required since FreeBSD 2.x.
Anyone still using FreeBSD 2 shared libraries can also use a FreeBSD 2
ldconfig to generate aout ldconfig hints.

Sponsored by:	The FreeBSD Foundation
2020-03-17 15:57:25 +00:00
Ed Maste
dfcef1de85 Makefile.inc1: add a note when deleting stale dependencies
We have ad-hoc stale dependency handling in Makefile.inc1 to handle the
cases where file extensions change, but it appears that some cases are
not functional.  Add a note when about to clean stale deps to help
when investigating failure reports.

Sponsored by:	The FreeBSD Foundation
2020-03-17 14:12:19 +00:00
Alex Richardson
02f4a9dd96 Fix misleading indentation warning in OCTEON1 kernel
This is required to switch MIPS to compile with LLVM by default (D23204).

Reviewed By:	brooks
Differential Revision: https://reviews.freebsd.org/D24091
2020-03-17 11:59:45 +00:00
Alex Richardson
e40375374c Fix build of XLP MIPS kernel with clang
Clang does not recognize some of the GCC optimization options that are
used to compile ucore_app.bin. This is required to switch MIPS to
compile with LLVM by default (D23204).

Reviewed By:	imp
Differential Revision: https://reviews.freebsd.org/D24092
2020-03-17 11:59:40 +00:00
Mateusz Piotrowski
3431172fa8 Tell the world how to convert gigabytes to bytes with units(1) easily
It turns out that units(1) is not as horrible to use in scripts
as I initially thought. When the --terse flag is combined
with an appropriate output format (set via --output-format),
units(1) is actually capable of producing very nice results.
For example:

    units -o %0.f -t '4 gigabytes' bytes

is is just going to print out the expected value of 4294967296.

There is no time to waste. People have to know about it.

I am adding an example for this at the top of the examples section
because this is what users are most likely looking for.

Approved by:	bcr (mentor)
Differential Revision:	https://reviews.freebsd.org/D24096
2020-03-17 10:02:59 +00:00
Hans Petter Selasky
b527d52357 Add new USB device ID to u3g driver.
Submitted by:	super_gromit@hotmail.com
PR:		244798
MFC after:	3 days
Sponsored by:	Mellanox Technologies
2020-03-17 09:12:47 +00:00
Kevin Lo
61e4c924a0 Convert to the standard section 4 SYNOPSIS layout. 2020-03-17 05:33:05 +00:00
Patrick Kelsey
5d1899eedb Restore power-of-2 queue count constraint from r290948
When vmx(4) was converted to an iflib driver in r343291, the
power-of-2 queue count constraint was removed as it appeared that
current implementations of the VMXNET3 virtual device no longer
required that constraint.  It turns out that some of the
implementations still do, and on such systems, the device will fail to
initialize when configured with a non-power-of-2 RX or TX queue count.

PR:		237321
Reported by:	ncrogers@gmail.com
MFC after:	1 week
2020-03-17 03:32:13 +00:00
Lorenzo Salvadore
1d7a2bbe37 Add tcberner as co-mentor for salvadore
Approved by:	gerald (mentor)
2020-03-16 23:37:57 +00:00
Conrad Meyer
a99c321802 Remove misleading / redundant bzero in callout_callwheel_init
The intent seems to be zeroing all of the cc_cpu array, or its singleton on
such platforms.  The assumption made is that the BSP is always zero.  The
code smell was introduced in r326218, which changed the prior explicit zero
to 'curcpu'.  The change is only valid if curcpu continues to be zero,
contrary to the aim expressed in that commit message.

So, more succinctly, the expression could be: memset(cc_cpu,0,sizeof(cc_cpu)).

However, there's no point.  cc_cpu lives in the data section and has a zero
initial value already.  So this revision just removes the problematic
statement.

No functional change.  Appeases a (false positive, ish) Coverity CID.

CID:		1383567
Reported by:	Puneeth Jothaiah <puneethkumar.jothaia AT dell.com>
Reviewed by:	kib
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D24089
2020-03-16 22:25:25 +00:00
Alexander Motin
cf2f2eb568 Fix infinite scan on a pool with only special allocations
Attempt to run scrub or resilver on a new pool containing only special
allocations (special vdev added on creation) caused infinite loop
because of dsl_scan_should_clear() limiting memory usage to 5% of pool
size, which it calculated accounting only normal allocation class.

Addition of special and just in case dedup classes fixes the issue.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Alexander Motin <mav@FreeBSD.org>
Sponsored-By: iXsystems, Inc.
Closes #10106
Closes #8694
openzfs/zfs@fa130e010c
2020-03-16 19:03:10 +00:00
Edward Tomasz Napierala
fb48a42f03 Make autofs(5) timeout messages include affected process name and PID.
MFC after:	2 weeks
Sponsored by:	DARPA, AFRL
2020-03-16 16:17:58 +00:00
Andrew Gallatin
ee7a9e506e Avoid a cache miss accessing an mbuf ext_pgs pointer when doing SW kTLS.
For a Netflix 90Gb/s 100% TLS software kTLS workload, this reduces
the CPI of tcp_m_copym() from ~3.5 to ~2.5 as reported by vtune.

Reviewed by:	jtl, rrs
Sponsored by:	Netflix
Differential Revision:	https://reviews.freebsd.org/D23998
2020-03-16 14:03:27 +00:00
Alfredo Dal'Ava Junior
5c6ad2e813 atp: fix mouse attachment on PowerBook5,6 (G4)
Skip device mode switch step on Fountain-based devices as they don't
support RAW_SENSOR_MODE command, so failing to attach.

This was reproduced on PowerBook G4 (model PowerBook5,6) equipped with
product ID 0x020e

Reviewed by:	hselasky
Approved by:	jhibbits (mentor)
Differential Revision:	https://reviews.freebsd.org/D24005
2020-03-16 13:53:29 +00:00
Hans Petter Selasky
1c6a456125 Fix for double unlock in ipoib.
The ipoib_unicast_send() function is not supposed to unlock the priv lock.

MFC after:	3 days
Sponsored by:	Mellanox Technologies
2020-03-16 12:33:57 +00:00
Kristof Provost
bb490fcf19 bridge tests: Basic span test
Reviewed by:	philip, emaste (previous version)
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D23961
2020-03-16 08:44:46 +00:00
Ed Maste
9f6954e505 if_muge: whitespace and style cleanup
Submitted by:	clang-format (in part)
Sponsored by:	The FreeBSD Foundation
2020-03-15 21:47:16 +00:00
Warner Losh
ddeb85e131 We don't need $M/$M in the path anymore.
Now that machdep files are gone, we don't need $S/$M/$M in the path to find
them.
2020-03-15 17:40:14 +00:00
Ed Maste
6c0331ea04 muge: drop CSUM from MUGE_DEFAULT_TSO_CSUM_ENABLE
TSO is independent of checksum offload
2020-03-15 03:32:39 +00:00
Ed Maste
0d5e6868c5 muge: enable RXCSUM as it now works
MFC after:	2 weeks
Sponsored by:	The FreeBSD Foundation
2020-03-15 03:03:01 +00:00
Pedro F. Giffuni
83735685d3 calendar(1): Updates and corrections for some calendar files.
These have an educational value and are, no doubt, an integral part of the fun
behind running the BSDs.

PR:		242909, 242918
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D23581
2020-03-15 00:49:06 +00:00
Patrick Kelsey
876996910a Remove extraneous code from iflib
ifsd_cidx is never used, and the line removed from rxd_frag_to_sd() is
just dead code.

Reviewed by:	erj, gallatin
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D23951
2020-03-14 20:13:42 +00:00
Patrick Kelsey
1342c8c622 Adjust if_vmx default receive parameters for better out-of-box performance
These adjustments improve performance with jumbo frames and/or LRO
enabled (i.e., when there may be multiple descriptors per packet) by
increasing the default size of the receive queues and by always using
page-sized buffers for the body type receive ring.

This patch also adjust the initialization of the max frame size to
remove cases where certain configuration sequences would result in 2K
receive buffers being used instead of 4K ones when jumbo frames were
enabled.

Reviewed by:	gallatin
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D23950
2020-03-14 20:11:46 +00:00
Patrick Kelsey
f50375eec6 Fix if_vmx receive checksum offload bug and harden against the device skipping receive descriptors
This fixes a bug where the checksum offload status of received packets
was being taken from the first descriptor instead of the last, which
affected LRO packets.

The driver has been hardened against the device skipping receive
descriptors, although it is not believed that this can occur given the
way this implementation configures the receive rings.

Additionally, for packets received with the error indicator set, the
driver now forces the length of all fragments in that packet to zero
prior to passing it to iflib.  Such packets should wind up being
discarded at some point in the stack anyway, but this removes any
questions by killing them in the driver.

Counters have been added (and exposed via sysctls) for skipped receive
descriptors, zero-length packets received, and packets received with
the error indicator set so that these conditions can be easily
observed in the field.

PR:		243126, 243392, 240628
Reported by:	avg, alexandr.oleynikov@gmail.com, Harald Schmalzbauer
Reviewed by:	gallatin
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D23949
2020-03-14 20:08:04 +00:00
Patrick Kelsey
3caff1885f Remove refill budget from iflib
Reviewed by:	gallatin
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D23948
2020-03-14 19:58:50 +00:00
Patrick Kelsey
b38136097a Allow iflib drivers to specify the buffer size used for each receive queue
Reviewed by:	erj, gallatin
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D23947
2020-03-14 19:56:46 +00:00