]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
2 years agolinux(4): Implement utimensat_time64 system call.
Dmitry Chagin [Mon, 7 Jun 2021 01:54:30 +0000 (04:54 +0300)]
linux(4): Implement utimensat_time64 system call.

MFC after: 2 weeks

(cherry picked from commit e4bffb80bbc6a2e4b3be89aefcbd5bb2c2fc0ba0)

2 years agolinux(4): add struct timespec64 definition and conversion routine for
Dmitry Chagin [Mon, 7 Jun 2021 01:47:12 +0000 (04:47 +0300)]
linux(4): add struct timespec64 definition and conversion routine for
future use.

MFC after: 2 weeks

(cherry picked from commit bfcce1a9f6e3c9defde10bb1f83d4ba9752c23f6)

2 years agolinux(4): Microoptimize futimesat, utimes, utime.
Dmitry Chagin [Mon, 31 May 2021 19:54:18 +0000 (22:54 +0300)]
linux(4): Microoptimize futimesat, utimes, utime.
While here wrap long line.

Differential Revision: https://reviews.freebsd.org/D30488
MFC after: 2 weeks

(cherry picked from commit 2a0fa277f66b0dc81a97d0f7fc6dc91ff5a7fd9c)

2 years agolinux(4): Handle AT_EMPTY_PATH in the utimensat syscall.
Dmitry Chagin [Mon, 31 May 2021 19:37:06 +0000 (22:37 +0300)]
linux(4): Handle AT_EMPTY_PATH in the utimensat syscall.

Differential Revision: https://reviews.freebsd.org/D30518
MFC after: 2 weeks

(cherry picked from commit b4f9b6eef2bb30059cf1040383c88c94f4d093a5)

2 years agolinux(4): Convert flags before use in utimensat.
Dmitry Chagin [Mon, 31 May 2021 19:30:37 +0000 (22:30 +0300)]
linux(4): Convert flags before use in utimensat.

Differential Revision: https://reviews.freebsd.org/D30487
MFC after: 2 weeks

(cherry picked from commit 8505eb5dd8f743f29e9c93b6814a34f1890e6c41)

2 years agolinux(4): Add F_GETPIPE_SZ fcntl operation which returns the capacity
Dmitry Chagin [Mon, 31 May 2021 19:15:02 +0000 (22:15 +0300)]
linux(4): Add F_GETPIPE_SZ fcntl operation which returns the capacity
of the pipe referred by fd.

Differential Revision: https://reviews.freebsd.org/D30517
MFC after: 2 weeks

(cherry picked from commit a06c12464bb49750c6b113c971e2770408ce422a)

2 years agolinux(4); Retire unnecessary __packed attribute from some struct's
Dmitry Chagin [Mon, 31 May 2021 18:56:34 +0000 (21:56 +0300)]
linux(4); Retire unnecessary __packed attribute from some struct's
definition.

Differential Revision: https://reviews.freebsd.org/D30482
MFC after: 2 weeks

(cherry picked from commit 19593f775c23623571cac4cf638996f5c11e91f4)

2 years agolinux: remove redundant SDT tracepoints
Dmitry Chagin [Fri, 17 Jun 2022 19:22:15 +0000 (22:22 +0300)]
linux: remove redundant SDT tracepoints

Remove all the 'entry' and 'return' probes; they clutter up the source
and are redundant to FBT.

Reviewed By:    dchagin
Sponsored By:   EPSRC
Differential Revision:  https://reviews.freebsd.org/D30040

(cherry picked from commit 5e8caee259d0cc73301b8fc60c8fb388e7f745af)

2 years agolinux(4): make linkat(2) handle AT_EMPTY_PATH
Edward Tomasz Napierala [Tue, 4 May 2021 12:09:31 +0000 (13:09 +0100)]
linux(4): make linkat(2) handle AT_EMPTY_PATH

Sponsored By: EPSRC
Differential Revision: https://reviews.freebsd.org/D29974

(cherry picked from commit ee384b229dc62b2b0c9180db8c71fa99f30144cf)

2 years agokern_linkat: modify to accept AT_ flags instead of FOLLOW/NOFOLLOW
Edward Tomasz Napierala [Sun, 25 Apr 2021 13:13:02 +0000 (14:13 +0100)]
kern_linkat: modify to accept AT_ flags instead of FOLLOW/NOFOLLOW

This makes this API match other kern_xxxat() functions.

Reviewed By: kib
Sponsored By: EPSRC
Differential Revision: https://reviews.freebsd.org/D29776

(cherry picked from commit 5d1d844a77622878cd05478d4ab504f70e067248)

2 years agoUpdate tools/regression/poll/sockpoll.c for POLLRDPOLL.
Thomas Munro [Wed, 28 Apr 2021 11:08:27 +0000 (23:08 +1200)]
Update tools/regression/poll/sockpoll.c for POLLRDPOLL.

Add a POLLRDHUP example to this tool, for comparison with other
operating systems.  Also record current output on FreeBSD and Linux.

Reviewed by:    kib
MFC after:      1 month
Differential Revision:  https://reviews.freebsd.org/D29757

(cherry picked from commit 18f21f0355481283ceef0ec10e99554f44c205c2)

2 years agopoll(2): Add POLLRDHUP.
Thomas Munro [Wed, 28 Apr 2021 09:31:38 +0000 (21:31 +1200)]
poll(2): Add POLLRDHUP.

Teach poll(2) to support Linux-style POLLRDHUP events for sockets, if
requested.  Triggered when the remote peer shuts down writing or closes
its end.

Reviewed by: kib
MFC after: 1 month
Differential Revision: https://reviews.freebsd.org/D29757

(cherry picked from commit 3aaaa2efde896e19d229ee2cf09fe7e6ab0fbf6e)

2 years agolinux: drop unneeded casts
Edward Tomasz Napierala [Mon, 15 Feb 2021 12:34:10 +0000 (12:34 +0000)]
linux: drop unneeded casts

No functional changes.

Sponsored By: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D28533

(cherry picked from commit cc743b050acf59862b268296d50923d6e5f0e86f)

2 years agoLoader: support booting OS from memory disk (MD)
Yongbo Yao [Wed, 7 Apr 2021 18:33:22 +0000 (13:33 -0500)]
Loader: support booting OS from memory disk (MD)

Until now, the boot image can be embedded into the loader with
/sys/tools/embed_mfs.sh, and memory disk (MD) is already supported
in loader source. But due to memory disk (MD) driver isn't registered
to the loader yet, the boot image can't be boot from embedded memory
disk.

Reviewed by: dab, tsoome
MFC after: 1 week
Sponsored by: Dell EMC Isilon
Differential Revision: https://reviews.freebsd.org/D29512

(cherry picked from commit 5984246f9626fbc3d356ee2d3b3cd159f6d0a7c2)

2 years agobsdinstall/scripts/docsinstall: Add Indonesian Documentation
Marc Fonvieille [Mon, 6 Jun 2022 11:40:56 +0000 (13:40 +0200)]
bsdinstall/scripts/docsinstall: Add Indonesian Documentation

Add Indonesian Documentation to docinstall menu.

Approved by: doceng (implicit) re (gjb, implicit)
MFC after: 1 week

(cherry picked from commit 45ef6b4b5db14eaadb1c8c2eda48353c112fd2ae)

2 years agosshd_config: clarify password authentication options
Ed Maste [Wed, 25 May 2022 13:32:57 +0000 (09:32 -0400)]
sshd_config: clarify password authentication options

Passwords may be accepted by both the PasswordAuthentication and
KbdInteractiveAuthentication authentication schemes.  Add a reference to
the latter in the description/comment for PasswordAuthentication, as it
otherwise may seem that "PasswordAuthentication no" implies passwords
will be disallowed.

This situation should be clarified with more extensive documentation on
the authentication schemes and configuration options, but that should be
done in coordination with upstream OpenSSH.  This is a minimal change
that will hopefully clarify the situation without requiring an extensive
local patch set.

PR: 263045
Reviewed by: manu (earlier version)
MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D35272

(cherry picked from commit 9f009e066f088e2c31442db31d2a85001040abfe)

2 years agogetpagesize(3): add .Xr to sysconf(3)
Ed Maste [Mon, 30 May 2022 19:34:34 +0000 (15:34 -0400)]
getpagesize(3): add .Xr to sysconf(3)

POSIX deprecated getpagesize(3).  The portable way to obtain the page
size is `sysconf(_SC_PAGESIZE)`.

Reviewed by: cperciva (earlier), imp
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D35352

(cherry picked from commit 49c937e7040c44afdcfccede57dcecaf9ff08ed6)

2 years agosyscons: note incompatibility with UEFI
Ed Maste [Thu, 26 May 2022 00:19:24 +0000 (20:19 -0400)]
syscons: note incompatibility with UEFI

PR: 264226
MFC after: 1 week
Sponsored by: The FreeBSD Foundation

(cherry picked from commit 20b2b464ebb6748756e262d8a421509a2937c74b)

2 years agomakefs: sort cd9660 sysid entries in man page
Ed Maste [Wed, 18 May 2022 19:38:54 +0000 (15:38 -0400)]
makefs: sort cd9660 sysid entries in man page

"efi" was added at the end of the sysid list rather than in alpha
order.  Move it as a diff reduction against NetBSD.

(cherry picked from commit ec3c01ae7233088057395aa50be2439d1abde828)

2 years agoloader.efi: add cross-reference to loader(8)
Ed Maste [Wed, 18 May 2022 14:33:20 +0000 (10:33 -0400)]
loader.efi: add cross-reference to loader(8)

The loader.efi man page describes UEFI-specific loader details, but not
general loader information.

MFC after: 3 days
Sponsored by: The FreeBSD Foundation

(cherry picked from commit f70de61e567df59bceb2d18c8bc1b54943a7466b)

2 years agourtw(4): Adjust all pause calls to use milliseconds instead of ticks.
Hans Petter Selasky [Thu, 9 Jun 2022 13:11:29 +0000 (15:11 +0200)]
urtw(4): Adjust all pause calls to use milliseconds instead of ticks.

Sponsored by: NVIDIA Networking

(cherry picked from commit c6c22ebb38e7371191e2f8c411b81011ecbe096a)

2 years agoupgt(4): Adjust all pause calls to use milliseconds instead of ticks.
Hans Petter Selasky [Thu, 9 Jun 2022 13:14:17 +0000 (15:14 +0200)]
upgt(4): Adjust all pause calls to use milliseconds instead of ticks.

Sponsored by: NVIDIA Networking

(cherry picked from commit bc2e447338b7ade8d800d1f24913bb3873c65f99)

2 years agoMerge llvm-project release/14.x llvmorg-14.0.5-0-gc12386ae247c
Dimitry Andric [Sun, 12 Jun 2022 18:51:09 +0000 (20:51 +0200)]
Merge llvm-project release/14.x llvmorg-14.0.5-0-gc12386ae247c

This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and
openmp to llvmorg-14.0.5-0-gc12386ae247c, aka 14.0.5 release.

PR: 261742
MFC after: 3 days

(cherry picked from commit 56f451bb3b99a72f73d6771b98825a0b00784e7b)

2 years agoFix mtree for usr/
Xin LI [Sun, 12 Jun 2022 04:37:15 +0000 (21:37 -0700)]
Fix mtree for usr/

MFC after: 3 days

(cherry picked from commit 695052e240c7c4291707a55358fe79de9ef79767)

Account for missing `..' in BSD.usr.dist for clang 14.0.3.

MFC after: 3 days

(cherry picked from commit 1d25053e9365e99a2d16f2ee64d3416f14f7f167)

Remove yet another incorrect .. level from BSD.usr.dist

Since the spacing was off, it was not clear that it descended one level
too many.

Fixes: 695052e240c7
MFC after: 3 days

(cherry picked from commit 987d26ee3f7a1685f7070db834478964170b6f62)

2 years agomlx4core: Use-after-free causes a resource leak in flow-steering detach
Hans Petter Selasky [Tue, 7 Jun 2022 14:27:53 +0000 (16:27 +0200)]
mlx4core: Use-after-free causes a resource leak in flow-steering detach

mlx4_QP_FLOW_STEERING_DETACH_wrapper first removes the steering
rule (which results in freeing the rule structure), and then
references a field in this struct (the qp number) when releasing the
busy-status on the rule's qp.

Since this memory was freed, it could reallocated and changed.
Therefore, the qp number in the struct may be incorrect,
so that we are releasing the incorrect qp. This leaves the rule's qp
in the busy state (and could possibly release an incorrect qp as well).

Fix this by saving the qp number in a local variable, for use after
removing the steering rule.

Linux commit:
3b01fe7f91c8e4f9afc4fae3c5af72c14958d2d8

PR:       264469
Sponsored by: NVIDIA Networking

(cherry picked from commit dd2a8c8f72d369440c36f10512324d42ecedb5c7)

2 years agoktls: Refer send tag pointer once.
Hans Petter Selasky [Wed, 25 May 2022 12:16:27 +0000 (14:16 +0200)]
ktls: Refer send tag pointer once.

So that the asserts and the actual code see the same values.

Differential revision: https://reviews.freebsd.org/D32356
Sponsored by: NVIDIA Networking

(cherry picked from commit f0fca64618045bba23f4d61a377b64f9acb96220)

2 years agong_ubt(4): Probe USB Bluetooth per USB interface and not per USB device.
Hans Petter Selasky [Fri, 3 Jun 2022 08:22:54 +0000 (10:22 +0200)]
ng_ubt(4): Probe USB Bluetooth per USB interface and not per USB device.

PR: 264416
Sponsored by: NVIDIA Networking

(cherry picked from commit 9d28e15e7bbee7a809eb4ccab558d114d4343312)

2 years agoRegen src.conf.5 for recent MFCs
Ed Maste [Tue, 14 Jun 2022 00:34:43 +0000 (20:34 -0400)]
Regen src.conf.5 for recent MFCs

2 years agofdescfs: allow chown/utime etc on fdescfs fd for underlying files opened with O_PATH
Konstantin Belousov [Sun, 5 Jun 2022 18:49:09 +0000 (21:49 +0300)]
fdescfs: allow chown/utime etc on fdescfs fd for underlying files opened with O_PATH

(cherry picked from commit 156745b42d9e6dfa3d9c6dc480db7836683850cf)

2 years agoAlso define THR_PAGE_SIZE_MIN for mips
Dimitry Andric [Mon, 13 Jun 2022 18:55:23 +0000 (20:55 +0200)]
Also define THR_PAGE_SIZE_MIN for mips

Commit 6173c7833be4, which cherry-picked commit c7904405a8d4 ("Remove
PAGE_SIZE from libthr") to stable/13 resulted in build errors on mips:

/usr/src/lib/libthr/thread/thr_barrier.c:40:50: error: use of undeclared identifier 'THR_PAGE_SIZE_MIN'
_Static_assert(sizeof(struct pthread_barrier) <= THR_PAGE_SIZE_MIN,
                                                 ^

This is because c7904405a8d4 defined THR_PAGE_SIZE_MIN for all supported
architectures in main/14-CURRENT, but that list no longer includes mips.
Add a similar define for mips, so libthr can build successfully again.

Direct commit to stable/13, since main no longer has mips.

Fixes: 6173c7833be4

2 years agosrc.conf.5: Update the WITHOUT_ZFS description
Mark Johnston [Mon, 30 May 2022 14:45:57 +0000 (10:45 -0400)]
src.conf.5: Update the WITHOUT_ZFS description

... to take into account programs and libraries which might implement
some ZFS-specific features without being exclusive to ZFS.

Reviewed by: emaste
Sponsored by: The FreeBSD Foundation

(cherry picked from commit f7f387730e3fc7d6e3807c1300269cd127ad3234)

2 years agosmp: Use local copies of the setup function pointer and argument
Yuichiro NAITO [Mon, 6 Jun 2022 15:21:33 +0000 (11:21 -0400)]
smp: Use local copies of the setup function pointer and argument

No functional change intended.

PR: 264383
Reviewed by: jhb, markj

(cherry picked from commit 8d95f500521128c2b40270bdd703a54b56dbccf2)

2 years agopkgbase: Move pw to the runtime package
Doug Rabson [Mon, 30 May 2022 13:22:08 +0000 (14:22 +0100)]
pkgbase: Move pw to the runtime package

This allows building a container image with enough functionality for
downloading and installing packages without having to include the
utilities package.

Reviewed by: manu
MFC after:   2 weeks

(cherry picked from commit 5e9c888a7ac014f81bcf369ff3d38690d51545ee)

2 years agosqlite3: Vendor import of sqlite3 3.38.5
Cy Schubert [Thu, 12 May 2022 19:25:36 +0000 (12:25 -0700)]
sqlite3: Vendor import of sqlite3 3.38.5

Changes at https://www.sqlite.org/releaselog/3_38_5.html.

Obtained from https://www.sqlite.org/2022/sqlite-autoconf-3380500.tar.gz.

Merge commit 'b562e59e27efbea397bdc8782dfceaa3c0e23542'

(cherry picked from commit 4fe1295c964fa712dd763e3852187da8724ef79a)

2 years agomount_nfs: Only create a mounttab file entry is nmount(2) succeeds
Rick Macklem [Sat, 28 May 2022 22:48:40 +0000 (15:48 -0700)]
mount_nfs: Only create a mounttab file entry is nmount(2) succeeds

mount_nfs creates entries in the mounttab file and umount removes
them.  Entries in the mounttab file ae used by rpc.umntall to
notify the NFS server that NFSv3 entries need to be removed when
they have not been removed by umount.

Without this patch, an enty will be created in the mounttab file,
even if the nmount(2) syscall fails for the mount.  This patch
modifies the code so that the mounttab entry is only created
after nmount(2) succeeds.

This change only affects NFSv3 and only affects how showmount
displays NFSv3 mounts.

(cherry picked from commit 7cab630ba4fb26bf85336a89d88721ed2315c46c)

2 years agonfscl: Add a diagnostic printf() for a "should never happen" case
Rick Macklem [Fri, 27 May 2022 21:32:46 +0000 (14:32 -0700)]
nfscl: Add a diagnostic printf() for a "should never happen" case

When a NFSv4.1/4.2 session to the NFS server (not a pNFS DS) is
replaced, the old session should always be marked defunct by
nfsess_defunct being set non-zero.

However, the hang reported by the PR suggests that this might
be the case.

This patch adds a printf() to indicate this has somehow happened.

PR: 260011

(cherry picked from commit a7bb120f8b8735bc4c417b3c8fc2308c3d2964aa)

2 years agonfscl: Do not handle NFSERR_BADSESSION in operation code
Rick Macklem [Fri, 27 May 2022 21:20:31 +0000 (14:20 -0700)]
nfscl: Do not handle NFSERR_BADSESSION in operation code

The NFSERR_BADSESSION reply from a NFSv4.1/4.2 server
is handled by newnfs_request().  It should not be handled
separately after newnfs_request() has returned.

These two cases were spotted during code inspection.
One of them should only redo what newnfs_request() already
did by the same "nfscl" thread.  The other might have
resulted in recovery being done twice, but the code is
only used for "pnfs" mounts, so that would be rare.
Also, since NFSERR_BADSESSION should only be replied by
a server after the server reboots, this would be extremely
rare.

(cherry picked from commit 425e5c739bcf190265330b79e85f89eb4d7b5f25)

2 years agofirewire.4: Fix typo
PauAmma [Mon, 6 Jun 2022 03:52:34 +0000 (23:52 -0400)]
firewire.4: Fix typo

While there, replace dead wiki URL with dev handbook one and fix markup.

Reviewed by: gbe
Differential Revision: https://reviews.freebsd.org/D35252

(cherry picked from commit eabfcbbfe1a4bee09d1dab659116ccbb8e36f88f)

2 years agobuild(7): fix references to svn(1) and svnlite(1)
Fernando Apesteguía [Fri, 23 Apr 2021 16:59:19 +0000 (18:59 +0200)]
build(7): fix references to svn(1) and svnlite(1)

Replace them with references to Git.

PR: 254937
Reported by: m.bueker@berlin.de
Approved by: 0mp (mentor)
Differential Revision: https://reviews.freebsd.org/D29949

(cherry picked from commit e444a4c677ee3e86038ba2179c4838f5f4b778cd)

2 years agoal_eth: Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 13:33:36 +0000 (15:33 +0200)]
al_eth: Fix a typo in a source code comment

- s/enought/enough/

(cherry picked from commit 45b143d2ea5fb0389304cc918781e98696a4b48f)

2 years agoipsec(4): Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 10:28:20 +0000 (12:28 +0200)]
ipsec(4): Fix a typo in a source code comment

- s/formated/formatted/

(cherry picked from commit 7a33c6bf52b747a1725a2a3665c438cd5a9e9355)

2 years agofstype(8): Fix two typos in source code comments
Gordon Bergling [Sat, 4 Jun 2022 08:38:48 +0000 (10:38 +0200)]
fstype(8): Fix two typos in source code comments

- s/auxillary/auxiliary/

(cherry picked from commit df4da2d6b7bc96abb1ae78bb1f2d28150124bd15)

2 years agorack: Fix a common typo in comments and a sysctl description
Gordon Bergling [Sat, 4 Jun 2022 15:56:56 +0000 (17:56 +0200)]
rack: Fix a common typo in comments and a sysctl description

- s/multipler/multiplier/

(cherry picked from commit 32a01b2b8691453b59a26cf273a5a5eae7643985)

2 years agoamdsbwd(4): Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 09:26:44 +0000 (11:26 +0200)]
amdsbwd(4): Fix a typo in a source code comment

- s/accross/across/

(cherry picked from commit 68c0bd3e3f45e030d48b354d7444934ca381a07e)

2 years agoufs: Fix a typo a source code comment
Gordon Bergling [Sat, 4 Jun 2022 13:23:53 +0000 (15:23 +0200)]
ufs: Fix a typo a source code comment

- s/droped/dropped/

(cherry picked from commit a429d3050ec3f2a807d6e74be80b055ee636cb6f)

2 years agolinux(4): Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 09:27:19 +0000 (11:27 +0200)]
linux(4): Fix a typo in a source code comment

- s/accross/across/

(cherry picked from commit 8cf0d094629edbafc1d6de055cef6a53d6a4addb)

2 years agopowerpc: Fix a typo in a comment
Gordon Bergling [Sat, 4 Jun 2022 17:55:03 +0000 (19:55 +0200)]
powerpc: Fix a typo in a comment

- s/layed/laid/

(cherry picked from commit 23615a3e4e41f55693980fdcb6842a25754741c9)

2 years agopowerpc: Fix two typos in source code comments
Gordon Bergling [Sat, 4 Jun 2022 08:39:50 +0000 (10:39 +0200)]
powerpc: Fix two typos in source code comments

- s/auxillary/auxiliary/

(cherry picked from commit d8dd4b2fd2bdedb33978692c82fc494aa594b8b2)

2 years agonvmw(4): Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 09:46:03 +0000 (11:46 +0200)]
nvmw(4): Fix a typo in a source code comment

- s/inaccessable/inaccessible/

(cherry picked from commit 6e8ab6715d3589ad5577ad5fa408f81b4a7077e9)

2 years agotegra: Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 09:54:09 +0000 (11:54 +0200)]
tegra: Fix a typo in a source code comment

- s/Disble/Disable/

(cherry picked from commit 415e8d12d12808897fe23f06637e942f5a4a2d06)

2 years agomake.conf: Fix a typo in the example file
Gordon Bergling [Sat, 4 Jun 2022 10:24:17 +0000 (12:24 +0200)]
make.conf: Fix a typo in the example file

- s/architechture/architecture/

(cherry picked from commit 6300e58ab2d2575852e15724a74d545cea32cef5)

2 years agousbhid(3): Fix a typo in the manual page
Gordon Bergling [Sat, 4 Jun 2022 17:54:25 +0000 (19:54 +0200)]
usbhid(3): Fix a typo in the manual page

- s/layed/laid/

(cherry picked from commit 9b15c51b0551fe09d589d06e654ce61584e3f61c)

2 years agovm_page: Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 10:52:22 +0000 (12:52 +0200)]
vm_page: Fix a typo in a source code comment

- s/consistancy/consistency/

(cherry picked from commit f77a88c855c557902e4e4c9696b08e847c413f54)

2 years agotcp_rack: Fix two typos in sysctl descriptions
Gordon Bergling [Sat, 4 Jun 2022 09:24:18 +0000 (11:24 +0200)]
tcp_rack: Fix two typos in sysctl descriptions

- s/higest/highest/

(cherry picked from commit 21b923c33082b0123a7c638e8984fd313c3a6f1f)

2 years agoaic7xxx: Fix a few typos in comments and an error message
Gordon Bergling [Sat, 4 Jun 2022 14:49:53 +0000 (16:49 +0200)]
aic7xxx: Fix a few typos in comments and an error message

- s/directrive/directive/
- s/specifiled/specified/
- s/Decend/Descend/
- s/tranversal/transversal/

Obtained from: NetBSD

(cherry picked from commit d35e1c29a9bb5c2ed98a6d8df171b3b3c8439130)

2 years agoac(8): Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 10:41:20 +0000 (12:41 +0200)]
ac(8): Fix a typo in a source code comment

- s/chosing/choosing/

(cherry picked from commit 10924c4fc3bec1a3170681e42c3a854845584a51)

2 years agoena(4): Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 15:17:04 +0000 (17:17 +0200)]
ena(4): Fix a typo in a source code comment

- s/entred/entered/

(cherry picked from commit eb3f25b413c5d8912cdb40f2040a0b678a2af2fd)

2 years agokthread(9): Add a missing space
Gordon Bergling [Sat, 4 Jun 2022 18:15:07 +0000 (20:15 +0200)]
kthread(9): Add a missing space

- s/inthe/in the/

(cherry picked from commit a7f5cf2096346076ef16bed9c40b21d3d7a7bd8f)

2 years agosound(4): Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 10:11:06 +0000 (12:11 +0200)]
sound(4): Fix a typo in a source code comment

- s/alltogether/altogether/

(cherry picked from commit 70311ccffc2f9233cc4c3db1bb706f0566d6818d)

2 years agohptmv(4): Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 11:28:52 +0000 (13:28 +0200)]
hptmv(4): Fix a typo in a source code comment

- s/continous/continuous/

(cherry picked from commit bbb0ca45f8189911a35ba76000783b05188153af)

2 years agofpu: Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 11:15:53 +0000 (13:15 +0200)]
fpu: Fix a typo in a source code comment

- s/choise/choice/

Obtained from: NetBSD

(cherry picked from commit faff37be462262c6ae958c93f0aa27118d4d62cf)

2 years agole(4): Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 10:00:44 +0000 (12:00 +0200)]
le(4): Fix a typo in a source code comment

- s/brodcast/broadcast/

(cherry picked from commit b008ab622c401ee2e705b1fe5804865982dac11c)

2 years agoif_bridge(4): Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 09:26:01 +0000 (11:26 +0200)]
if_bridge(4): Fix a typo in a source code comment

- s/accross/across/

(cherry picked from commit f7faa4ad4844470058b84fa35156c463cfa8bd85)

2 years agorack: Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 13:32:59 +0000 (15:32 +0200)]
rack: Fix a typo in a source code comment

- s/enought/enough/

(cherry picked from commit c93db89231fedd4afe64915cf8dcad89bfdd3c94)

2 years agoif_llatbl: Fix a typo in a debug statement
Gordon Bergling [Sat, 4 Jun 2022 13:22:09 +0000 (15:22 +0200)]
if_llatbl: Fix a typo in a debug statement

- s/droped/dropped/

Obtained from: NetBSD

(cherry picked from commit 4f493559b0d7853c7521bd3cb5affe659914e479)

2 years agonvmecontrol(8): Fix a typo in an error message
Gordon Bergling [Sat, 4 Jun 2022 18:30:48 +0000 (20:30 +0200)]
nvmecontrol(8): Fix a typo in an error message

- s/insufficent/insufficient/

(cherry picked from commit e2dfabb5895122ce46e627e53347f0e81019c95f)

2 years agoacpi(4): Fix a typo in a debug statement
Gordon Bergling [Sat, 4 Jun 2022 13:17:09 +0000 (15:17 +0200)]
acpi(4): Fix a typo in a debug statement

- s/Efficency/tEfficiency/

Obtained from: NetBSD

(cherry picked from commit 0b4302aa934d748503d6377f875f2972db41a092)

2 years agoif_sis(4): Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 14:56:18 +0000 (16:56 +0200)]
if_sis(4): Fix a typo in a source code comment

- s/emperical/empirical/

(cherry picked from commit 3c2ea3ca28c5e95185f57ff27148909c8f846c3e)

2 years agosed(1): Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 18:27:45 +0000 (20:27 +0200)]
sed(1): Fix a typo in a source code comment

- s/Initialy/Initially/

Obtained from: NetBSD

(cherry picked from commit bb0e21032bf61a93489f8b964b6707038cc4d1c3)

2 years agoam335x: Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 11:28:10 +0000 (13:28 +0200)]
am335x: Fix a typo in a source code comment

- s/continous/continuous/

(cherry picked from commit 1261c01d7fa25955610936f690e237b7c308ee5b)

2 years agoaic79xx: Fix a typo in a source code comment
Gordon Bergling [Sat, 4 Jun 2022 09:52:34 +0000 (11:52 +0200)]
aic79xx: Fix a typo in a source code comment

- s/Disble/Disable/

Obtained from: NetBSD

(cherry picked from commit 2cada72c65931683121ea7f6f740a7d07420c367)

2 years agovm: Fix a common typo in a source code comment
Gordon Bergling [Sun, 5 Jun 2022 07:52:32 +0000 (09:52 +0200)]
vm: Fix a common typo in a source code comment

- s/independant/independent/

(cherry picked from commit 860740ae0f0f247b2dabd15fcfa0c215f77e5858)

2 years agonlist(3): Fix a common typo in a source code comment
Gordon Bergling [Sun, 5 Jun 2022 07:51:57 +0000 (09:51 +0200)]
nlist(3): Fix a common typo in a source code comment

- s/independant/independent/

(cherry picked from commit 565405095b88a00df786614cdaabfdd3de1148ec)

2 years agogeom(4): Fix a common typo in a source code comment
Gordon Bergling [Sun, 5 Jun 2022 07:51:10 +0000 (09:51 +0200)]
geom(4): Fix a common typo in a source code comment

- s/independant/independent/

(cherry picked from commit c2a249ad8f29e326e9c18b076eadd8730e43af0b)

2 years agoqlnxe(4): Fix a typo in a source code comment
Gordon Bergling [Sun, 5 Jun 2022 07:15:33 +0000 (09:15 +0200)]
qlnxe(4): Fix a typo in a source code comment

- s/indepent/independent/

(cherry picked from commit a87f167c41c5fc9240987a09a98379680c910c51)

2 years agotwe(4): Fix a common typo in a source code comment
Gordon Bergling [Sun, 5 Jun 2022 07:55:25 +0000 (09:55 +0200)]
twe(4): Fix a common typo in a source code comment

- s/independant/independent/

(cherry picked from commit 508a46c745b34c1e520b0c00ad3e0b727967f5ae)

2 years agoqlxgbe(4): Fix a common typo in a source code comment
Gordon Bergling [Sun, 5 Jun 2022 07:56:29 +0000 (09:56 +0200)]
qlxgbe(4): Fix a common typo in a source code comment

- s/independant/independent/

(cherry picked from commit f1294737023fbb5748d6e572b0ac042281361bf7)

2 years agolibkern: Fix a typo in a source code comment
Gordon Bergling [Sun, 5 Jun 2022 06:57:26 +0000 (08:57 +0200)]
libkern: Fix a typo in a source code comment

- s/involes/involves/

Obtained from: NetBSD

(cherry picked from commit 5cacfa7092f851ce31d75cd5dde73d26ea734497)

2 years agoffec: Fix a common typo in a source code comment
Gordon Bergling [Sun, 5 Jun 2022 07:54:39 +0000 (09:54 +0200)]
ffec: Fix a common typo in a source code comment

- s/independant/independent/

(cherry picked from commit d3e0919b564d0f0267758d33c5de8008526f61a5)

2 years agoif_age(4): Fix a typo in a source code comment
Gordon Bergling [Sun, 5 Jun 2022 07:14:17 +0000 (09:14 +0200)]
if_age(4): Fix a typo in a source code comment

- s/indepent/independent/

(cherry picked from commit f207bdd2cc4fb43fed13a20dc7f892021e8a9b42)

2 years agomlx(4): Fix a common typo in a source code comment
Gordon Bergling [Sun, 5 Jun 2022 07:53:59 +0000 (09:53 +0200)]
mlx(4): Fix a common typo in a source code comment

- s/independant/independent/

(cherry picked from commit 9ae6b386ab33a701c8df281f1dbf07a1659aab90)

2 years agostand: Fix a common typo in source code comments
Gordon Bergling [Sun, 5 Jun 2022 07:49:51 +0000 (09:49 +0200)]
stand: Fix a common typo in source code comments

- s/independant/independent/

(cherry picked from commit c44b5e090d84f911551d038f61e7cf798a843b8c)

2 years agolibgssapi: Fix a common typo in a source code comment
Gordon Bergling [Sun, 5 Jun 2022 07:53:24 +0000 (09:53 +0200)]
libgssapi: Fix a common typo in a source code comment

- s/independant/independent/

(cherry picked from commit 9e75b06f93d001fc961b6e839e59977f826b6c2f)

2 years agoixgbe(4): Fix common typos in source code comments
Gordon Bergling [Mon, 6 Jun 2022 05:28:56 +0000 (07:28 +0200)]
ixgbe(4): Fix common typos in source code comments

- s/filer/filter/

Obtained from: NetBSD

(cherry picked from commit cd7e11f78dedad810273ae71d791027e75aa16c9)

2 years agonfscl: Add support for a NFSv4 AppendWrite RPC
Rick Macklem [Sat, 30 Apr 2022 20:49:23 +0000 (13:49 -0700)]
nfscl: Add support for a NFSv4 AppendWrite RPC

For IO_APPEND VOP_WRITE()s, the code first does a
Getattr RPC to acquire the file's size, before it
can do the Write RPC.

Although NFS does not have an append write operation,
an NFSv4 compound can use a Verify operation to check
that the client's notion of the file's size is
correct, followed by the Write operation.

This patch modifies the NFSv4 client to use an Appendwrite
RPC, which does a Verify to check the file's size before
doing the Write.  This avoids the need for a Getattr RPC
to preceed this RPC and reduces the RPC count by half for
IO_APPEND writes, so long as the client knows the file's
size.

The nfsd structure was moved from the stack to be malloc()'d,
since the kernel stack limit was being exceeded.

While here, fix the types of a few variables, although
there should not be any semantics change caused by these
type changes.

(cherry picked from commit 5218d82c81f987223054671b9821d39f08d87599)

2 years agonfscl: Add support for a NFSv4 AppendWrite RPC
Rick Macklem [Fri, 8 Apr 2022 20:59:05 +0000 (13:59 -0700)]
nfscl: Add support for a NFSv4 AppendWrite RPC

For IO_APPEND VOP_WRITE()s, the code first does a
Getattr RPC to acquire the file's size, before it
can do the Write RPC.

Although NFS does not have an append write operation,
an NFSv4 compound can use a Verify operation to check
that the client's notion of the file's size is
correct, followed by the Write operation.

This patch modifies nfscl_wcc_data() to optionally
acquire the file's size, for use with an AppendWrite.
Although the "stuff" arguments are always NULL
(these were used for the Mac OSX port and should be
cleared out someday), make the argument to
nfscl_wcc_data() explicitly NULL for clarity.

This patch does not cause any semantics change until
the AppendWrite is added in a future commit.

(cherry picked from commit 21de450aa1a7ca226908e7421b93ca979ff42db7)

2 years agoUnbreak the build: Also define NFSV42_OLDNPROCS here.
Warner Losh [Tue, 5 Apr 2022 17:54:20 +0000 (11:54 -0600)]
Unbreak the build: Also define NFSV42_OLDNPROCS here.

If nfsproto.h is included before nfsport.h, then NFSV42_OLDNPROCS would
be undefined when it is used in struct nfsstatsov1.

(cherry picked from commit 393b7606f9c18c27f340edb28395093b618f68bd)

2 years agonfscl: Add support for a NFSv4 AppendWrite RPC
Rick Macklem [Tue, 5 Apr 2022 15:11:37 +0000 (08:11 -0700)]
nfscl: Add support for a NFSv4 AppendWrite RPC

For IO_APPEND VOP_WRITE()s, the code first does a
Getattr RPC to acquire the file's size, before it
can do the Write RPC.

Although NFS does not have an append write operation,
an NFSv4 compound can use a Verify operation to check
that the client's notion of the file's size is
correct before doing the Write operation.

This patch prepares the NFSv4 client for such an
RPC, which will be added in a future commit.

This patch does not cause any semantics change.

(cherry picked from commit 330aa8acdec76d00d9e0ca526d421fe25ccf90cf)

2 years agoMerge llvm-project release/14.x llvmorg-14.0.4-0-g29f1039a7285
Dimitry Andric [Sat, 4 Jun 2022 12:30:46 +0000 (14:30 +0200)]
Merge llvm-project release/14.x llvmorg-14.0.4-0-g29f1039a7285

This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and
openmp to llvmorg-14.0.4-0-g29f1039a7285, aka 14.0.4 release.

PR: 261742
MFC after: 3 days

(cherry picked from commit 2a66634d1bc6d7401adafad4a3be7b9ac6bab8b3)

Bump versions llvm-project release/14.x llvmorg-14.0.4-0-g29f1039a7285

Somehow git rebase made this squashed commit disappear. Restore it.

PR: 261742
MFC after: 3 days

(cherry picked from commit ab9d54731f43bb6befae75e9fed64da98c9ae1b4)

Update rest of llvm-project build glue for 14.0.4

I completely forgot about updating the generated llvm-project config
files, which also contain version numbers, etc. Sorry for the churn.

PR: 261742
Fixes: ab9d54731f43
MFC after: 3 days

(cherry picked from commit 809922b01004daf627ad4b8d92c7f98eb579043c)

Add more old clang files to (Optional)ObsoleteFiles.inc

There were a few more libclang_rt libraries added recently, but not yet
listed in the ObsoleteFiles.inc lists.

MFC after: 3 days

(cherry picked from commit 5e383e360314c875fee648b386493b0dcde5c5f3)

2 years agonfscl: Always invalidate buffers for append writes
Rick Macklem [Thu, 6 Jan 2022 22:18:36 +0000 (14:18 -0800)]
nfscl: Always invalidate buffers for append writes

kib@ reported a problem which was resolved by
reverting commit 867c27c23a5c, which changed the NFS
client to use direct RPCs to the server for
IO_APPEND writes.  He also spotted that the
code only invalidated buffer cache buffers
when they were marked NMODIFIED (had been
written into).

This patch modifies the NFS VOP_WRITE() to
always invalidate the buffer cache buffers
and pages for the file when IO_APPEND is
specified.  It also includes some cleanup
suggested by kib@.

(cherry picked from commit e4df1036f66dc360606fea053ec04ccabb69df14)

2 years agonfscl: Partially revert commit 867c27c23a5c
Rick Macklem [Thu, 16 Dec 2021 22:30:37 +0000 (14:30 -0800)]
nfscl: Partially revert commit 867c27c23a5c

Commit 867c27c23a5c enabled the n_directio_opens code
in open/close, which sets/clears NNONCACHE, for
IO_APPEND. This code should not be enabled unless
newnfs_directio_enable is non-zero.

This patch reverts that part of commit 867c27c23a5c.

A future patch that fixes the case where the
file that is being written IO_APPEND is mmap()'d.

(cherry picked from commit 150da1e3cd51e552f7d6bc159b387e540c5a3733)

2 years agonfscl: Change IO_APPEND writes to direct I/O
Rick Macklem [Wed, 15 Dec 2021 16:35:48 +0000 (08:35 -0800)]
nfscl: Change IO_APPEND writes to direct I/O

IO_APPEND writes have always been very slow over NFS, due to
the need to acquire an up to date file size after flushing
all writes to the NFS server.

This patch switches the IO_APPEND writes to use direct I/O,
bypassing the buffer cache.  As such, flushing of writes
normally only occurs when the open(..O_APPEND..) is done.
It does imply that all writes must be done synchronously
and must be committed to stable storage on the file server
(NFSWRITE_FILESYNC).

For a simple test program that does 10,000 IO_APPEND writes
in a loop, performance improved significantly with this patch.

For a UFS exported file system, the test ran 12x faster.
This drops to 3x faster when the open(2)/close(2) are done
for each loop iteration.
For a ZFS exported file system, the test ran 40% faster.

The much smaller improvement may have been because the ZFS
file system I tested against does not have a ZIL log and
does have "sync" enabled.

Note that IO_APPEND write performance is still much slower
than when done on local file systems.

Although this is a simple patch, it does result in a
significant semantics change, so I have given it a
large MFC time.

(cherry picked from commit 867c27c23a5c469b27611cf53cc2390b5a193fa5)

2 years agortw88: plug various skb leaks in error cases
Bjoern A. Zeeb [Sun, 5 Jun 2022 18:07:48 +0000 (18:07 +0000)]
rtw88: plug various skb leaks in error cases

Based on manual inspection the skbs are not freed in those unlikely
cases, though all would give an error message so would have gone noticed
if happened.
While here fix a typo in one of these error messages.

(cherry picked from commit 728afa885f04f6316bc9ecf6498f4a635ced1e21)

2 years agoLinuxKPI: 802.11: plug a ni leak in lkpi_sta_assoc_to_run()
Bjoern A. Zeeb [Sun, 5 Jun 2022 21:10:01 +0000 (21:10 +0000)]
LinuxKPI: 802.11: plug a ni leak in lkpi_sta_assoc_to_run()

In lkpi_sta_assoc_to_run() we are going through some code segments
twice (auth->assoc, assoc->authorized).  The 2nd time we shall not
re-gain a reference on the net80211 node as otherwise it'll leak.
Likewise we do not have to re-set lsta and sta.

Sponsored by: The FreeBSD Foundation

(cherry picked from commit 71df58aefcf8be21b32e2a7b83da6d0facb8b326)

2 years agoLinuxKPI: 802.11 plug mbuf leak in error cases
Bjoern A. Zeeb [Sun, 5 Jun 2022 18:04:57 +0000 (18:04 +0000)]
LinuxKPI: 802.11 plug mbuf leak in error cases

Manually free the mbuf in certain error cases from net80211 to not
leak it.
Note that the differences between ieee80211_input_mimo() and
ieee80211_input_mimo_all(), the former not consuming the mbuf while
the later does, is confusing.

Sponsored by: The FreeBSD Foundation

(cherry picked from commit dbc06dd98ae9940377a9ef31a594c17566334977)

2 years agoiwlwifi: disable more MEI (Management Engine) code
Bjoern A. Zeeb [Sat, 4 Jun 2022 16:18:58 +0000 (16:18 +0000)]
iwlwifi: disable more MEI (Management Engine) code

It is unclear why this hasn't bothered anyone in months; I can only assume
optimization levels but it seems there were unresolved symbols in
iwlwifi after d9836fb4b9380e2ed1c38455fb31a3832b452671:
link_elf_obj: symbol iwl_mvm_send_roaming_forbidden_event undefined

Hide more of the currently unsupported (GPL-only) MEI (Management Engine)
code behind #ifdef to avoid this.

Reported by: dchagin
Tested by: dchagin
Sponsored by: The FreeBSD Foundation

(cherry picked from commit 75c779fb279c2bea90c08e275af5937213bdca81)

2 years agoiwlwifi: Update man pages with card list
Bjoern A. Zeeb [Tue, 17 May 2022 01:43:15 +0000 (01:43 +0000)]
iwlwifi: Update man pages with card list

Add list of supported names to iwlwifi.4 and an extended list with
PCI IDs and firmware prefix to iwlwififw.4.

Sponsored by: The FreeBSD Foundation
Reviewed by: imp
Differential Revision: https://reviews.freebsd.org/D35227

(cherry picked from commit f5539996511eeca7dcf3c9849edda26d85306290)

2 years agoiwlwifi: add sysctl to dump PCI IDs/ names / firmware-prefixes
Bjoern A. Zeeb [Wed, 18 May 2022 16:05:49 +0000 (16:05 +0000)]
iwlwifi: add sysctl to dump PCI IDs/ names / firmware-prefixes

Add a FreeBSD-specifc SYSCTL_PROC to dump the list of
PCI IDs / name / firmware-prefix which can be post-processed
for man pages (iwlwifi.4 and iwlwififw.4) or the wiki.

The output still yields duplicates depending on by what information
you need so one may wants to filter them out (try not to use sort/uniq).

Sponsored by: The FreeBSD Foundation

(cherry picked from commit 645886d028c85b3cb9fb36e96b1edc661cf4c0d8)

2 years agoMFC: if_glxgbe: fix stand-alone module build
Eugene Grosbein [Sun, 5 Jun 2022 17:59:46 +0000 (00:59 +0700)]
MFC: if_glxgbe: fix stand-alone module build

Fix module build outside of kernel build environment.

(cherry picked from commit 32467e47b7b7d224ca51889bbb9233af0462d87f)

2 years agoMFC: if_glxgb: fix stand-alone module build
Eugene Grosbein [Sun, 5 Jun 2022 17:54:50 +0000 (00:54 +0700)]
MFC: if_glxgb: fix stand-alone module build

Fix module build outside of kernel build environment.

(cherry picked from commit 966e279052f33b1665480e0327c177013cb8205a)