openbsd
2 years agoFor clarity and consistency, refer to ".Bx 4.0" rather than ".Bx 4".
schwarze [Thu, 4 Aug 2022 11:31:18 +0000 (11:31 +0000)]
For clarity and consistency, refer to ".Bx 4.0" rather than ".Bx 4".
Also, mention /usr/ucb/man because /usr/bin/man did not provide -f in 4.0BSD.

2 years agoUse ".Bx 4.0" rather than ".Bx 4" for clarity and consistency.
schwarze [Thu, 4 Aug 2022 11:14:46 +0000 (11:14 +0000)]
Use ".Bx 4.0" rather than ".Bx 4" for clarity and consistency.
Both are correct, but "4.0" avoids the misunderstanding that we were
talking about any unspecified 4.xBSD release, and it is much more widely
used in our manuals.
Discussed with jsg@ in the context of other manual pages.

2 years agoAdd some glue to fetch the tlsext functions from the tls_extensions[]
tb [Thu, 4 Aug 2022 09:28:31 +0000 (09:28 +0000)]
Add some glue to fetch the tlsext functions from the tls_extensions[]
table rather than calling the functions directly.

2 years agoMake tlsext_*_{build,needs,parse}() functions static
tb [Thu, 4 Aug 2022 09:27:36 +0000 (09:27 +0000)]
Make tlsext_*_{build,needs,parse}() functions static

None of these functions are used outside of ssl_tlsext.c. The only reason
they are prototyped in the header is for the use of tlsexttest.c. Rather
than having a big pile of useless copy-paste in the header, we can adapt
the test to avoid using these functions directly.

ok jsing

2 years agoDefault to softraid on boot-device iff found
kn [Thu, 4 Aug 2022 09:16:53 +0000 (09:16 +0000)]
Default to softraid on boot-device iff found

root on softraid on sparc64 currently requires explicitly passing the volume
name as part of the boot arguments, e.g.
boot-file=sr0
boot-file=sr0a:/bsd
or
{ok} boot my-devalias sr0:

(ofwboot always probes for softraid devices, assembles them but continues
 to ignore such volumes unless specified.)

This is inconsistent with softraid support on other platforms and has
further drawbacks when it comes to sysupgrade logic.

Unless an explicit root disk was given, make ofwboot default to the softraid
volume on the boot device to make root on softraid work out of the box
without having to set variables or pass arguments in OpenBoot.

Eventually, ofwboot's disk discovery and softraid assembly machinery will be
fixed and boot-file won't be misused for softraid purposes anymore.

Remove the quirky softraid paragraph from boot_sparc64(8) now that it
is purely optional, expecting users from now on to either leave boot-file
empty or pass a kernel filename alone.

Tested on T4-2 guest domains with and without root on softraid.

Feedback claudio kettenis stsp
OK kettenis (previous diff)
OK stsp

2 years agoMop up key_len assignments.
jsing [Thu, 4 Aug 2022 08:06:48 +0000 (08:06 +0000)]
Mop up key_len assignments.

Remove unnecessary conditions for XTS mode, since we know which are XTS.
Also use bytes rather than bits / 8.

ok tb@

2 years agoMop up EVP_CIPH_FLAG_FIPS usage.
jsing [Thu, 4 Aug 2022 08:02:31 +0000 (08:02 +0000)]
Mop up EVP_CIPH_FLAG_FIPS usage.

LibreSSL does not do FIPS and nothing else sets or checks these.

ok tb@

2 years agoRemove various aesni_* defines to aes_* functions.
jsing [Thu, 4 Aug 2022 08:00:11 +0000 (08:00 +0000)]
Remove various aesni_* defines to aes_* functions.

A number of the AES-NI functions are #defines to an aes_* function - remove
these and just use the AES variant directly.

ok tb@

2 years agoadd openbsd-73-syspatch.pub to the sets
robert [Thu, 4 Aug 2022 07:16:49 +0000 (07:16 +0000)]
add openbsd-73-syspatch.pub to the sets

2 years agoadd 7.3 syspatch pubkey
robert [Thu, 4 Aug 2022 07:15:33 +0000 (07:15 +0000)]
add 7.3 syspatch pubkey

2 years agochange some 4.4BSD references to earlier releases
jsg [Thu, 4 Aug 2022 06:20:24 +0000 (06:20 +0000)]
change some 4.4BSD references to earlier releases
ok schwarze@

2 years agocu first appeared outside of Bell Labs in PWB/UNIX 1.0 before v7
jsg [Thu, 4 Aug 2022 04:01:48 +0000 (04:01 +0000)]
cu first appeared outside of Bell Labs in PWB/UNIX 1.0 before v7
mention tip in 4.1c while here

with and ok schwarze@ ok nicm@

2 years agoAdd workarounds for some symbols that are hidden under !LIBRESSL_INTERNAL
tb [Wed, 3 Aug 2022 20:17:38 +0000 (20:17 +0000)]
Add workarounds for some symbols that are hidden under !LIBRESSL_INTERNAL
until the next bump exposes new symbols that we can use.

2 years agoPrepare to provide PKCS12 accessors
tb [Wed, 3 Aug 2022 20:16:06 +0000 (20:16 +0000)]
Prepare to provide PKCS12 accessors

In order to be able to make pkcs12/ opaque, we need an entire family of
accessors. These are in a particularly nasty tangle since this was done
in about a dozen steps while sprinkling const, renaming functions, etc.
The public API also adds backward compat macros for functions that were
in the tree for half a day and then renamed. Of course some of them got
picked up by some ports.

Some of the gruesome hacks in here will go away with the next bump, but
that doesn't mean that the pkcs12 directory will be prettier afterward.

ok jsing

2 years agoSince ts(1) is line-based, always using line buffering
job [Wed, 3 Aug 2022 16:54:30 +0000 (16:54 +0000)]
Since ts(1) is line-based, always using line buffering

makes sense millert@
yep deraadt@

2 years agoAdd aplaudio(4) and aplmca(4). The aplmca(4) driver controls the hardware
kettenis [Wed, 3 Aug 2022 13:42:16 +0000 (13:42 +0000)]
Add aplaudio(4) and aplmca(4).  The aplmca(4) driver controls the hardware
block that takes data from apldma(4), serializes it and sends it out on
the i2s ports.  The aplaudio(4) driver ties together aplmca(4) and various
codecs to present an audio(4) interface to the system.

This is still WIP, but good enough to play back audio on the speaker in the
M1 mini.

ok patrick@

2 years agoClear active state when we attach.
kettenis [Wed, 3 Aug 2022 13:36:51 +0000 (13:36 +0000)]
Clear active state when we attach.

ok patrick@

2 years agoDo not crash when searching for .* with extremely long lines. Reported
nicm [Wed, 3 Aug 2022 13:27:48 +0000 (13:27 +0000)]
Do not crash when searching for .* with extremely long lines. Reported
by Torbjorn Lonnemark, GitHub issue 3272.

2 years agoAdd comment that NEXTHOP_FLAPPED is only set on oldstate of a nexthop.
claudio [Wed, 3 Aug 2022 08:56:23 +0000 (08:56 +0000)]
Add comment that NEXTHOP_FLAPPED is only set on oldstate of a nexthop.

2 years agotail(1) first appeared outside of Bell Labs in PWB/UNIX 1.0
jsg [Wed, 3 Aug 2022 08:28:19 +0000 (08:28 +0000)]
tail(1) first appeared outside of Bell Labs in PWB/UNIX 1.0

with and ok schwarze@

2 years agosed(1) first appeared outside of Bell Labs in PWB/UNIX 1.0
jsg [Wed, 3 Aug 2022 08:16:50 +0000 (08:16 +0000)]
sed(1) first appeared outside of Bell Labs in PWB/UNIX 1.0

it did not start in the PWB group

"The talk said that tools like grep and sed came from PWB,
but that's not true. They were original"

"The flow from PWB back to the main research line was a trickle at best.
We had bad NIH in 1127."

Rob Pike
https://minnie.tuhs.org/pipermail/tuhs/2020-February/020329.html

The 4.4BSD version was written by Diomidis Spinellis
credited in csrg/admin/admin/contrib

"In 1992, as a bored PhD student, I reimplemented sed(1) and contributed
it the unencumbered BSD version that was then being put together"
https://www.spinellis.gr/blog/FreeBSD.html

with and ok schwarze@

2 years agoFix a modify after free error in kroute_remove()
claudio [Wed, 3 Aug 2022 08:16:05 +0000 (08:16 +0000)]
Fix a modify after free error in kroute_remove()

knexthop_validate() will modify the kroute the nexthop points to.
Because of this knexthop_validate() needs to be called before the
to be removed kroute is freed. Move the code into kroute_remove[46]
so the order is correct.
Problem found and fix tested by sthen@.
OK sthen@ tb@

2 years agoBug was reported by Chriss Cappucio. It has turned out my earlier change
sashan [Wed, 3 Aug 2022 08:16:04 +0000 (08:16 +0000)]
Bug was reported by Chriss Cappucio. It has turned out my earlier change
to pf_lb.c was not complete. We must add a test to determine number of
addresses defined by pool, so we don't treat pool definition
172.16.0.0/16 as a single IP address in pool. If pool is defined as
172.16.0.0/16, then we don't want to fall back to PF_POOL_NONE. Missing
this measure in pf_map_addr() may cause pf_get_sport() to enter infinite
loop when source ports translation become depleted for the first address
found in pool (like 172.16.0.1), because the bug prevents pf_map_addr()
to move to next address in pool (like 172.16.0.2).

while investigating issue I've also noticed an oddity for small random
pools such as 192.168.1.32/28. One would expect the addresses for nat
will be randomly picked from range .32 - .47 in this case. however the
random selection yield significantly more (like 20%) addresses ending by .32
In order to fix it we make random pool to use arc4random_uniform(~mask + 1)
instead of current arc4random().

feedback by claudio@
tested by hrvoje@

2 years agoFix possible NULL dereference in knexthop_validate().
claudio [Wed, 3 Aug 2022 08:11:18 +0000 (08:11 +0000)]
Fix possible NULL dereference in knexthop_validate().

kroute_match() may return NULL so setting kn->ifindex should only
be done if the kroute is valid. Also set the ifindex to 0 in
kroute_detach_nexthop().
Based on a bigger diff which is OK tb@ and sthen@

2 years agomake(1) first appeared outside of Bell Labs in PWB/UNIX 1.0
jsg [Wed, 3 Aug 2022 07:54:47 +0000 (07:54 +0000)]
make(1) first appeared outside of Bell Labs in PWB/UNIX 1.0

it did not start in the PWB group
"PWB did not create make; Stu Feldman did it in research." Doug McIlroy
https://minnie.tuhs.org/pipermail/tuhs/2015-November/007572.html

with and ok schwarze@

2 years agowe have spell(1) via 4.4BSD
jsg [Wed, 3 Aug 2022 07:43:45 +0000 (07:43 +0000)]
we have spell(1) via 4.4BSD

discussed with schwarze@

2 years agoderoff(1) first appeared outside of Bell Labs in PWB/UNIX 1.0
jsg [Wed, 3 Aug 2022 07:38:09 +0000 (07:38 +0000)]
deroff(1) first appeared outside of Bell Labs in PWB/UNIX 1.0

it did not start in the PWB group
"Lorinda also wrote deroff" Doug McIlroy
https://minnie.tuhs.org/pipermail/tuhs/2015-September/007510.html

our version came from 4.4BSD after the Caldera relicense

with and ok schwarze@

2 years agosome love for patch regress
op [Wed, 3 Aug 2022 07:35:04 +0000 (07:35 +0000)]
some love for patch regress

* t3 doesn't was fixed anymore
* add a comment describing t19
* add t20 (reversal application of a diff that creates a one-line file)

ok stsp@

2 years agofix locate_hunk in empty files
op [Wed, 3 Aug 2022 07:30:37 +0000 (07:30 +0000)]
fix locate_hunk in empty files

if `first_guess' is zero then main() assumes that locate_hunk has failed
and aborts the patch operation.  Instead, make sure to return 1 (the
line number) so that the patch operation can continue.

Issue originally found by Neels Hofmeyr in the regress suite of the diff
implementation for got, where the tests assume that applying a diff with
`patch' and then again with `patch -R' yields back the original file.

ok stsp@

2 years agofix dwim for reversed patches
op [Wed, 3 Aug 2022 07:25:44 +0000 (07:25 +0000)]
fix dwim for reversed patches

patch(1) fails to recognize the reversal application of a patch that
cerates a file.  since an empty context always matches, the idea is to
run the dwim ("do what I mean") code also when locate_hunk succeeds but
the patch would create a file and the match is on the first line.
fixes the (disabled) test t3.

ok stsp@

2 years agorecognise IDT 92HD95/92HD95B now sold as TSI 92HD95B
jsg [Wed, 3 Aug 2022 05:54:50 +0000 (05:54 +0000)]
recognise IDT 92HD95/92HD95B now sold as TSI 92HD95B

https://frame.work/blog/solving-for-silicon-shortages

2 years agodrm/i915/adlp: Fix register corruption after DDI clock enabling
jsg [Wed, 3 Aug 2022 03:14:23 +0000 (03:14 +0000)]
drm/i915/adlp: Fix register corruption after DDI clock enabling

From Imre Deak
59207e63801fbcd39ca68df6e2ba5ae90f76c0c3 in mainline linux

2 years agodmesg(8): don't accept positional arguments
cheloha [Wed, 3 Aug 2022 00:23:14 +0000 (00:23 +0000)]
dmesg(8): don't accept positional arguments

dmesg(8) doesn't use any positional arguments.  If we see any, it's a
usage error.

ok florian@, "Sure" deraadt@ millert@

2 years agoCorrectly detect xmem operations faulting on missing pages on 88110.
miod [Tue, 2 Aug 2022 20:15:28 +0000 (20:15 +0000)]
Correctly detect xmem operations faulting on missing pages on 88110.
These must be handled as write faults rather than read faults, since xmem
performs both a read and a write, and unlike on 88100, we don't have an easy
bit to check.

This solves libcrypto spinning on its locks on 88110.

2 years agoAdd missing closing bracket in usage
tb [Tue, 2 Aug 2022 20:01:12 +0000 (20:01 +0000)]
Add missing closing bracket in usage

2 years agoAdd --contimeout functionality.
job [Tue, 2 Aug 2022 18:09:20 +0000 (18:09 +0000)]
Add --contimeout functionality.

Input from deraadt@

OK claudio@

2 years agoStrange argument padding is no longer neccessary, remove this BUGS section
deraadt [Tue, 2 Aug 2022 17:37:18 +0000 (17:37 +0000)]
Strange argument padding is no longer neccessary, remove this BUGS section
ok guenther

2 years ago1) The yp_bind/yp_unbind and internal _yp_dobind/_yp_unbind sequences shared
deraadt [Tue, 2 Aug 2022 17:00:15 +0000 (17:00 +0000)]
1) The yp_bind/yp_unbind and internal _yp_dobind/_yp_unbind sequences shared
dom_binding structs between threads, which is unsafe -- example, dom_vers
signalled retry events, and structs+socket would get deallocated in _yp_unbind.
Change all yp_first (and similar) functions to understand that _yp_dobind now
provides a private dom_binding and socket, which must be released using
_yp_unbind.  Use similar methods in the one-step yp_all function.
2) domainname caching in get* is not neccessary now that the domainname cannot
change relative to ypconnect(2)'s decisions.
Many fields in dom_binding struct become unused, so delete them.
ok jmatthew, also tested by miod

2 years ago1) The yp_bind/yp_unbind and internal _yp_dobind/_yp_unbind sequences shared
deraadt [Tue, 2 Aug 2022 16:59:29 +0000 (16:59 +0000)]
1) The yp_bind/yp_unbind and internal _yp_dobind/_yp_unbind sequences shared
dom_binding structs between threads, which is unsafe -- example, dom_vers
signalled retry events, and structs+socket would get deallocated in _yp_unbind.
Change all yp_first (and similar) functions to understand that _yp_dobind now
provides a private dom_binding and socket, which must be released using
_yp_unbind.  Use similar methods in the one-step yp_all function.
2) domainname caching in get* is not neccessary now that the domainname cannot
change relative to ypconnect(2)'s decisions.
Many fields in dom_binding struct become unused, so delete them.
ok jmatthew, also tested by miod

2 years agoThe Xr to ypbind 3 doesn't help improve anyone's understanding of how the
deraadt [Tue, 2 Aug 2022 16:47:16 +0000 (16:47 +0000)]
The Xr to ypbind 3 doesn't help improve anyone's understanding of how the
YP libc/protocol/ypserv|ypldap->ldapd situation works.  Delete it.

2 years agodelete incorrect comment: yp_unbind is not called by passwd
deraadt [Tue, 2 Aug 2022 16:45:00 +0000 (16:45 +0000)]
delete incorrect comment: yp_unbind is not called by passwd

2 years agoBring back the direct map optimization when PMAP_PREFER isn't defined.
mpi [Tue, 2 Aug 2022 14:04:06 +0000 (14:04 +0000)]
Bring back the direct map optimization when PMAP_PREFER isn't defined.

PMAP_PREFER is checked to prevent cache aliasing issues when the physical
page is mapped at different virtual addresses.

This speeds up file-based mmap faults.

ok kettenis@

2 years agoIf the body of a man(7) .MT or .UR block is empty, do not emit a warning.
schwarze [Tue, 2 Aug 2022 11:55:51 +0000 (11:55 +0000)]
If the body of a man(7) .MT or .UR block is empty, do not emit a warning.
Leaving the body empty is legitimate in this case if the author only
wants to display a mail address or URI without providing a link text.
Output modules already handle this correctly: terminal output shows
just the URI without an accompanying text, HTML output uses the URI
for *both* the href= attribute and as the content of the <a> element.

The documentation was also wrong and claimed that an .MT or .UR block
with an empty body would produce no output.  As explained above,
this isn't true.

Bogus warning reported by
Alejandro Colomar <alx dot manpages at gmail dot com>.

2 years agoAdd a third state "all" to allow-passthrough to work even in invisible
nicm [Tue, 2 Aug 2022 11:09:26 +0000 (11:09 +0000)]
Add a third state "all" to allow-passthrough to work even in invisible
panes, from Sergei Grechanik in GitHub issue 3274.

2 years agosome ports bootstraps, and go internals, need a bit more time to adapt
deraadt [Tue, 2 Aug 2022 11:04:25 +0000 (11:04 +0000)]
some ports bootstraps, and go internals, need a bit more time to adapt
to the padded syscalls going away.

2 years agoReorganize the tests that require custom command line options
schwarze [Tue, 2 Aug 2022 10:59:51 +0000 (10:59 +0000)]
Reorganize the tests that require custom command line options
such that they don't abort the whole test suite if one of them fails.

2 years agoFix validation of missing percentage arguments.
nicm [Tue, 2 Aug 2022 09:23:34 +0000 (09:23 +0000)]
Fix validation of missing percentage arguments.

2 years agoshamelessly missed to unveil(_PATH_BSHELL, "x") which is required to run the
mestre [Tue, 2 Aug 2022 09:07:34 +0000 (09:07 +0000)]
shamelessly missed to unveil(_PATH_BSHELL, "x") which is required to run the
commands inside usbhidaction(1)'s `conf' file.

reported and fix tested by Hector Velasco < tech ! ogroth . com >

2 years ago-u is no longer equivalent to -TUTF-8 so don't say it is.
nicm [Tue, 2 Aug 2022 08:57:01 +0000 (08:57 +0000)]
-u is no longer equivalent to -TUTF-8 so don't say it is.

2 years agoExpand BLOCK_CIPHER_* macros.
jsing [Tue, 2 Aug 2022 07:51:37 +0000 (07:51 +0000)]
Expand BLOCK_CIPHER_* macros.

As a first step towards untangling and cleaning up the EVP AES code, expand
the BLOCK_CIPHER_* macros. In particular, rather than having two sets of
macros - one that is used if AESNI is being compiled in and one if it is
not, condition on #ifdef AESNI_CAPABLE in the expanded code.

ok tb@

2 years agomatch on Intel 600 Series LP
jsg [Tue, 2 Aug 2022 05:38:17 +0000 (05:38 +0000)]
match on Intel 600 Series LP

2 years agoregen
jsg [Tue, 2 Aug 2022 05:35:34 +0000 (05:35 +0000)]
regen

2 years agoadd more Intel Alder Lake / 600 Series LP ids
jsg [Tue, 2 Aug 2022 05:35:01 +0000 (05:35 +0000)]
add more Intel Alder Lake / 600 Series LP ids

from:
12th Generation Intel Core Processors
Datasheet, Volume 1 of 2, Doc. No.: 655258, Rev.: 008

Intel 600 Series Chipset Family On-Package Platform Controller Hub
Datasheet, Volume 1 of 2, Doc. No.: 691222, Rev.: 002

and SanDisk SN850 while here

2 years agoaccess(2) alarm(2) pause(2) were not ported from pwb to v7
jsg [Tue, 2 Aug 2022 01:23:23 +0000 (01:23 +0000)]
access(2) alarm(2) pause(2) were not ported from pwb to v7

Alan Glasser describes the incident that led to access(2) in
https://minnie.tuhs.org/pipermail/tuhs/2021-November/024657.html

access(2) alarm(2) pause(2) were also part of the "50 changes" tape

post v6 "50 bugs" / "diff tape" / "50 fixes" tape (Salus QCU, pp 138-139)
"fifty changes" tape
https://www.oreilly.com/openbook/opensources/book/kirkmck.html

"50 changes"
https://archive.org/details/unix_news_november-1976

tuhs/Applications/Spencer_Tapes/unsw3.tar.gz
usr/sys/v6unix/changenotes

45) The "access()" system call checks access permissions on the real
id's of the process regardless of the effective ones.  Doesn't return
stats, just does an internal "access()" to set u.u_error.

48) "alarm()" and "pause()" system calls are in to provide a user-mode
timeout capability.

with and ok schwarze@

2 years agoAllocate memory for collection translation tables for hardware that needs
kettenis [Mon, 1 Aug 2022 20:48:19 +0000 (20:48 +0000)]
Allocate memory for collection translation tables for hardware that needs
it.

ok patrick@

2 years agoFix bogus indent. NFC
miod [Mon, 1 Aug 2022 20:35:25 +0000 (20:35 +0000)]
Fix bogus indent. NFC

2 years agodrm/amd/display: Fix wrong format specifier in amdgpu_dm.c
jsg [Mon, 1 Aug 2022 16:18:53 +0000 (16:18 +0000)]
drm/amd/display: Fix wrong format specifier in amdgpu_dm.c

From Hayden Goodfellow
c6e4817ab622f526d6afe9e02c6d85b177b3e846 in linux 5.15.y/5.15.58
655c167edc8c260b6df08bdcfaca8afde0efbeb6 in mainline linux

2 years agodrm/amdgpu: Off by one in dm_dmub_outbox1_low_irq()
jsg [Mon, 1 Aug 2022 16:17:17 +0000 (16:17 +0000)]
drm/amdgpu: Off by one in dm_dmub_outbox1_low_irq()

From Dan Carpenter
ec9ec3bc08b18c5b1b2feafd306ea7c348013898 in linux 5.15.y/5.15.58
a35faec3db0e13aac8ea720bc1a3503081dd5a3d in mainline linux

2 years agodrm/amd/display: invalid parameter check in dmub_hpd_callback
jsg [Mon, 1 Aug 2022 16:15:38 +0000 (16:15 +0000)]
drm/amd/display: invalid parameter check in dmub_hpd_callback

From Jose Exposito
f85a6046f7718f11c6ad015a0ba25d897194b1ac in linux 5.15.y/5.15.58
978ffac878fd64039f95798b15b430032d2d89d5 in mainline linux

2 years agodrm/amd/display: Don't lock connection_mutex for DMUB HPD
jsg [Mon, 1 Aug 2022 16:13:29 +0000 (16:13 +0000)]
drm/amd/display: Don't lock connection_mutex for DMUB HPD

From Nicholas Kazlauskas
760fe32034931a8c97c773edef2f1b7c7346f43a in linux 5.15.y/5.15.58
d82b3266ef88dc10fe0e7031b2bd8ba7eedb7e59 in mainline linux

2 years agodrm/amd/display: Fix surface optimization regression on Carrizo
jsg [Mon, 1 Aug 2022 16:11:08 +0000 (16:11 +0000)]
drm/amd/display: Fix surface optimization regression on Carrizo

From Nicholas Kazlauskas
c2b484d784c8dfc3eb62fd4f9ff11515b6e78e19 in linux 5.15.y/5.15.58
62e5a7e2333a9f5395f6a9db766b7b06c949fe7a in mainline linux

2 years agodrm/amd/display: Optimize bandwidth on following fast update
jsg [Mon, 1 Aug 2022 16:08:58 +0000 (16:08 +0000)]
drm/amd/display: Optimize bandwidth on following fast update

From Nicholas Kazlauskas
9581511948582a0ed8da03fb91d2ab658087283d in linux 5.15.y/5.15.58
34316c1e561db0b24e341029f04a5a5bead9a7bc in mainline linux

2 years agodrm/amd/display: Reset DMCUB before HW init
jsg [Mon, 1 Aug 2022 16:06:06 +0000 (16:06 +0000)]
drm/amd/display: Reset DMCUB before HW init

From Nicholas Kazlauskas
b3f16976b9ed7afafa2caf12ef5539fafc34d48d in linux 5.15.y/5.15.58
791255ca9fbe38042cfd55df5deb116dc11fef18 in mainline linux

2 years agodrm/amd/display: Ignore First MST Sideband Message Return Error
jsg [Mon, 1 Aug 2022 16:04:24 +0000 (16:04 +0000)]
drm/amd/display: Ignore First MST Sideband Message Return Error

From Fangzhi Zuo
c7720f23bb93628f30f16d033eaefbe2540f1b5e in linux 5.15.y/5.15.58
acea108fa067d140bd155161a79b1fcd967f4137 in mainline linux

2 years agodrm/amdgpu/display: add quirk handling for stutter mode
jsg [Mon, 1 Aug 2022 16:01:50 +0000 (16:01 +0000)]
drm/amdgpu/display: add quirk handling for stutter mode

From Alex Deucher
8bae037b0fb429466fed1585440f337396d72efa in linux 5.15.y/5.15.58
3ce51649cdf23ab463494df2bd6d1e9529ebdc6a in mainline linux

2 years agodrm/amd/display: Fork thread to offload work of hpd_rx_irq
jsg [Mon, 1 Aug 2022 16:00:11 +0000 (16:00 +0000)]
drm/amd/display: Fork thread to offload work of hpd_rx_irq

From Wayne Lin
e980e1d978e0eb4c0399cff37f175779237db53b in linux 5.15.y/5.15.58
8e794421bc981586d0af4e959ec76d668c793a55 in mainline linux

2 years agodrm/amd/display: Add option to defer works of hpd_rx_irq
jsg [Mon, 1 Aug 2022 15:56:16 +0000 (15:56 +0000)]
drm/amd/display: Add option to defer works of hpd_rx_irq

From Wayne Lin
54740bc4b182c2522c6570c3fb0b96a912982bf3 in linux 5.15.y/5.15.58
410ad92d7fecd30de7456c19e326e272c2153ff2 in mainline linux

2 years agodrm/amd/display: Support for DMUB HPD interrupt handling
jsg [Mon, 1 Aug 2022 15:53:58 +0000 (15:53 +0000)]
drm/amd/display: Support for DMUB HPD interrupt handling

From Jude Shih
734d5ce02cb069cccedc993d8f1dc0ea41cfa3dd in linux 5.15.y/5.15.58
e27c41d5b0681c597ac1894f4e02cf626e062250 in mainline linux

2 years agosync
deraadt [Mon, 1 Aug 2022 14:57:19 +0000 (14:57 +0000)]
sync

2 years agosome ports bootstraps, and go internals, need a bit more time to adapt
deraadt [Mon, 1 Aug 2022 14:56:59 +0000 (14:56 +0000)]
some ports bootstraps, and go internals, need a bit more time to adapt
to the padded syscalls going away.

2 years agoIntroduce and use uvm_pagewait() where PG_WANTED is set.
mpi [Mon, 1 Aug 2022 14:15:46 +0000 (14:15 +0000)]
Introduce and use uvm_pagewait() where PG_WANTED is set.

No change in behavior.

ok kn@, semarie@, kettenis@

2 years agoRaise "staff" login class datasize-cur on arm64 to the value of amd64.
stsp [Mon, 1 Aug 2022 12:17:30 +0000 (12:17 +0000)]
Raise "staff" login class datasize-cur on arm64 to the value of amd64.
Values for other login classes defined in this file match amd64 already.

ok millert, tb, deraadt

2 years agoavoid double-free in error path introduced in r1.70;
djm [Mon, 1 Aug 2022 11:09:26 +0000 (11:09 +0000)]
avoid double-free in error path introduced in r1.70;
report and fix based on GHPR#332 by v-rzh
ok dtucker@

2 years agoKNF
kettenis [Mon, 1 Aug 2022 09:50:02 +0000 (09:50 +0000)]
KNF

2 years agolibc string functions were not ported from pwb to v7
jsg [Mon, 1 Aug 2022 00:04:46 +0000 (00:04 +0000)]
libc string functions were not ported from pwb to v7

https://minnie.tuhs.org/pipermail/tuhs/2017-August/011807.html

ok schwarze@

2 years agostrlen was in v6 libc (s5/perror.c) but not documented till v7
jsg [Sun, 31 Jul 2022 14:50:32 +0000 (14:50 +0000)]
strlen was in v6 libc (s5/perror.c) but not documented till v7
ok schwarze@

2 years agoTidy up some of BN_nist_mod_*
jsing [Sun, 31 Jul 2022 14:38:38 +0000 (14:38 +0000)]
Tidy up some of BN_nist_mod_*

Shuffle variables around for consistency, also ensuring appropriate and
consistent initialisation.

ok tb@

2 years agoThe geometry information in stuct disklabel is not used for
krw [Sun, 31 Jul 2022 14:29:19 +0000 (14:29 +0000)]
The geometry information in stuct disklabel is not used for
anything. Allowing modifications to it or displaying whatever
geometry was in use when the label was created leads to needless
inconsistency with the kernel and with the values displayed by,
e.g., fdisk(8).

Always set label fields d_secsize, d_nsectors, d_ntracks,
d_secpercyl, d_ncylinders to the current values used by the
kernel, obtained via DIOCGPDINFO. Ignore any values from the
on-disk label or the file -R uses.

Nuke editor command 'g' and restrict editor command 'e' to
changing d_type and d_packname.

2 years agofix indent
tb [Sun, 31 Jul 2022 13:41:45 +0000 (13:41 +0000)]
fix indent

2 years agotypo
denis [Sun, 31 Jul 2022 12:55:31 +0000 (12:55 +0000)]
typo

2 years agoAllow a NULL header in PEM_write{,_bio}()
tb [Sun, 31 Jul 2022 09:48:27 +0000 (09:48 +0000)]
Allow a NULL header in PEM_write{,_bio}()

When PEM_write{,_bio}() were documented by Rich Salz and Richard Levitte,
it was incorrectly stated that the header argument is allowed to be NULL.
This was never true.  Instead of fixing the documentation, it was decided
that the API needs a fix, so pull in a variant of OpenSSL 3b9082c8.

ok jsing

2 years agoAdd LWN in Gyumri, Shirak Region, Armenia
kn [Sun, 31 Jul 2022 06:12:20 +0000 (06:12 +0000)]
Add LWN in Gyumri, Shirak Region, Armenia

Armenian: Շիրակ Միջազգային Օդանավակայան
Russian:  Аеропорт Ширак

It has exactly one terminal and the small cafe area inside seems bigger than
the check-in area.

2 years agoRandomise the rekey interval a little. Previously, the chacha20
djm [Sun, 31 Jul 2022 05:10:36 +0000 (05:10 +0000)]
Randomise the rekey interval a little. Previously, the chacha20
instance would be rekeyed every 1.6MB. This makes it happen at a
random point somewhere in the 1-2MB range.

Feedback deraadt@ visa@, ok tb@ visa@

2 years agoReplace selwakeup() with KNOTE() in audio(4)
visa [Sun, 31 Jul 2022 03:31:36 +0000 (03:31 +0000)]
Replace selwakeup() with KNOTE() in audio(4)

KNOTE() is safe to use at IPL_AUDIO. Remove the now-unnecessary
deferring that uses soft interrupts.

Remove selwakeup() calls from audio_detach() because klist_invalidate()
wakes up any remaining kevent/poll/select waiters.

OK mpi@

2 years agoPOSIX 2008 TC2 requires <inttypes.h> to provide wchar_t
guenther [Sun, 31 Jul 2022 01:27:31 +0000 (01:27 +0000)]
POSIX 2008 TC2 requires <inttypes.h> to provide wchar_t

ok kettenis@ espie@

2 years agoNow that we have proper .text and .data sections we need to move dt_blob to
patrick [Sat, 30 Jul 2022 21:06:54 +0000 (21:06 +0000)]
Now that we have proper .text and .data sections we need to move dt_blob to
.data.  dt_blob is a basic device tree that is populated from ACPI tables
when booting with ACPI instead of DT.  Since we're modifying its content we
need to put it somewhere writeable.

Found and proposed by mlarkin@
ok kettenis@ mlarkin@

2 years agosync
sthen [Sat, 30 Jul 2022 20:21:45 +0000 (20:21 +0000)]
sync

2 years agoUse named initialisers for BIGNUMs.
jsing [Sat, 30 Jul 2022 18:03:36 +0000 (18:03 +0000)]
Use named initialisers for BIGNUMs.

Also move the _bignum_nist_p_.*_sqr static BIGNUMs out of individual
functions.

ok tb@

2 years agoKill virtual address randomization for the EFI runtime. It was a neat idea
kettenis [Sat, 30 Jul 2022 17:56:54 +0000 (17:56 +0000)]
Kill virtual address randomization for the EFI runtime.  It was a neat idea
but it appears to be too fragile and now that we are using a 48-bit VA space
for the EFI runtime we no longer need to call SetVirtualAddressMap() to
make address fit into our pmap.  Unbreaks the x13s.

ok mlarkin@, patrick@

2 years agoUntangle two logic chains in x509_asid.c into something more readable.
tb [Sat, 30 Jul 2022 17:50:17 +0000 (17:50 +0000)]
Untangle two logic chains in x509_asid.c into something more readable.

ok jsing

2 years agoupdate copyright years
tb [Sat, 30 Jul 2022 17:26:01 +0000 (17:26 +0000)]
update copyright years

2 years agoReorder functions and remove unnecessary function prototypes.
jsing [Sat, 30 Jul 2022 17:11:38 +0000 (17:11 +0000)]
Reorder functions and remove unnecessary function prototypes.

2 years agoUpdate copyright for additional/new code.
jsing [Sat, 30 Jul 2022 17:09:45 +0000 (17:09 +0000)]
Update copyright for additional/new code.

2 years agorewrite was in Tahoe
jsg [Sat, 30 Jul 2022 16:42:08 +0000 (16:42 +0000)]
rewrite was in Tahoe
ok cheloha@

2 years agoProvide additional AEAD test cases.
jsing [Sat, 30 Jul 2022 16:40:23 +0000 (16:40 +0000)]
Provide additional AEAD test cases.

Bring in additional AEAD test cases from BoringSSL.

This provides additional coverage for AES-{128,192,256}-GCM, as well as
Chacha20-Poly1305 and XChaCha20-Poly1305.

Discussed with tb@

2 years agoAdd EVP_aes_192_gcm() as a known AEAD.
jsing [Sat, 30 Jul 2022 16:31:41 +0000 (16:31 +0000)]
Add EVP_aes_192_gcm() as a known AEAD.

2 years agoAllow the AEAD to be specified for a test file.
jsing [Sat, 30 Jul 2022 16:30:42 +0000 (16:30 +0000)]
Allow the AEAD to be specified for a test file.

Currently, this must be specified per test - allow it to be given as a
command line argument that applies to the entire test file.

2 years agoRun AEAD tests against EVP_CIPHER implementations.
jsing [Sat, 30 Jul 2022 16:17:22 +0000 (16:17 +0000)]
Run AEAD tests against EVP_CIPHER implementations.

In addition to running AEAD tests against the EVP_AEAD implementation, also
run them against the EVP_CIPHER implementation where applicable.

This is a perfect example of why EVP_AEAD exists and why EVP_CIPHER is
completely unsuited for use with AEADs...

2 years agoAllow quoted ASCII strings as input for AEAD regress.
jsing [Sat, 30 Jul 2022 16:12:40 +0000 (16:12 +0000)]
Allow quoted ASCII strings as input for AEAD regress.

Currently, each line in the text file is expected to be string of
hexadecimal digits. In addition to this, allow a line to be given as an
quoted ASCII string.

2 years agosleep.1: miscellaneous rewrites, cleanup
cheloha [Sat, 30 Jul 2022 15:57:35 +0000 (15:57 +0000)]
sleep.1: miscellaneous rewrites, cleanup

Description

- "for a minimum of" is better said "for at least".

- The seconds argument can be zero, so say "non-negative".

- Specify that the number (the whole thing) is decimal to exclude
  e.g. hex numbers.  It then follows that the optional fraction
  must also be decimal.

- No need to inspire the reader to use sleep(1) in any particular way.
  It is probably sufficient to demonstrate these patterns in the Examples
  section later.

Asynchronous Events

- Note that SIGALRM wakes sleep(1) up "early".

Examples

- Simplify the first example.  Parenthetically pointing the reader to
  at(1) muddies what is otherwise a trivial example.  We can still point
  the reader to at(1) in the See Also section later.

- Shorten the interval in the first example.  A half hour is not
  interactive.

- Get rid of the entire csh(1) example.  It's extremely complex and
  the bulk of the text is spent explaining things that aren't about
  sleep(1) at all.

- Tweak the third example to show the reader that you can sleep
  for a fraction of a second, as mentioned in the Description.

Standards

- Prefer active voice.

  "The handling of fractional arguments" is better said
  "Support for fractional seconds".

  Shorten "is provided as" to "is".

History

- Not merely "appeared": "first appeared".

- Note that sleep(1) was reimplemented for 4.4BSD.

Thread: https://marc.info/?l=openbsd-tech&m=165888826603953&w=2

Lots of nice tweaks from jmc@.  Typo spotted by Crystal Kolipe.

ok jmc@