Re: kernel: remove global "randompid" toggle

2022-06-16 Thread Theo de Raadt
Miod Vallat wrote: > > Are we keeping this "randompid" global around to make it possible to > > disable random PIDs by toggling it in ddb(4)? > > IIRC this logic was needed because some kthreads were created before > arc4random was operational, but that was before substantial changes to > the ra

Re: kernel: remove global "randompid" toggle

2022-06-16 Thread Miod Vallat
> Are we keeping this "randompid" global around to make it possible to > disable random PIDs by toggling it in ddb(4)? IIRC this logic was needed because some kthreads were created before arc4random was operational, but that was before substantial changes to the random generator. However since the

Re: Lenovo ThinkCentre M910q fails to suspend

2022-06-16 Thread Mike Larkin
On Thu, Jun 16, 2022 at 08:48:36PM +0100, Edd Barrett wrote: > On Thu, Jun 16, 2022 at 10:22:16AM -0700, Mike Larkin wrote: > > did it ever work in the past? > > I've only just received the machine, so it's difficult to say. > > I've spent the last hour changing various BIOS settings to see if anyt

Re: Fix lock order reversal in nfs_inactive()

2022-06-16 Thread Jeremie Courreges-Anglas
On Thu, Jun 16 2022, Visa Hankala wrote: > nfs_inactive() has a lock order reversal. When it removes the silly > file, it locks the directory vnode while it already holds the lock > of the argument file vnode. This clashes for example with name lookups > where directory vnodes are locked before fi

Re: selecting proper GOP when there are multiple GOPs

2022-06-16 Thread YASUOKA Masahiko
On Thu, 16 Jun 2022 19:37:57 +0200 (CEST) Mark Kettenis wrote: >> Date: Thu, 16 Jun 2022 23:49:05 +0900 (JST) >> From: YASUOKA Masahiko (snip) >> @@ -444,6 +445,30 @@ efi_video_init(void) >> int i, mode80x25, mode100x31; >> UINTNc

Only scan device 0 on pcie downstream ports

2022-06-16 Thread Mark Kettenis
On the Ampere Altra machines, some PCIe devices show up 32 times; once for each possible PCI device number. This is a hardware bug, since a downstream switch port (or root port) is supposed to terminate configuration request targeted at device numbers 1-31. But it is a somewhat common bug since I

kernel: remove global "randompid" toggle

2022-06-16 Thread Scott Cheloha
All PIDs after we fork init(8) are random. This has been the case for over 8 years: https://cvsweb.openbsd.org/src/sys/kern/init_main.c?rev=1.193&content-type=text/x-cvsweb-markup Are we keeping this "randompid" global around to make it possible to disable random PIDs by toggling it in ddb(4)?

Re: Lenovo ThinkCentre M910q fails to suspend

2022-06-16 Thread Edd Barrett
On Thu, Jun 16, 2022 at 10:22:16AM -0700, Mike Larkin wrote: > did it ever work in the past? I've only just received the machine, so it's difficult to say. I've spent the last hour changing various BIOS settings to see if anything changes, but alas no. I don't see any sleep-related power options,

Re: fix KAME hack in bgpd sa2addr()

2022-06-16 Thread Theo Buehler
On Thu, Jun 16, 2022 at 05:48:48PM +0200, Claudio Jeker wrote: > Copy the version of the __KAME__ hack from route/show.c and more > importantly copy the address after modifying the sa. ok > > This only affects IPv6 link local addresses which are not really used by > bgpd. Still happy if a few mo

Re: bgpd switch kroute_find to bgpd_addr argument

2022-06-16 Thread Theo Buehler
On Thu, Jun 16, 2022 at 07:15:51PM +0200, Claudio Jeker wrote: > Not much holds us back to switch kroute_find() to use a struct bgpd_addr > as prefix argument. Only the match code needs some adoption. > I created applymask() for this which works on bgpd_addrs like > inet4applymask works on in_addrs

Re: ssh-add(1): fix NULL in fprintf

2022-06-16 Thread Martin Vahlensieck
ping, diff attached On Mon, May 16, 2022 at 09:21:42PM +0200, Martin Vahlensieck wrote: > Hi > > What's the status on this? Anthing required from my side? I have > reattached the patch (with the changes Theo suggested). > > Best, > > Martin > > On Mon, May 09, 2022 at 08:39:38PM +0200, Marti

Re: selecting proper GOP when there are multiple GOPs

2022-06-16 Thread Mark Kettenis
> Date: Thu, 16 Jun 2022 23:49:05 +0900 (JST) > From: YASUOKA Masahiko > > On Thu, 16 Jun 2022 15:52:41 +0300 > Nick Henderson wrote: > > Any updates on this patch? Would love to see it included in the next > > release. > > Yes. > > I'll commit this this weekend even if I don't get no ok. >

Re: Lenovo ThinkCentre M910q fails to suspend

2022-06-16 Thread Mike Larkin
On Thu, Jun 16, 2022 at 05:14:53PM +0100, Edd Barrett wrote: > Hi, > > Has anyone managed to get a Lenovo ThinkCentre M910q (or similar) to suspend > with OpenBSD? > > When invoking `zzz` the system prepares to go down, the screen goes blank, but > then a short while later, the system comes back, a

bgpd switch kroute_find to bgpd_addr argument

2022-06-16 Thread Claudio Jeker
Not much holds us back to switch kroute_find() to use a struct bgpd_addr as prefix argument. Only the match code needs some adoption. I created applymask() for this which works on bgpd_addrs like inet4applymask works on in_addrs. I also switched a simple case in session.c over to applymask(). Ther

Lenovo ThinkCentre M910q fails to suspend

2022-06-16 Thread Edd Barrett
Hi, Has anyone managed to get a Lenovo ThinkCentre M910q (or similar) to suspend with OpenBSD? When invoking `zzz` the system prepares to go down, the screen goes blank, but then a short while later, the system comes back, as though it was awoken straight away. Here's the diff between the initia

fix KAME hack in bgpd sa2addr()

2022-06-16 Thread Claudio Jeker
Copy the version of the __KAME__ hack from route/show.c and more importantly copy the address after modifying the sa. This only affects IPv6 link local addresses which are not really used by bgpd. Still happy if a few more people can give this a spin. -- :wq Claudio ? obj Index: util.c =

mailing list

2022-06-16 Thread Alan McGrath
subscribe *m...@openbsd.org *

Fix lock order reversal in nfs_inactive()

2022-06-16 Thread Visa Hankala
nfs_inactive() has a lock order reversal. When it removes the silly file, it locks the directory vnode while it already holds the lock of the argument file vnode. This clashes for example with name lookups where directory vnodes are locked before file vnodes. The reversal can cause a deadlock when

Re: Change behaviour of vis(3) in syslogd concerning backslash escaping

2022-06-16 Thread Alexander Bluhm
On Fri, Jun 03, 2022 at 11:26:58AM -0600, Theo de Raadt wrote: > If we do this, I think we should document it somehow that the payload is > massaged. This has been in snapshots for 10 days. The only fallout I see, is that regress has to be adapted. ok? bluhm Index: usr.sbin/syslogd/syslogd.8 =

Re: selecting proper GOP when there are multiple GOPs

2022-06-16 Thread YASUOKA Masahiko
On Thu, 16 Jun 2022 15:52:41 +0300 Nick Henderson wrote: > Any updates on this patch? Would love to see it included in the next release. Yes. I'll commit this this weekend even if I don't get no ok. ok? Index: sys/arch/amd64/stand/efiboot/efiboot.c =

Re: bgpd: next round of kroute cleanup

2022-06-16 Thread Claudio Jeker
On Thu, Jun 16, 2022 at 03:28:58PM +0200, Theo Buehler wrote: > On Thu, Jun 16, 2022 at 02:36:28PM +0200, Claudio Jeker wrote: > > This diff kills external use of prefixlen2mask() and uses inet4applymask() > > instead. With this the IPv4 and IPv6 code is more similar. > > Also I feel the code is a

Re: bgpd name2id change

2022-06-16 Thread Theo Buehler
On Thu, Jun 16, 2022 at 02:42:31PM +0200, Claudio Jeker wrote: > tb@ noticed that name2id conversions never check for error. > Now I think this is fine but in that case the api should not do a half > assed job of setting errnos. > > In the end if 0 is returned from name2id but the input was not th

Re: bgpd: next round of kroute cleanup

2022-06-16 Thread Theo Buehler
On Thu, Jun 16, 2022 at 02:36:28PM +0200, Claudio Jeker wrote: > This diff kills external use of prefixlen2mask() and uses inet4applymask() > instead. With this the IPv4 and IPv6 code is more similar. > Also I feel the code is a bit easier to read. > > Also kroute{,6}_match() is changed to take a

selecting proper GOP when there are multiple GOPs

2022-06-16 Thread Nick Henderson
Any updates on this patch? Would love to see it included in the next release. Best, Nick

bgpd name2id change

2022-06-16 Thread Claudio Jeker
tb@ noticed that name2id conversions never check for error. Now I think this is fine but in that case the api should not do a half assed job of setting errnos. In the end if 0 is returned from name2id but the input was not the empty string then an error occurred. None of the callers does this chec

bgpd: next round of kroute cleanup

2022-06-16 Thread Claudio Jeker
This diff kills external use of prefixlen2mask() and uses inet4applymask() instead. With this the IPv4 and IPv6 code is more similar. Also I feel the code is a bit easier to read. Also kroute{,6}_match() is changed to take a struct bgpd_addr *. This is another step towards removing lots of copy p

Re: bgpd: cleanup warnings in pfkey

2022-06-16 Thread Theo Buehler
On Thu, Jun 16, 2022 at 11:34:00AM +0200, Claudio Jeker wrote: > There is no reason to add the __func__ in this warning. > It is just clutter in the error message with no benefit. > > OK to remove? Yes, these don't disambiguate anything. ok

bgpd: cleanup warnings in pfkey

2022-06-16 Thread Claudio Jeker
There is no reason to add the __func__ in this warning. It is just clutter in the error message with no benefit. OK to remove? -- :wq Claudio Index: pfkey.c === RCS file: /cvs/src/usr.sbin/bgpd/pfkey.c,v retrieving revision 1.64 dif