Commit Graph

273759 Commits

Author SHA1 Message Date
Mateusz Piotrowski
1969cc7bdc ifconfig.8: Remove remaining Xerox Network Systems(tm) bits
Support for Xeros Network Systems seems to be long gone. There is no
reason to keep this in the manual page.

MFC after:	2 weeks
2022-03-31 12:00:42 +02:00
Mateusz Piotrowski
19ac0bc5c1 ifconfig.8: Simplify examples by using canonical parameters
Also, use Bd instead of Dl for multi line examples.

MFC after:	2 weeks
2022-03-31 11:54:06 +02:00
Mateusz Piotrowski
2cd28d6f9b ifconfig.8: Mark address_family as optional in synopsis
Commands like "ifconfig wlan0 up" are valid. There is no need to always
specify the address family.

MFC after:	2 weeks
2022-03-31 11:43:18 +02:00
Mateusz Piotrowski
3049aac91b ifconfig.8: Improve description of the address argument
- Split paragraphs for clarity.
- Add an example of setting a random MAC address.

MFC after:	2 weeks
2022-03-31 11:43:18 +02:00
Mateusz Piotrowski
ad8cac1229 ifconfig.8: Improve readability of address_family documentation
Also, move the description of the special case of "ifconfig -l ether" to
the description of the -l flag.

MFC after:	2 weeks
2022-03-31 11:43:17 +02:00
Doug Moore
342056fa1c vm_phys: alloc pages without duplicating searches.
In the search for contiguous pages, as each page segment is examined,
check to see if the free list set for the next page segment differs
from the set for the current segment, and avoid a pointless search if
they do not differ.

Discussed with:	alc
Reviewed by:	markj
Tested by:	pho
Differential Revision:	https://reviews.freebsd.org/D33947
2022-03-31 01:40:46 -05:00
Greg Lehey
4044083079 chroot.2: Correct grammar errors.
No functional change.

MFC after:	1 week
2022-03-31 13:05:49 +11:00
Ed Maste
27ac4281fd mpr: add \n in diagnostic printf
Diff reduction between mpr and mps.

Fixes:		e2997a03b7 ("Diagnostic buffer fixes for the mps(4)...")
MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
2022-03-30 20:14:07 -04:00
Mark Johnston
d53927b0ba uma: Don't allow a limit to be set in a warm zone
The limit accounting in UMA does not tolerate this.

MFC after:	2 weeks
Sponsored by:	The FreeBSD Foundation
2022-03-30 15:42:18 -04:00
Mark Johnston
54361f9020 uma: Use the correct type for a return value
zone_alloc_bucket() returns a pointer, not a bool.

MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
2022-03-30 15:42:05 -04:00
Mark Johnston
7d1ab86691 pf: Initialize the table entry zone limit at initialization time
The limit may later be updated by the "set limit" directive in pf.conf.
UMA does not permit a limit to be set on a zone after any items have
been allocated from a zone.

Other UMA zones used by pf do not appear to be susceptible to this
problem: they either set a limit at zone creation time or never set one
at all.

PR:		260406
Reviewed by:	kp
MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D34713
2022-03-30 15:41:44 -04:00
Ed Maste
8299f9a5c1 compat32: add size CTASSERTs for non-amd64 cases
Reviewed by:	markj
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D34712
2022-03-30 13:25:25 -04:00
Ed Maste
27c2f016b8 fstyp: Correct comment: Raspberry Pi Pico, not Nano
Fixes:		868c1b8431 ("fstyp: detect Raspberry Pi Pico boot...")
2022-03-30 13:04:11 -04:00
Jose Luis Duran
2d5df84081 dtc.1: Fix the display of directives ending with semicolons
While here, fix a typo and bump the date.

Obtained from:	https://github.com/davidchisnall/dtc/pull/71
Fixes:	6979e8cb6e
2022-03-30 17:45:50 +02:00
Jose Luis Duran
607eed2f84 ifconfig.8: Fix quoting
Obtained from:	67d77afb0d (r69907135)
Fixes:		67d77afb0d ifconfig.8: Do not use ``'' for quoting
MFC after:	2 weeks
2022-03-30 17:43:13 +02:00
Ed Maste
e5821a2156 syscalls.master: remove obsolete comment about compatibility tables
Compatibility ABIs no longer use a separate syscalls.master.

Fixes:		be67ea40c5 ("freebsd32: generate from ...")
Sponsored by:	The FreeBSD Foundation
2022-03-30 11:07:00 -04:00
Mateusz Piotrowski
388c12e3f4 ifconfig.8: Clean up markup of "state" parameter
MFC after:	2 weeks
2022-03-30 14:58:39 +02:00
Mateusz Piotrowski
39da6db9bc ifconfig.8: Make the -f flag description compact
- Remove extraneous examples
- Apply "-compact" to the list macros so that it is possible to fit the
  definitions of the types and formats in one terminal screen.

MFC after:	2 weeks
2022-03-30 14:58:39 +02:00
Mateusz Piotrowski
67d77afb0d ifconfig.8: Do not use ``'' for quoting
MFC after:	2 weeks
2022-03-30 14:58:38 +02:00
Mateusz Piotrowski
ce03846373 ifconfig.8: Clean up the channel parameter description
MFC after:	2 weeks
2022-03-30 14:58:38 +02:00
Mateusz Piotrowski
0e2045b294 ifconfig.8: Add section headers to the parameters section
MFC after:	2 weeks
2022-03-30 14:58:37 +02:00
Mateusz Piotrowski
186a372f24 ifconfig.8: Clean up -n documentation
MFC after:	2 weeks
2022-03-30 14:58:37 +02:00
Mateusz Piotrowski
9076f99b9b ifconfig.8: Clean up -k documentation
MFC after:	2 weeks
2022-03-30 14:58:36 +02:00
Mateusz Piotrowski
59cdaadcf6 ifconfig.8: Clean up -C and -v documentation
MFC after:	2 weeks
2022-03-30 14:58:36 +02:00
Mateusz Piotrowski
fe1e3b55f2 ifconfig.8: Clean up -l documentation
MFC after: 2 weeks
2022-03-30 14:58:35 +02:00
Mateusz Piotrowski
787599088b ifconfig.8: Clean up -G & -g documentation
MFC after:	2 weeks
2022-03-30 14:58:35 +02:00
Mateusz Piotrowski
0625c31391 ifconfig.8: Clean up documentation of -a, -d, and -u
MFC after:	2 weeks
2022-03-30 14:58:34 +02:00
Mateusz Piotrowski
19c1b75f71 ifconfig.8: Clean up -L documentation
MFC after:	2 weeks
2022-03-30 14:58:34 +02:00
Mateusz Piotrowski
b56e4224e9 ifconfig.8: Clean up -m documentation
MFC after: 2 weeks
2022-03-30 14:58:33 +02:00
Mateusz Piotrowski
f4f02fa1e3 ifconfig.8: Clean up formatting of -f documentation
This change is about moving the -f documentation into the right place in
the manual. Also, document the IFCONFIG_FORMAT variable in the
ENVIRONMENT section.

MFC after:	2 weeks
2022-03-30 14:58:33 +02:00
Mateusz Piotrowski
f15eed7c2a ifconfig.8: Move options sections to the top
In order to clean up the layout of the manual page, let's keep
parameters in the end of the DESCRIPTION section. This patch does not
change any content, it's meant to only move the content around before
refactoring.

MFC after:	2 weeks
2022-03-30 14:58:32 +02:00
Mateusz Piotrowski
12a774649a ifconfig.8: Deduplicate groupname documentation
-G and -g flags are already described somewhere else in the manual.

MFC after:	2 weeks
2022-03-30 14:58:32 +02:00
Kristof Provost
d27c9f5bc3 pf: fixup match rules
Ensure that we can set and print match rules in ethernet rules.

Sponsored by:	Rubicon Communications, LLC ("Netgate")
2022-03-30 10:28:19 +02:00
Kristof Provost
81cac0d2f6 pf: add missing input/error validation for DIOCGETETHRULE
Sponsored by:	Rubicon Communications, LLC ("Netgate")
2022-03-30 10:28:19 +02:00
Kristof Provost
514039bb90 libpfct: Return errno from pfctl_add_eth_rule()
If the pfctl_add_eth_rule() ioctl fails return the errno, not the error
returned by ioctl(). That will give us slightly more insight into what
went wrong, because ioctl() would always return -1.

Sponsored by:	Rubicon Communications, LLC ("Netgate")
2022-03-30 10:28:19 +02:00
Kristof Provost
9bb06778f8 pf: support listing ethernet anchors
Sponsored by:	Rubicon Communications, LLC ("Netgate")
2022-03-30 10:28:19 +02:00
Wei Hu
5473dee730 Hyper-V: vPCI: Write back original BAR values after prepopulating bars
In vmbus_pcib_prepopulate_bars(), after writing all 1's to the
avialable device bars, those without being configured by device driver
are also set to its initialized values. However, this could cause
weird problem which results to device failure. The issue has been
reported to happen on LSI 9211-8i HBA card for DDA access on Hyper-V.
Writing back the orignal BAR values seem to work around this problem.

Reported by:	Alexander Motin <mavbsd@gmail.com>
Tested by:	Mathias Kraut <krautmaster@gmail.com>
Fixes:		75412a521f Hyper-V: vPCI: Prepopulate device bars
MFC after:	1 month
2022-03-30 06:56:09 +00:00
Greg Lehey
8deef88628 Correct source markup. No change to output.
Reported by:	0mp@
2022-03-30 14:55:28 +11:00
Greg Lehey
8e4b069f45 Remove reference to kernel clock time zone.
Add references.

Reported by:	philip@
2022-03-30 14:42:14 +11:00
Michael Tuexen
218e463b85 sctp: ensure that ASCONF chunks are not too large
MFC after:	3 days
2022-03-30 01:22:20 +02:00
Ed Maste
868c1b8431 fstyp: detect Raspberry Pi Pico boot filesystem as FAT
fstyp looks for a 0x55 0xAA signature at offset 510, but this is not
required by specifications and is not proivded by the Raspberry Pi Nano
bootloader.

We should really remove the signature check and implement a more
comprehensive BPB validation instead, but it will require more
investigation and testing.  For now just add a special case for the
Raspberry Pi Nano bootloader, to avoid introducing regressions or new
false positives.

PR:		262896
Reviewed by:	delphij
MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D34699
2022-03-29 17:33:15 -04:00
Michael Tuexen
e7e65008ff sctp: fix typos
Thanks to David Sanders for fixing the typos in the userland stack.

MFC after:	3 days
2022-03-29 21:09:51 +02:00
Ed Maste
f90cd1ae30 Clear non-x86 compat stat syscall kernel stack memory disclosure
32-bit architectures other than i386 have 64-bit time_t which results
in a struct timespec with 12 bytes for tv_sec and tv_nsec, and 4 bytes
of padding.  Zero the padding holes in struct stat32 and struct
freebsd11_stat32.

i386 has 32-bit time_t; struct timespec is 8 bytes and has no padding.

Found by inspection, prompted by a report by Reno Robert of Trend Micro
Zero Day Initiative.  The originally reported issue (ZDI-CAN-14538) is
already fixed in all supported FreeBSD versions (it was addressed
incidentally as part of the 64-bit inode project).

Reviewed by:	markj
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D34709
2022-03-29 16:10:04 -04:00
Mateusz Guzik
e123e2294c pf: guard against DIOCADDRULE without DIOCXBEGIN
Possibility to do it was always a bug, but it runs into crashes
since recent introduction of a per-ruleset RB tree.

Reviewed by:	kp
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Reported by:	syzbot+665b700afc6f69f1766a@syzkaller.appspotmail.com
2022-03-29 19:00:55 +00:00
Gordon Bergling
277d3e855d Revert "drm2: Fix a typo in a source code comment"
The comment about 'mmaping' was actually correct since
the comment was referencing to mmap(2).

Reported by:	alc

This reverts commit 22ba115b49.
2022-03-29 20:47:52 +02:00
Jens Schweikhardt
e50daba0e4 Remove extraneous semicolons trailing break and continue statements. 2022-03-29 19:48:11 +02:00
Mateusz Piotrowski
b710d4c85a ifconfig.8: Document that -k can be used with -a
MFC after:	2 weeks
2022-03-29 19:37:01 +02:00
Mateusz Piotrowski
52ec8807d8 ifconfig.8: Improve -f synopsis
- There is no need to mention in the synopsis that -f can be a list of
  comma-separated type:format pairs. Let's keep it simple instead.
- Mention that -f can be supplied multiple times.
- Add -f to other entries in the synopsis where it can be used.

MFC after:	2 weeks
2022-03-29 19:32:32 +02:00
Mateusz Piotrowski
efb4f7fd09 ifconfig.8: Document the synopsis of -C
As documented, the -C flag can only be used on its own. Any other
command modifiers and flags are ignored when -C is used. Reflect that in
synopsis.

MFC after:	2 weeks
2022-03-29 19:16:07 +02:00
Mateusz Piotrowski
a9475cb389 ifconfig.8: Show that -g groupname can be used on its own
MFC after:	2 weeks
2022-03-29 19:14:20 +02:00