acpibat: add _BIX support

2017-07-21 Thread joshua stein
ACPI 4.0 deprecated _BIF for battery status, so some newer machines have _BIX instead which provides the same info plus some extra fields. I used some macro magic to make the diff less painful, and added a sensor for the new cycle count exported by _BIX which can be useful to see. Index:

simple ifstated pledge

2017-07-21 Thread Rob Pierce
With the most recent commit ifstated can now be pledged in a straight forward manner. A better pledge is possible with more work. Does it make sense to get this one in now? Rob Index: ifstated.c === RCS file:

Re: crypt_checkpass.3: mention additional failure case for crypt_newhash

2017-07-21 Thread Ted Unangst
Scott Cheloha wrote: > crypt_newhash(3) will return -1 and set errno to EINVAL if hashsize is > too small to accommodate bcrypt's hash space. I imagine this would > also be the case if anything other than bcrypt were supported. i went ahead and reworked the page a bit. i think it clarifies a few

armv7 dumpconf()/dumpsys()

2017-07-21 Thread Artturi Alm
Hi, i think something equivalent to this diff got lost in the past, in some diff i haven't seen myself, and don't care to go digging cvs history, if there's any explanation for why not. comments? boot tested cubie2, too busy to make 'em dump right now. -Artturi diff --git

Re: armv7 bootstrap-only variables

2017-07-21 Thread Artturi Alm
On Thu, Jul 06, 2017 at 06:55:17PM +0300, Artturi Alm wrote: > Hi, > > is/has anyone been working on a diff that would collect these > into a structure, so that those could easier get gotten rid of once > bootstrap is done? Or have i missed something about this new bootstrap > split-up to

crypt_checkpass.3: mention additional failure case for crypt_newhash

2017-07-21 Thread Scott Cheloha
Hi, crypt_newhash(3) will return -1 and set errno to EINVAL if hashsize is too small to accommodate bcrypt's hash space. I imagine this would also be the case if anything other than bcrypt were supported. Test program: #include #include #include int main(int argc, char *argv[]) {

hppa SIGBUS/SIGSEGV patch

2017-07-21 Thread Mark Kettenis
Fixes regress/sys/kern/siginfo-fault on hppa. For some reason the old code munges EACCES into EFAULT so it never actually generated SEGV_ACCERR. ok? Index: arch/hppa/hppa/trap.c === RCS file: /cvs/src/sys/arch/hppa/hppa/trap.c,v

style.9: discourage (void)ing unused return values

2017-07-21 Thread Scott Cheloha
Hi, Per encouragement from deraadt@, here's a diff that explicitly discourages casting unused return values to void. The recent style.9 change from Matthew Martin deleted the last (void) cast in style.9, so I think it makes sense to formalize it. Not sure if it needs further explanation along

Re: time(1): use monotonic clock for computing elapsed time

2017-07-21 Thread Scott Cheloha
~1 week bump. Changes to time(1) were committed by tedu@. Any feedback on the ksh/csh portions of the patch? -- Scott Cheloha

Re: Document hostctl commands for XenServer

2017-07-21 Thread Mike Belopuhov
On Fri, Jul 21, 2017 at 17:49 +0200, Erik van Westen wrote: > Hi Ingo, > > Op 21-7-2017 om 16:20 schreef Ingo Schwarze: > > Hi Mike, > > > > Mike Belopuhov wrote on Fri, Jul 21, 2017 at 03:14:08PM +0200: > > > >> Together with Maxim Khitrov we have figured out what needs to > >> be set for

Re: Document hostctl commands for XenServer

2017-07-21 Thread Maxim Khitrov
On Fri, Jul 21, 2017 at 2:22 PM, Mike Belopuhov wrote: > On Fri, Jul 21, 2017 at 19:58 +0200, Ingo Schwarze wrote: >> If these numbers are completely fake and irrelevant, >> then saying so in one short sentence - or even in the >> comment line above - may be

Removing dead unused cruft from /usr/src/lib/libssl/test

2017-07-21 Thread Kurt Mosiejczuk
I was out hunting for unused cruft in the source tree and found a bunch of stuff in /usr/src/libssl/test that is unused. (Reference to ULTRIX in bctest brought me there). Each of the following files are not only ancient, but I can find no other reference to them in the rest of the source tree,

Re: Document hostctl commands for XenServer

2017-07-21 Thread Mike Belopuhov
On Fri, Jul 21, 2017 at 19:58 +0200, Ingo Schwarze wrote: > Hi Mike, > > Mike Belopuhov wrote on Fri, Jul 21, 2017 at 07:08:06PM +0200: > > > Thanks for the detailed respose, I share your outlook and in > > this case it is better to keep this stuff in the userland since > > we actually can do it

Create pvbus1 node in addition to pvbus0

2017-07-21 Thread Mike Belopuhov
As suggested by deraadt@ it's better to have /dev/pvbus1 around then document the need to create it under certain circumstances which are of course availability of multiple virtualization interfaces. The diff has survived a make build. I'm not sure the adjustment is done perfectly, but I've tried

Re: Document hostctl commands for XenServer

2017-07-21 Thread Ingo Schwarze
Hi Mike, Mike Belopuhov wrote on Fri, Jul 21, 2017 at 07:08:06PM +0200: > Thanks for the detailed respose, I share your outlook and in > this case it is better to keep this stuff in the userland since > we actually can do it just fine. Fair enough! > I will however add some text to the >

Re: Document hostctl commands for XenServer

2017-07-21 Thread Mike Belopuhov
On Fri, Jul 21, 2017 at 10:28 -0400, Maxim Khitrov wrote: > On Fri, Jul 21, 2017 at 9:14 AM, Mike Belopuhov wrote: > > Hi, > > > > Together with Maxim Khitrov we have figured out what needs to > > be set for XenServer (that's a Citrix product based on Xen) to > > "recognize"

Re: Document hostctl commands for XenServer

2017-07-21 Thread Mike Belopuhov
On Fri, Jul 21, 2017 at 16:20 +0200, Ingo Schwarze wrote: > Hi Mike, > > Mike Belopuhov wrote on Fri, Jul 21, 2017 at 03:14:08PM +0200: > > > Together with Maxim Khitrov we have figured out what needs to > > be set for XenServer > > If XenServer were free software, i would say that the OpenBSD

net80211: panic on invalid state transitions

2017-07-21 Thread Stefan Sperling
The rsu(4) driver got subtly broken in -current because it did an invalid state transition in net80211 and hence didn't actually run some of the net80211 setup code after association. To make diagnosing such bugs easier in the future I propose we make the system panic when an invalid state

Re: ospfd: add IMSG_IFADDRADD to deal with "sh /etc/netstart if"

2017-07-21 Thread Remi Locherer
On Fri, Jul 21, 2017 at 02:45:03PM +0200, Florian Riehm wrote: > On 06/25/17 23:47, Remi Locherer wrote: > > Hi, > > > > ospfd does not react nicely when running "sh /etc/netstart if". > > > > This is because adding the same address again do an interface results > > in RTM_DELADDR and

Re: cwm.1: use key names from /usr/X11R6/include/X11/keysymdef.h

2017-07-21 Thread Okan Demirmen
On Thu 2017.07.20 at 18:56 -0400, Michael Reed wrote: > While trying to unbind C-/ in cwm, it took me a while to realize > that you can't do "unbind-key C-/", as the key "/" is not defined > in /usr/X11R6/include/X11/keysymdef.h. > > Instead you must do "unbind-key C-slash", as "slash" is defined

Re: Document hostctl commands for XenServer

2017-07-21 Thread Erik van Westen
Hi Ingo, Op 21-7-2017 om 16:20 schreef Ingo Schwarze: > Hi Mike, > > Mike Belopuhov wrote on Fri, Jul 21, 2017 at 03:14:08PM +0200: > >> Together with Maxim Khitrov we have figured out what needs to >> be set for XenServer > If XenServer were free software, i would say that the OpenBSD >

Re: ifstated: no need for ioctl(SIOCGIFDATA)

2017-07-21 Thread Florian Obser
shiny! OK florian@ On Fri, Jul 21, 2017 at 04:25:58PM +0200, Jeremie Courreges-Anglas wrote: > > getifaddrs(3) can already give us access to the link state of the > interface, no need for an additional ioctl(2) call. > > Bonus: getifaddrs(3) and its underlying syscalls can be allowed by >

Re: ifstated: no need for ioctl(SIOCGIFDATA)

2017-07-21 Thread Theo de Raadt
Very good, that makes things easier for Rob. > getifaddrs(3) can already give us access to the link state of the > interface, no need for an additional ioctl(2) call. > > Bonus: getifaddrs(3) and its underlying syscalls can be allowed by > pledge(2), this is not the case for SIOCGIFDATA. > >

Re: Document hostctl commands for XenServer

2017-07-21 Thread Maxim Khitrov
On Fri, Jul 21, 2017 at 9:14 AM, Mike Belopuhov wrote: > Hi, > > Together with Maxim Khitrov we have figured out what needs to > be set for XenServer (that's a Citrix product based on Xen) to > "recognize" the OpenBSD VM and let it do things like reboot and > so on. > > I'd

ifstated: no need for ioctl(SIOCGIFDATA)

2017-07-21 Thread Jeremie Courreges-Anglas
getifaddrs(3) can already give us access to the link state of the interface, no need for an additional ioctl(2) call. Bonus: getifaddrs(3) and its underlying syscalls can be allowed by pledge(2), this is not the case for SIOCGIFDATA. Diff tested by Rob Pierce, regress tests pass. The extra

Re: Document hostctl commands for XenServer

2017-07-21 Thread Ingo Schwarze
Hi Mike, Mike Belopuhov wrote on Fri, Jul 21, 2017 at 03:14:08PM +0200: > Together with Maxim Khitrov we have figured out what needs to > be set for XenServer If XenServer were free software, i would say that the OpenBSD operating system should detect whether it is running under XenServer and

Re: [patch] ospfd: exporting default gateway via route label (fix ROUNDUP)

2017-07-21 Thread Sebastian Benoit
Florian Riehm(m...@friehm.de) on 2017.07.21 15:42:21 +0200: > On 03/03/14 00:33, Florian Riehm wrote: > > Hi all, > > > > ospfd can't export the default gateway via route label because > > get_rtaddrs gets confused by a netmask (RTAX_NETMASK) of 0 because > > sa->sa_len in get_rtaddrs is 0 and

Re: [patch] ospfd: exporting default gateway via route label (fix ROUNDUP)

2017-07-21 Thread Claudio Jeker
On Fri, Jul 21, 2017 at 03:42:21PM +0200, Florian Riehm wrote: > On 03/03/14 00:33, Florian Riehm wrote: > > Hi all, > > > > ospfd can't export the default gateway via route label because > > get_rtaddrs gets confused by a netmask (RTAX_NETMASK) of 0 because > > sa->sa_len in get_rtaddrs is 0 and

Re: [patch] ospfd: exporting default gateway via route label (fix ROUNDUP)

2017-07-21 Thread Florian Riehm
On 03/03/14 00:33, Florian Riehm wrote: > Hi all, > > ospfd can't export the default gateway via route label because > get_rtaddrs gets confused by a netmask (RTAX_NETMASK) of 0 because > sa->sa_len in get_rtaddrs is 0 and ROUNDUP then returns 0 also. > > The bug has been fixed in ospf6d in the

Document hostctl commands for XenServer

2017-07-21 Thread Mike Belopuhov
Hi, Together with Maxim Khitrov we have figured out what needs to be set for XenServer (that's a Citrix product based on Xen) to "recognize" the OpenBSD VM and let it do things like reboot and so on. I'd like to get this documented in the xen(4) man page instead of referring users to mailing

Re: ospfd: add IMSG_IFADDRADD to deal with "sh /etc/netstart if"

2017-07-21 Thread Florian Riehm
On 06/25/17 23:47, Remi Locherer wrote: > Hi, > > ospfd does not react nicely when running "sh /etc/netstart if". > > This is because adding the same address again do an interface results > in RTM_DELADDR and RTM_NEWADDR. ospfd handles the former but the later. > If this happens ospfd says

[diff] httpd: tls client cert & CRL checks

2017-07-21 Thread Jack Burton
Here's another iteration of my diff, updated to work with the new & improved imsg transfers for tls config that jsing@ committed yesterday. That helped simplify this diff significantly. Other changes since the last version: * uses simpler config (one new directive instead of three); * drops the

Re: [PATCH] ure improvement

2017-07-21 Thread sc dying
On 2017/07/20 08:31, Martin Pieuchot wrote: > On 18/07/17(Tue) 13:43, sc dying wrote: >> On 2017/07/18 09:12, Martin Pieuchot wrote: >>> On 17/07/17(Mon) 15:24, sc dying wrote: On 2017/07/17 08:24, Martin Pieuchot wrote: > On 15/07/17(Sat) 21:16, sc dying wrote: >> - Call