Commit graph

289891 commits

Author SHA1 Message Date
Jose Luis Duran
f7eb6b134d open(2): Extend EINVAL's description
PR:	281033

(cherry picked from commit 02c23c3b5ac9c9c1115c8b892034bb5d67b05c06)
2024-09-01 03:53:36 +03:00
Jose Luis Duran
97ccb41979 rename(2): Extend EINVAL's description
PR:	281033

(cherry picked from commit 33f58ac0795b2b02593ad0a8bf8a1ea24c1dc5e1)
2024-09-01 03:53:36 +03:00
Jose Luis Duran
f968e0819d open(2): mandoc -T lint
(cherry picked from commit f5a37f8dd319e3007b126b77376e61ad96f44d8b)
2024-09-01 03:53:36 +03:00
Jose Luis Duran
65ae1d493e msdosfs: return ENOENT if looking up invalid name for OPEN or DELETE
PR:	281033

(cherry picked from commit 0b2c159c8faa3ca155412a1b2e57b3d6bcf91880)
2024-09-01 03:53:36 +03:00
Gordon Tetlow
5a542a6055
release: Redirect etcupdate logfile to /dev/null.
Stop shipping a log file for etcupdate. This is a source of
non-reproducability as it uses mktemp thereby guaranteeing the output is
different each run.

Differential Revision:	https://reviews.freebsd.org/D46317

(cherry picked from commit e972e408d19a58c4f2855eface487d06ef73b799)
2024-08-31 09:17:55 -07:00
Rick Macklem
cfcf0db909 nfsproto.h: Define the new mode_umask attribute
RFC8275 defines a new attribute as an extension to NFSv4.2
called MODE_UMASK.  This patch adds the attribute number
to nfsproto.h.

Future patches will add optional support for the attribute.
This patch does not cause any semantics change.

(cherry picked from commit 10d5b43424da7fadfbdcc41bbffe40d130af1e1d)
2024-08-30 18:53:55 -07:00
Michael Tuexen
2dcd21ddab tcp: fix format of sysctl variable
The format for CTLTYPE_UINT is "IU" instead of "UI" as specified
in sysctl.9.

Reviewed by:		cc, zlei
Sponsored by:		Netflix, Inc.
Differential Revision:	https://reviews.freebsd.org/D46408

(cherry picked from commit 498286d4e807d6b9e4caad22b96ebca7f16e9b18)
2024-08-30 08:32:11 +02:00
Michael Tuexen
bb31f15d17 sctp: fix format of sysctl variables
(cherry picked from commit a1d9ce19b13f220c5738e6aa58cf0c3750a05526)
2024-08-30 08:31:35 +02:00
Michael Tuexen
6c0fb6c5ac tcp: improve consistency of SYN-cache handling
Originally, a SYN-cache entry was always allocated and later freed,
when not needed anymore. Then the allocation was avoided, when no
SYN-cache entry was needed, and a copy on the stack was used.
But the logic regarding freeing was not updated.
This patch doesn't re-check conditions (which may have changed) when
deciding to insert or free the entry, but uses the result of
the earlier check.
This simplifies the code and improves also consistency.

Reviewed by:		glebius
Sponsored by:		Netflix, Inc.
Differential Revision:	https://reviews.freebsd.org/D46410

(cherry picked from commit e41364711ca3f7e214f9607ebedf62e03e51633d)
2024-08-30 08:30:54 +02:00
Michael Tuexen
e0bcb3aa4f tcp: initialize the LRO hash table with correct size
There will at most lro_entries entries in the LRO hash table. So no
need to take lro_mbufs into account, which only results in the
LRO hash table being too large and therefore wasting memory.

Reviewed by:		rrs
Sponsored by:		Netflix, Inc.
Differential Revision:	https://reviews.freebsd.org/D46378

(cherry picked from commit aa6c490bf80fcef15cfc0d3f562fae19ef2375aa)
2024-08-30 08:29:50 +02:00
Michael Tuexen
118ab70d57 tcp: fix list iteration in tcp_lro_flush_active()
Use LIST_FOREACH_SAFE(), since the list element is removed from
the list in the loop body, zero out and inserted in the free list.

Reviewed by:		rrs
Sponsored by:		Netflix, Inc.
Differential Revision:	https://reviews.freebsd.org/D46383

(cherry picked from commit 64443828bbe7c571db8d8731758ec8c4b8364c86)
2024-08-30 08:29:03 +02:00
Warner Losh
455dc6ffa8 loader.efi(8): beef up the updating the ESP
There's a huge variety of situations when booting with UEFI. Document
more of them, hopefully better.

Feedback from: jrtc27
MFC After: 3 days
Sponsored by:		Netflix

(cherry picked from commit 871911a4ab738a54a88f3533f553f5eb68c28012)
2024-08-29 12:12:27 -06:00
Konstantin Belousov
43605618aa amd64: use INVLPGB for kernel pmap invalidations
(cherry picked from commit 47656cc1ef1cac307f24de88a4fe23a1389af44e)
2024-08-28 03:26:34 +03:00
Konstantin Belousov
23117748f2 amd64: add variables indicating INVLPGB works
(cherry picked from commit bc4ffcadf2681c954444e1853200dca3f5e65676)
2024-08-28 03:26:34 +03:00
Konstantin Belousov
c3cd4db461 amd64: add convenience wrappers for INVLPGB and TBLSYNC
(cherry picked from commit 111c7fc2fe21356a637f89fa58c407958f05ad93)
2024-08-28 03:26:34 +03:00
Konstantin Belousov
d66c4853b8 DMAR: clear dmar_devs[unit] if attach failed
PR:	280817

(cherry picked from commit 45543d3424d46f84a5399879e190fc359dcefbd4)
2024-08-28 03:26:33 +03:00
John Baldwin
7b9327d6b2 defaults/rc.conf: Remove /usr/lib32 from ldconfig32_paths
Commit 99132daf6f70cb0cc969c555d3612547fa3cf1db prepends /usr/lib32 to
the list of paths in ldconfig32_paths since it is a standard library
path in ld-elf32.so.1.  Remove /usr/lib32 from the value in rc.conf so
that it is not listed twice.

Reviewed by:	olce, kib
Sponsored by:	University of Cambridge, Google, Inc.
Differential Revision:	https://reviews.freebsd.org/D44752

(cherry picked from commit 4bf5db113f760619bf754c22864b1d7e2acdeabd)
2024-08-27 14:15:55 -04:00
Konrad Witaszczyk
ee104259c7 rc.d/ldconfig: Compute ldconfig paths in a function
Move logic that computes paths passed to ldconfig(8) to a
ldconfig_paths() function that can be called for multiple ABIs.

Reviewed by:	olce, kib
Obtained from:	CheriBSD
Differential Revision:	https://reviews.freebsd.org/D44751

(cherry picked from commit e6e38bc522e29de6299536b547bf11dab11e9679)
2024-08-27 14:15:48 -04:00
John Baldwin
52bc3fae71 ctladm: Use nitems() in a few more places
Sponsored by:	Chelsio Communications

Differential Revision:	https://reviews.freebsd.org/D45017

(cherry picked from commit afd0c206a6ce9a182c1a26a4d8dbb66a8335f519)
2024-08-27 12:35:34 -04:00
Elyes Haouas
9f01ac2f7d ctladm: Use nitems(foo) instead of sizeof(foo)/sizeof(foo[0])
Pull Request: https://github.com/freebsd/freebsd-src/pull/888
Signed-off-by: Elyes Haouas <ehaouas@noos.fr>
(cherry picked from commit 2f8ea2f605acbeadb3c2fe9d336fcf558f2d4fa6)
2024-08-27 12:35:34 -04:00
Elyes Haouas
b2a3826e9d ctld: Use nitems(foo) instead of sizeof(foo)/sizeof(foo[0])
Pull Request: https://github.com/freebsd/freebsd-src/pull/888
Signed-off-by: Elyes Haouas <ehaouas@noos.fr>
(cherry picked from commit 8f65dcd6276bf139a2fe87c1bbeffcc1fed015e4)
2024-08-27 12:35:34 -04:00
Warner Losh
86a8ea7444 nvmecontrol: Allow optional /dev/ for device names
nvmecontrol operates on devices. Allow a user to specify the /dev/ if
they want. Any device that starts with / will be treated as if it was a
full path for maximum flexbility.

Sponsored by:		Netflix

(cherry picked from commit b12cae88cfb6286bc85a47b36ddd84f52b5c38ca)
2024-08-27 12:35:34 -04:00
Warner Losh
1d56b7ed63 nvmecontrol: Flesh out nvmecontrol format information
The format command takes a number of different parameters. Include a
brief summary of what the values mean, though since the driver's support
for metadata is at best weak, 0's are almost always used for values
other than -f format. Add an example that ties it all together.

Sponsored by:		Netflix
Reviewed by:		pauamma@gundo.com, chuck
Differential Revision:	https://reviews.freebsd.org/D44958

(cherry picked from commit ce3b53ffcc3ecc00fa6283542c60ff1fe697d853)
2024-08-27 12:35:34 -04:00
Gordon Bergling
af6673e6a5 nvmecontrol(8): Remove a double word in a source code comment
- s/the the/the/

MFC after:	3 days

(cherry picked from commit 6573ce292fc5ddc6c846860b3fa98473e3f5d1c6)
2024-08-27 12:35:34 -04:00
Elyes Haouas
169c76b9b6 camcontrol: Use nitems(foo) instead of sizeof(foo)/sizeof(foo[0])
Pull Request: https://github.com/freebsd/freebsd-src/pull/888
Signed-off-by: Elyes Haouas <ehaouas@noos.fr>
(cherry picked from commit 7028e630d6110789502cfc0f17b36b6f513ec297)
2024-08-27 12:35:34 -04:00
Yi-Chen Li
152a9cfe6d camcontrol(8): Fix grammar: a ATA -> an ATA
Event:		Advanced UNIX Programming Course (Fall'23) at NTHU.
Pull Request:	https://github.com/freebsd/freebsd-src/pull/1030

(cherry picked from commit 9977fb8042a4b2f2b3386684e137dfb42bf1707f)
2024-08-27 12:35:34 -04:00
Che-Yu Chang
c4fa138c2a camcontrol(8): Fix typos
On line 748, "bigger than" is mistyped as "bigger then", and on line
765, "more than" is mistyped as "more then".

Event: Advanced UNIX Programming Course (Fall’23) at NTHU.
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/949

(cherry picked from commit f8f3b16b6cb671649345352c16894f59679c096f)
2024-08-27 12:35:34 -04:00
Warner Losh
3cff088ebd src.conf.5: Regen after ddcd3b606c9d
Sponsored by:		Netflix

(cherry picked from commit 9ed58aa60fd9cfcc7b6d9f4efa3a0631da393fc9)
2024-08-27 12:33:16 -04:00
Warner Losh
38b00f73b8 options: Make it clearer some x86 / BIOS only things
Suggested by: jrtc27
Sponsored by: Netflix

(cherry picked from commit bf4f27e85aa62e459fb4cde9ebd51e32bdac7910)
2024-08-27 12:32:54 -04:00
John Baldwin
c7379937a2 src.conf.5: Regen after removing MK_NVME
(cherry picked from commit cbbc5770a30b6769d9d9a3a4504b81a5400a9110)
2024-08-27 11:54:55 -04:00
John Baldwin
7b182a286d Remove the MK_NVME build option
The drivers and utilities are now built and installed unconditionally.

Reviewed by:	imp, emaste
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D44843

(cherry picked from commit ee3187f6fa7986c6bfaa97528e050b796eaca343)
2024-08-27 11:54:45 -04:00
John Baldwin
a3a8eabcdc nvmecontrol: Always build instead of being conditional on WITH_NVME
This now builds fine on all platforms so always include it similar
to other tools such as camcontrol.

Reviewed by:	imp, emaste
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D44842

(cherry picked from commit 2d51a9898e26c87586ba50e71b6b3fdf1591713d)
2024-08-27 11:54:45 -04:00
John Baldwin
8f586587da camcontrol: Enable WITH_NVME unconditionally
MK_NVME is no longer marked broken for any platforms, so just include
support for it always as we do for ATA and SCSI.

Reviewed by:	emaste
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D44841

(cherry picked from commit 2b676a66c00af03e4b64d072658d2478dbdf0a97)
2024-08-27 11:54:45 -04:00
Warner Losh
e13b9fb02f camcontrol: One file per line in Makefile
We have enough files now that moving to one file per line makes sense.

Sponsored by:		Netflix

(cherry picked from commit 69ae43a1e6a53a1b8898a31c6b7140bf52b2c3ad)
2024-08-27 11:54:45 -04:00
Brooks Davis
40f573de8a src.conf.5: rebuild after WITH_NVME changes
WITH_NVME is no longer marked broken on armv7, riscv64, or powerpc.

Fixes:		2fda3ab0ac19 WITH_NVME: Remove from broken.
Differential Revision:	https://reviews.freebsd.org/D44850

(cherry picked from commit e5700dab1e7ad84b9a97025d263f0acd3599a1c2)
2024-08-27 11:54:45 -04:00
Kristof Provost
485bd16308 pf: cope with SCTP port re-use
Some SCTP implementations will abort connections and then later re-use the same
port numbers (i.e. both src and dst) for a new connection, before pf has fully
purged the old connection.

Apply the same hack we already have for similarly misbehaving TCP
implementations and forcibly remove the old state so we can create a new one.

MFC after:	2 weeks
Sponsored by:	Rubicon Communications, LLC ("Netgate")

(cherry picked from commit 82e021443a76b1f210cfb929a495185179606868)
2024-08-27 10:09:10 +02:00
Cy Schubert
818e3dc03d tools: Remove stray "then"
Fixes:		26a09db3add3
(cherry picked from commit f7f570eb97c70bc7f545d79a96c3192181bb8dd1)
2024-08-26 19:39:32 -04:00
Brooks Davis
8d2b36ef6c Fix incremental build with WITH_NVME newly enabled
rescue.mk doesn't get updated when options change so nvme_util.o is now
missing on architectures were NVME was previously marked BROKEN.

Reviewed by:	imp
Fixes:		2fda3ab0ac19 WITH_NVME: Remove from broken.
Differential Revision:	https://reviews.freebsd.org/D44826

(cherry picked from commit 26a09db3add30238b99e3214c56a3aee63fd71d1)
2024-08-26 19:39:15 -04:00
John Baldwin
ec8c44812a ObsoleteFiles.inc: Don't remove recently added mixer(8) tests
An earlier set of mixer(8) tests were removed leading to this entry,
but now the entry is removing the new tests.

Fixes:		94a86f3f6920 mixer(8): Add tests
(cherry picked from commit 09ed116dc5b84e6b3478b42e5b1076604e92f676)
2024-08-26 15:03:57 -04:00
Warner Losh
aba2d7f89d WITH_NVME: Remove from broken.
NVME works everywhere, so we can eliminate this. We may remove the
option altogether.

Sponsored by:		Netflix
Discussed with:		ken, jhb

(cherry picked from commit 2fda3ab0ac1903a977ef5d39d4dfb2ffe86ff1b7)
2024-08-26 14:31:03 -04:00
Warner Losh
37eb64d7d2 nvmecontrol: One file per line
Move to a one file per line setup, and sort the files alphabetically.

Sponsored by:		Netflix
Reviewed by:		chuck, jhb
Differential Revision:	https://reviews.freebsd.org/D44684

(cherry picked from commit 49ea0889f2cb5e786e166fa9536c84f4a9994a6b)
2024-08-26 14:31:03 -04:00
Warner Losh
efb91b313c nvmecontrol: Add nvme 2.0 fields to read_logpage
Add the lpo, ot, csi and uuid_index fields to read_logpage. The logpage
command has not been updated to allow these to be specified.

Sponsored by:		Netflix
Differential Revision:	https://reviews.freebsd.org/D44683

(cherry picked from commit 98ab7d0a30f8d0fc9c51e1e97ac29f87750b526c)
2024-08-26 14:31:03 -04:00
Warner Losh
aaac429c12 nvmecontrol: Preliminary namespace documentation
Provide preliminary namespace subcommand documentation, along with some
basic definitions from the NVM standards relating to namespaces.

Sponsored by:		Netflix
Reviewed by:		jhb
Differential Revision:	https://reviews.freebsd.org/D44682

(cherry picked from commit 383a44fc0bcb36bf67127856f0c5fabfea522bab)
2024-08-26 14:31:03 -04:00
Warner Losh
37109ba0ec nvmecontrol: add newlines where needed for ns command printfs
Sponsored by:		Netflix
Reviewed by:		chuck, jhb
Differential Revision:	https://reviews.freebsd.org/D44681

(cherry picked from commit e39873820da7ddfddb59823efc3421125b92c17a)
2024-08-26 14:31:03 -04:00
Warner Losh
1dac152478 nvme: Eliminate intel_log_temp_stats_swapbytes
We can't post a AER for this page, so there's no need to be able to swap
it to host byte order. It's not one of the standard defined pages that
can post via AER, and the vendor's public docs for this temperature page
don't suggest it's possible to get over or under event changes. Since
nvmecontrol no longer needsd the swap routine, remove it since it's
now unused.

Sponsored by:		Netflix
Reviewed by:		chuck
Differential Revision:	https://reviews.freebsd.org/D44659

(cherry picked from commit 97b77de2d951b4946fb3219a99c98f2dd4c0120f)
2024-08-26 14:31:03 -04:00
Warner Losh
4e7cc8f545 nvmecontrol: Move intel temperature page printing to little endian orderinng
Sponsored by:		Netflix
Reviewed by:		chuck
Differential Revision:	https://reviews.freebsd.org/D44658

(cherry picked from commit f0f7e9616da052e3d77b6e41301ccd655ae434fa)
2024-08-26 14:31:03 -04:00
Warner Losh
1bc8c6d40d nvmecontrol: Move sanitize status page printing to little endian orderinng
Sponsored by:		Netflix
Reviewed by:		chuck
Differential Revision:	https://reviews.freebsd.org/D44657

(cherry picked from commit 55a1679ece1f56beda5f68e929a6b2fc553fb501)
2024-08-26 14:31:03 -04:00
Warner Losh
36269290fc nvmecontrol: Move reservation notifcation page printing to little endian orderinng
Sponsored by:		Netflix
Reviewed by:		chuck
Differential Revision:	https://reviews.freebsd.org/D44656

(cherry picked from commit 3d28a9c608a382af669e22e9e8eda7fd0bc02cad)
2024-08-26 14:31:03 -04:00
Warner Losh
71484bbbff nvmecontrol: Move command effeccts page printing to little endian orderinng
Sponsored by:		Netflix
Reviewed by:		chuck
Differential Revision:	https://reviews.freebsd.org/D44655

(cherry picked from commit b850caf7b7099636fd4323cb47a82f5201309fed)
2024-08-26 14:31:03 -04:00
Warner Losh
067abd7d0b nvmecontrol: Move self test status page printing to little endian orderinng
Also, add printing vnedor_specific field, which doesn't have a valid
bit, so is always valid.

Sponsored by:		Netflix
Reviewed by:		chuck
Differential Revision:	https://reviews.freebsd.org/D44654

(cherry picked from commit 98f841efd8ce387d9cd060174b9dcc9ff9850648)
2024-08-26 14:31:02 -04:00