Re: vio0 recover from mbuf limit

2019-08-05 Thread David Gwynne
> On 5 Aug 2019, at 22:38, Alexander Bluhm wrote: > > On Thu, Jul 18, 2019 at 11:31:26PM +1000, David Gwynne wrote: >>> And I have to do ifconfig vio0 down and ifconfig vio0 up to receive >>> packets on the interface again. >> >> Can you look at systat mb when this happens to check what value

Re: SIGSEGV in libedit

2019-08-05 Thread YASUOKA Masahiko
On Mon, 05 Aug 2019 07:10:01 -0600 "Todd C. Miller" wrote: > On Mon, 05 Aug 2019 17:31:51 +0900, YASUOKA Masahiko wrote: > >> The diff basically is to do the same thing which is done on the >> upstream, but it also replaces h_malloc() and tok_malloc() which the >> upstream didn't replace yet. >

Re: unveil pathname pool

2019-08-05 Thread Theo de Raadt
I agree. I'm going to write and test a similar diff for coredump(). It is called at a deeper frame offset, thought the path is somewhat less arbitary and user-controlled. Alexander Bluhm wrote: > unveil(2) allocates 1024 bytes on the stack. That is a lot. Better > use namei pool like sys___r

Re: iwm(4) WPA2 crypto hardware offload

2019-08-05 Thread Richard Procter
> On 4/08/2019, at 11:21 PM, Stefan Sperling wrote: > On Sun, Aug 04, 2019 at 10:20:24PM +1200, Richard Procter wrote: >> >>> + >>> + return iwm_send_cmd_pdu(sc, IWM_ADD_STA_KEY, IWM_CMD_ASYNC, >>> + sizeof(cmd), &cmd); >> >> Might the async command open a race between loading keys and

Re: TSC synchronization on MP machines

2019-08-05 Thread Mike Larkin
On Tue, Aug 06, 2019 at 12:38:51AM +0200, Mark Kettenis wrote: > > Date: Mon, 5 Aug 2019 16:58:27 +0300 > > From: Paul Irofti > > > > On Fri, Aug 02, 2019 at 01:29:37PM +0300, Paul Irofti wrote: > > > On Mon, Jul 01, 2019 at 10:32:51AM +0200, Mark Kettenis wrote: > > > > > Date: Thu, 27 Jun 2019

Re: TSC synchronization on MP machines

2019-08-05 Thread Mark Kettenis
> Date: Mon, 5 Aug 2019 16:58:27 +0300 > From: Paul Irofti > > On Fri, Aug 02, 2019 at 01:29:37PM +0300, Paul Irofti wrote: > > On Mon, Jul 01, 2019 at 10:32:51AM +0200, Mark Kettenis wrote: > > > > Date: Thu, 27 Jun 2019 15:08:00 +0300 > > > > From: Paul Irofti > > > > > > > > Hi, > > > > > >

Re: TSC synchronization on MP machines

2019-08-05 Thread Mark Kettenis
> Date: Mon, 5 Aug 2019 16:58:27 +0300 > From: Paul Irofti > > On Fri, Aug 02, 2019 at 01:29:37PM +0300, Paul Irofti wrote: > > On Mon, Jul 01, 2019 at 10:32:51AM +0200, Mark Kettenis wrote: > > > > Date: Thu, 27 Jun 2019 15:08:00 +0300 > > > > From: Paul Irofti > > > > > > > > Hi, > > > > > >

dwiic(4) fifo depths

2019-08-05 Thread Mark Kettenis
The dwiic(4) controller on the Ampere eMAG machines has a Tx and Rx FIFO depth of 16 bytes. The FIFO depth can be read from a register. However Linux implements logic where (at least for ACPI) the FIFO depth defaults to 32 bytes and is reduced if a valid (lower) value is found in the register. So

Re: TSC synchronization on MP machines

2019-08-05 Thread Bryan Steele
On Mon, Aug 05, 2019 at 04:58:27PM +0300, Paul Irofti wrote: > Hi, > > Here is a third version of the TSC diff that also take into > consideration the suspend-resume path which was ignored by the previous > thus rendering resume broken. > > Have a go at it. Reports are welcome. So far I only got

unveil pathname pool

2019-08-05 Thread Alexander Bluhm
Hi, unveil(2) allocates 1024 bytes on the stack. That is a lot. Better use namei pool like sys___realpath() does. ok? bluhm Index: kern/vfs_syscalls.c === RCS file: /data/mirror/openbsd/cvs/src/sys/kern/vfs_syscalls.c,v retrievin

Re: TSC synchronization on MP machines

2019-08-05 Thread Paul Irofti
On Fri, Aug 02, 2019 at 01:29:37PM +0300, Paul Irofti wrote: > On Mon, Jul 01, 2019 at 10:32:51AM +0200, Mark Kettenis wrote: > > > Date: Thu, 27 Jun 2019 15:08:00 +0300 > > > From: Paul Irofti > > > > > > Hi, > > > > > > Here is an initial diff, adapted from NetBSD, that synchronizes TSC > > >

Re: SIGSEGV in libedit

2019-08-05 Thread Todd C . Miller
On Mon, 05 Aug 2019 17:31:51 +0900, YASUOKA Masahiko wrote: > The diff basically is to do the same thing which is done on the > upstream, but it also replaces h_malloc() and tok_malloc() which the > upstream didn't replace yet. This only changes the reallocarray(3) calls that don't actually reall

vio0 recover from mbuf limit

2019-08-05 Thread Alexander Bluhm
On Thu, Jul 18, 2019 at 11:31:26PM +1000, David Gwynne wrote: > > And I have to do ifconfig vio0 down and ifconfig vio0 up to receive > > packets on the interface again. > > Can you look at systat mb when this happens to check what value > vio0 has in the ALIVE column? If ALIVE is 0, it means the r

Re: ber_oid_cmp don't rely on 0 elements

2019-08-05 Thread Claudio Jeker
On Wed, Jul 31, 2019 at 10:27:58PM +0200, Martijn van Duren wrote: > Similar edgecase to ber_get_oid, but doesn't seem to influence snmpctl > walk. It does however influence another project of mine. > > snmpd returns ip addresses for e.g. inetCidrRouteIfIndex, which can > contain 0 elements in t

Re: Host Header Redirection on openbsd.org

2019-08-05 Thread Marc Espie
Well, the main issue I've seen so far is you flooding my mailboxen with lots of copies of the same useless mp4 video. What a douche.

Re: ber_get_oid accept 0 value at start oid

2019-08-05 Thread Claudio Jeker
On Wed, Jul 31, 2019 at 09:34:22PM +0200, Martijn van Duren wrote: > Found this while playing around with snmp. > > Right now we don't accept a 0 value the start of an oid. Since we return > 0.0 OIDs from snmpd they don't get displayed when querying them with > snmpctl. Diff below removes this res

Re: SIGSEGV in libedit

2019-08-05 Thread Ingo Schwarze
Hello Yasuoka-san, YASUOKA Masahiko wrote on Mon, Aug 05, 2019 at 04:20:41PM +0900: > This is the diff which fixes the problem by replacing malloc by calloc. > > Initialize the line buffer by zero when allocation. This fixes the > problem a crash happens after the window size change. Actually,

Re: files.pci: sis missing dependency for mii_phy

2019-08-05 Thread Alexander von Gernler
* Stefan Sperling [2019-08-05 10:33]: > Your patch had tabs replaced by spaces so it didn't apply as-is. > I had to apply it manually. Sorry for that. I guess something went wrong when pasting it inline.

Re: files.pci: sis missing dependency for mii_phy

2019-08-05 Thread Stefan Sperling
On Sun, Aug 04, 2019 at 05:26:40PM +0200, Alexander von Gernler wrote: > Just like other interfaces, sis depends on mii_phy in order to > configure it via config(8). Found out the hard way while building a custom > kernel for my Soekris net4501. > > In GENERIC, this missing dependency is shadowed

Re: SIGSEGV in libedit

2019-08-05 Thread YASUOKA Masahiko
Hi, On Thu, 1 Aug 2019 18:02:41 +0200 Ingo Schwarze wrote: > YASUOKA Masahiko wrote on Thu, Aug 01, 2019 at 08:42:35PM +0900: >> I noticed the upstream NetBSD recently replaced almost all malloc(3)s >> by calloc(3) in libedit. >> >> https://github.com/NetBSD/src/commit/b91b3c48e0edb116bd79758643

Re: SIGSEGV in libedit

2019-08-05 Thread YASUOKA Masahiko
Hi, On Thu, 1 Aug 2019 18:02:41 +0200 Ingo Schwarze wrote: > YASUOKA Masahiko wrote on Thu, Aug 01, 2019 at 08:42:35PM +0900: >> I noticed the upstream NetBSD recently replaced almost all malloc(3)s >> by calloc(3) in libedit. >> >> https://github.com/NetBSD/src/commit/b91b3c48e0edb116bd79758643