Commit Graph

284664 Commits

Author SHA1 Message Date
John Baldwin
f5e7330633 ipfw: Remove set but unused variables.
Reported by:	GCC
Differential Revision:	https://reviews.freebsd.org/D40654
2023-06-27 10:19:32 -07:00
John Baldwin
a7f25f141a libipf: Remove set but unused variable from printfraginfo().
Reported by:	GCC
Differential Revision:	https://reviews.freebsd.org/D40652
2023-06-27 10:19:31 -07:00
John Baldwin
ccfd87fe2a libefivar: Use a void cast in unimplemented stubs.
This "consumes" an otherwise unused argument.

Differential Revision:	https://reviews.freebsd.org/D40650
2023-06-27 10:19:31 -07:00
John Baldwin
36c2fec31d riscv: Remove MACHINE_ARCH-specific remnants of riscv64sf.
- Remove now unnecessary MACHINE_ARCHES definition.  The default logic
  in kern_mib.c works fine now for RISC-V.

- Remove custom sv_machine_arch hook from sysentvec.

Fixes:		1ca12bd927 Remove the riscv64sf architecture.
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D40648
2023-06-27 10:19:31 -07:00
Warner Losh
2d38d9839b openzfs: Remove broken symlinks
These symlinks are broken. They point to files that don't exist, and
rely on having them be built using a 'in-tree' build that FreeBSD
doesn't use. They also show up as errors on grep -r. Since they are
broken and can't possibly work, remove them for now since non-functional
symlinks matching an upstrem repo that can't work in our repo aren't
worth the error messages.

Though one could argue the whole debian directory should be removed, I
did the minimal change necessary. These can return when the fundamental
issue is fixed and the contrib/debian tree is useful on FreeBSD systems.
2023-06-27 11:15:20 -06:00
John Baldwin
5ae4463498 nvme: Fix typo in "Command Aborted by Host" constant name.
Reviewed by:	chuck, imp
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D40763
2023-06-27 10:06:22 -07:00
Dag-Erling Smørgrav
3ba4c8c81a Upgrade to OpenPAM Ximenia.
Merge commit '5894a4142a9d5ae5f7f6bee1f46237a3d20d0b5b'
2023-06-27 19:03:17 +02:00
Dag-Erling Smørgrav
5894a4142a Vendor import of OpenPAM Ximenia. 2023-06-27 19:01:49 +02:00
Doug Moore
9cfed089ac radix_trie: clean up overlong lines
This is purely a cosmetic change. vm_radix.c has lines that reach past
column 80 and this change cleans that up. The associated changes to
subr_pctrie.c are just to keep mirroring vm_radix.c.
Reviewed by:	markj
Differential Revision:	https://reviews.freebsd.org/D40764
2023-06-27 12:01:33 -05:00
Warner Losh
a1db51dbdb unzip(1): Comma after e.g.
Add comma after e.g. to make igor happy (oh, and I suppose to conform to
normal English grammar rules).

Sponsored by:		Netflix
2023-06-27 10:58:40 -06:00
Mingye Wang
a227908571 unzip: add -O/-I encoding support
These are for compatibility with the info-zip version of unzip.

PR: 271657
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/752
2023-06-27 10:55:26 -06:00
Mohamed Akram
8edb6fb572 man(1): Support custom sections
PR: 271830
Signed-off-by: Mohamed Akram <mohd.akram@outlook.com>
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/764
2023-06-27 07:51:27 -06:00
Greg Becker
a6c0d801ca libpthread: allocate rwlocks and spinlocks in dedicated cachelines
Reduces severe performance degradation due to false-sharing. Note that this
does not account for hardware which can perform adjacent cacheline prefetch.

[mjg: massaged the commit message and the patch to use aligned_alloc
instead of malloc]

PR:	272238
MFC after:	1 week
2023-06-27 11:56:44 +00:00
Konstantin Belousov
4a402dfe0b VFS: Remove VV_READLINK flag
since its only reason to exist is removed.

Reviewed by:	markj
Tested by:	pho
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
Differential revision:	https://reviews.freebsd.org/D40700
2023-06-27 13:43:25 +03:00
Konstantin Belousov
3bffa22623 fdescfs: improve linrdlnk mount option
Instead of using VV_READLINK vnode flag and checking it in one place,
just assign VLNK type to the Fdesc vnodes for linrdlnk mounts.  Then all
places where symlinks needs to be followed, e.g. lookup(), are handled.

PR:	272127
Reported by:	Peter Eriksson <pen@lysator.liu.se>
Reviewed by:	markj
Tested by:	pho
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
Differential revision:	https://reviews.freebsd.org/D40700
2023-06-27 13:43:17 +03:00
Li-Wen Hsu
eb550615ef
release/azure: Update reference URL
Sponsored by:	The FreeBSD Foundation
2023-06-27 15:58:55 +08:00
Doug Moore
72c3a43b16 radix_trie: skip compare in lookup_le, lookup_ge
In _lookup_ge, where a loop "looks for an available edge or val within
the current bisection node" (to quote the code comment), the value of
index has already been modified to guarantee that it is the least
value than can be found in the non-NULL child node being
examined. Therefore, if the non-NULL child is a leaf, there's no need
to compare 'index' to anything, and the value can just be returned.

The same is true for _lookup_le with 'most' replacing 'least'.
Reviewed by:	alc
Tested by:	pho
Differential Revision:	https://reviews.freebsd.org/D40746
2023-06-27 00:42:41 -05:00
Alan Cox
d8e6f4946c vm: Fix anonymous memory clustering under ASLR
By default, our ASLR implementation is supposed to cluster anonymous
memory allocations, unless the application's mmap(..., MAP_ANON, ...)
call included a non-zero address hint.  Unfortunately, clustering
never occurred because kern_mmap() always replaced the given address
hint when it was zero.  So, the ASLR implementation always believed
that a non-zero hint had been provided and randomized the mapping's
location in the address space.  To fix this problem, I'm pushing down
the point at which we convert a hint of zero to the minimum allocatable
address from kern_mmap() to vm_map_find_min().

Reviewed by:	kib
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D40743
2023-06-26 23:42:48 -05:00
John Baldwin
af296130ea nvme_xpt: Tidy nvme_announce_periph for fabrics support.
- Read the version from cts.protocol_version.

- Only check xport_specific.nvme for PCI-e info for XPORT_NVME.

Reviewed by:	chuck, imp
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D40618
2023-06-26 20:37:43 -07:00
John Baldwin
e932f0d2a3 cam_xpt: Properly fail if a sim uses an unsupported transport.
The default xport ops for a new bus is xport_default, not NULL, so
check for that when determining if a bus failed to find a suitable
transport.  In addition, the path needs to be freed with xpt_free_path
instead of a plain free so that the path's reference on the sim is
dropped; otherwise, cam_sim_free in the caller after xpt_bus_register
returns failure will hang forever.

Note that we have to exempt the xpt bus from this check as it uses
xport_default on purpose.

Reviewed by:	mav, imp
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D40617
2023-06-26 20:36:06 -07:00
John Baldwin
9c2203a691 nvme: Tidy up transfer rate settings in XPT_GET_TRAN_SETTINGS.
- Replace a magic number with CTS_NVME_VALID_SPEC.

- Set the transport and protocol versions the same as for XPT_PATH_INQ.

Probably we shouldn't bother with setting the version in the 'spec'
member of ccb_trans_settings_nvme at all and use the transport
and/or protocol version field instead.

Reviewed by:	chuck, imp
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D40616
2023-06-26 20:32:29 -07:00
John Baldwin
1aaa8f670a nvme: Don't install nvme_private.h in /usr/include.
Reviewed by:	chuck, imp
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D40394
2023-06-26 20:30:45 -07:00
Tom Hukins
e495600ce3 netstat(1): Use simpler language
Reviewed by: imp, Mina Galić
Pull Request: https://github.com/freebsd/freebsd-src/pull/771
2023-06-26 17:07:27 -06:00
VexedUXR
780332f1c1 loader.efi: Remove redundant error message
efi_copy_init already prints an error message (with more information) if it fails.

Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/777
2023-06-26 16:57:31 -06:00
Tom Hukins
3df959b5fe nohup(1): link to a related manual page
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/783
2023-06-26 16:36:25 -06:00
Tom Hukins
70bc3f4331 timeout(1): link to related manual pages
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/783
2023-06-26 16:36:25 -06:00
Andrew Fengler
f81be7a831 rc.d/routing: Correct setting default gateway for each FIB
There was a mistake in the previous commit, it used the incorrect
spelling of the FIB variable name and was not functional

Also corrects an issue with the IPv6 default route variable name.

Fixes:	30659d1dcb ("Add support for adding default routes for other FIBs")
Sponsored-by:	ScaleEngine Inc.
Differential Revision:	https://reviews.freebsd.org/D37685
2023-06-26 18:43:46 +00:00
Reid Linnemann
f0c9703301 sys/dev/ichsmb: Silence unhandled SMBALERT device_printfs
The ichsmb driver does not actually handle SMBALERT, other than by logging the
first 16 occurences of the ICH_HST_STA_SMBALERT_STS_SMBALERT status
flag. Because the SMBALERT is not acknowledged by the host, clearing it in the
host status register does not appear to work as long as some slave device is
pulling the SMBALERT line low, at least for C2000 chips. As a result, if a slave
device does pull SMBALERT low the interrupt handler will always loop its maximum
of 16 times attempting to clear all status register flags and device_printf the
status register. The result is the kernel message buffer is littered with these
device_printfs at every interrupt.

To remedy the problem, the ICH_HST_STA_SMBALERT_STS flag is zeroed in the read
host status register value, just as with ICH_HST_STA_INUSE_STS and
ICH_HST_STA_HOST_BUSY. This allows the loop to break when no other flags that
must be handled are set in the host status register. Additionally, because the
SMBALERT is not actually handled the SMBALERT logging is omitted as it has no
actual function at this time.

Reviewed by:	imp
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D39966
2023-06-26 10:29:34 +02:00
Bjoern A. Zeeb
08bc2cc4c4 LinuxKPI: cast jiffies_to_msecs() result
jiffies_to_msecs() is expected to return an uint_t.  In order to avoid
changing printf format strings, properly cast the result to the
expected type.

Sponsored by:	The FreeBSD Foundation
MFC after:	10 days
Reviewed by:	hselasky
Differential Revision: https://reviews.freebsd.org/D40486
2023-06-26 07:54:24 +00:00
Ed Maste
b2dcde7e9e Assemble .s to .o using cc, not as
As of commit fd71da37d4 we no longer have an `as` in the default
toolchain.  Although we do not make use of this rule in the base system
some ports or downstream projects might.  Use `cc -x assembler` instead
of as.

Reviewed by:	arichardson
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D35859
2023-06-25 22:03:19 -04:00
Ed Maste
5dae8905a5 seq: combine asprintf return value checks
Error handling is identical for all of these failure cases.

Sponsored by:	The FreeBSD Foundation
2023-06-25 19:57:17 -04:00
Kyle Evans
ee0aa1ce12 caroot: add new certs
Based on dates, these were likely just missed in the last update... add
them now.

- Twenty (20) new
2023-06-25 18:49:07 -05:00
Ed Maste
c079bcbc60 ifconfig: consistently sort set/clear commands
Sponsored by:	The FreeBSD Foundation
2023-06-25 16:09:26 -04:00
Konstantin Belousov
42ceab3ea1 libc.a: implement _rtld_addr_phdr()
to make __cxa_thread_call_dtors() operational for statically linked
binaries.

Noted by:	andrew
Reviewed by:	emaste, dim
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
Differential revision:	https://reviews.freebsd.org/D40748
2023-06-25 21:27:25 +03:00
Doug Moore
a42d8fe001 radix_trie: simplify trimkey functions
Replacing a branch and two shifts with a single masking operation saves 64 bytes the pair of functions lookup_le and lookup_ge on amd64.  Refresh the associated comments.
Reviewed by:	alc
Differential Revision:	https://reviews.freebsd.org/D40722
2023-06-25 12:49:15 -05:00
Ed Maste
9cbc371c8a libcrypto: build nistp* on all little-endian 64-bit targets
libcrypto intends to provide these routines on little-endian 64-bit
targets.  This was previously done by including them in the ASM_aarch64
and ASM_amd64 blocks in the Makefile, but this excluded powerpc64le and
riscv64.

Reported by:	ci.freebsd.org
Reviewed by:	jrtc27
Fixes:		b077aed33b ("Merge OpenSSL 3.0.9")
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D40749
2023-06-25 09:33:55 -04:00
Martin Matuska
f190c36b5d zfs: merge openzfs/zfs@8e8acabdc
Notable upstream pull request merges:
  #14987 Fix memory leak in zil_parse()

Obtained from:	OpenZFS
OpenZFS commit:	8e8acabdca
2023-06-25 10:32:42 +02:00
Ed Maste
229d643c4d depend-cleanup: apply big hammer for OpenSSL 3.0 update
If we find an object corresponding to a source file that existed in
OpenSSL 1.1.1 but not in 3.0 just remove all of the OpenSSL objdirs.

Reviewed by:	dhw
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D40750
2023-06-24 19:46:09 -04:00
Piotr Kubaj
5581cf903f share/mk/bsd.cpu.mk: drop -mno-powerpc64
Clang doesn't have -mno-powerpc64.

Differential revision:	https://reviews.freebsd.org/D40589
Approved by:	jhibbits
2023-06-24 22:01:47 +02:00
Mitchell Horne
ba84e87055 pmc: clean up remaining Pentium man page references
These have been removed.

Fixes:	d78896e46f ("pmc(3): remove Pentium-related man pages...")
MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
2023-06-24 16:30:00 -03:00
Mitchell Horne
17e97d41e7 hwpmc: add 'flags' local to pmc_op_do_pmcallocate()
Similar to the other allocation parameters. No functional change.

MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
2023-06-24 16:29:59 -03:00
Alan Cox
0d2f98c2f0 amd64 pmap: Tidy up pmap_promote_pde() calls
Since pmap_ps_enabled() is true by default, check it inside of
pmap_promote_pde() instead of at every call site.

Modify pmap_promote_pde() to return true if the promotion succeeded and
false otherwise.  Use this return value in a couple places.

Reviewed by:	kib, markj
Differential Revision:	https://reviews.freebsd.org/D40744
2023-06-24 13:09:04 -05:00
Ed Maste
564c5314f6 UPDATING: Add OpenSSL 3.0 update 2023-06-24 08:14:58 -04:00
Christos Margiolis
59833b089e arm64: improve KTR_TRAP trace entries
Follow-up of 7756232199 ("riscv: improve KTR_TRAP trace entries").

Reviewed by:	markj
Approved by:    markj (mentor)
Sponsored by:   The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D40696
2023-06-24 08:23:14 +03:00
Enji Cooper
6f6446b330 Do not expose architecture specific symbols
The following methods have existed since 1.0.2, however, they are
deprecated and are not available on all architectures.

- EC_GFp_nistp224_method
- EC_GFp_nistp256_method
- EC_GFp_nistp521_method

Do not expose them via libcrypto.

Discussed with:	emaste
2023-06-24 03:13:45 -07:00
Ed Maste
9ead001d5b Bump __FreeBSD_version for OpenSSL 3.0 update
Reported by:	bofh
Sponsored by:	The FreeBSD Foundation
2023-06-23 22:16:34 -04:00
Enji Cooper
bc1027a778 libfetch: remove all old OpenSSL support
This change removes pre-OpenSSL 1.1 supporting code and removes/adjusted
preprocessor conditionals which were tautilogically true as FreeBSD main
has shipped with OpenSSL 1.1+ for some time.

Reviewed by:	emaste
Differential Revision:	https://reviews.freebsd.org/D40711
2023-06-24 01:45:02 -07:00
Doug Moore
e8efee297c radix_trie: avoid reloading radix node
In the vm_radix:remove loop that searches for the last child, load
that child once, without loading it again after the search is over.
Change KASSERTS from index check to NULL node check.
Reviewed by:	alc
Differential Revision:	https://reviews.freebsd.org/D40721
2023-06-23 18:47:23 -05:00
Pierre Pronchery
e23d45187b libarchive: Avoid a build failure with OpenSSL 3.0
This is a minimal workaround; a proper fix will come via a future update
from upstream.

Sponsored by:	The FreeBSD Foundation
2023-06-23 18:53:36 -04:00
Pierre Pronchery
5abd4d378e kerberos: Request the OpenSSL 1.1 API
This is needed to build with OpenSSL 3.0; a future update should switch
to using native OpenSSL 3 APIs.

Sponsored by:	The FreeBSD Foundation
2023-06-23 18:53:36 -04:00