Re: splassert: sorwakeup (ipv6 related)

2016-09-22 Thread Martin Pieuchot
On 22/09/16(Thu) 10:17, David Hill wrote:
> On Thu, Sep 22, 2016 at 04:09:37PM +0200, Sebastien Marie wrote:
> > Hi,
> > 
> > After rebuilding kernel under i386, I experimented splassert.
> > 
> > Here is a shorten backtrace handwritten:
> > 
> > splassert: sorwakeup: want 64 have 0
> > Starting stack trace...
> > splassertfail(...)
> > splassertfail(...)
> > splassertcheck(...)
> > sorwakeup(...)
> > route_input(...)
> > rt_ifmsg(...)
> > ifioctl(...)
> > sys_ioctl(...)
> > syscall(...)
> > --- syscall (number 959474688) ---
> > 
> > (I could rewrite the complete version on request as I shoted pictures
> > and it is reproductible easily).
> > 
> > It occurs at boottime during network starting.
> > 
> > My configuration is simple:
> > $ cat /etc/hostname.bce0
> > dhcp
> > rtsol
> > 
> > The splassert is trigged during `rtsol' processing, as removing it makes
> > the laptop to boot.
> > 
> > Below the dmesg (while running without ipv6).
> > -- 
> > Sebastien Marie
> 
> I hit this too.  Is this the proper fix?

It is, I just committed it, thanks!

> Index: if.c
> ===
> RCS file: /cvs/src/sys/net/if.c,v
> retrieving revision 1.449
> diff -u -p -r1.449 if.c
> --- if.c  20 Sep 2016 16:14:43 -  1.449
> +++ if.c  21 Sep 2016 16:51:39 -
> @@ -1898,7 +1898,9 @@ ifioctl(struct socket *so, u_long cmd, c
>  
>   ifp->if_xflags = (ifp->if_xflags & IFXF_CANTCHANGE) |
>   (ifr->ifr_flags & ~IFXF_CANTCHANGE);
> + s = splsoftnet();
>   rt_ifmsg(ifp);
> + splx(s);
>   break;
>  
>   case SIOCSIFMETRIC:
> 



Re: splassert: sorwakeup (ipv6 related)

2016-09-22 Thread David Hill
On Thu, Sep 22, 2016 at 04:09:37PM +0200, Sebastien Marie wrote:
> Hi,
> 
> After rebuilding kernel under i386, I experimented splassert.
> 
> Here is a shorten backtrace handwritten:
> 
> splassert: sorwakeup: want 64 have 0
> Starting stack trace...
> splassertfail(...)
> splassertfail(...)
> splassertcheck(...)
> sorwakeup(...)
> route_input(...)
> rt_ifmsg(...)
> ifioctl(...)
> sys_ioctl(...)
> syscall(...)
> --- syscall (number 959474688) ---
> 
> (I could rewrite the complete version on request as I shoted pictures
> and it is reproductible easily).
> 
> It occurs at boottime during network starting.
> 
> My configuration is simple:
> $ cat /etc/hostname.bce0
> dhcp
> rtsol
> 
> The splassert is trigged during `rtsol' processing, as removing it makes
> the laptop to boot.
> 
> Below the dmesg (while running without ipv6).
> -- 
> Sebastien Marie

I hit this too.  Is this the proper fix?

Index: if.c
===
RCS file: /cvs/src/sys/net/if.c,v
retrieving revision 1.449
diff -u -p -r1.449 if.c
--- if.c20 Sep 2016 16:14:43 -  1.449
+++ if.c21 Sep 2016 16:51:39 -
@@ -1898,7 +1898,9 @@ ifioctl(struct socket *so, u_long cmd, c
 
ifp->if_xflags = (ifp->if_xflags & IFXF_CANTCHANGE) |
(ifr->ifr_flags & ~IFXF_CANTCHANGE);
+   s = splsoftnet();
rt_ifmsg(ifp);
+   splx(s);
break;
 
case SIOCSIFMETRIC:



splassert: sorwakeup (ipv6 related)

2016-09-22 Thread Sebastien Marie
Hi,

After rebuilding kernel under i386, I experimented splassert.

Here is a shorten backtrace handwritten:

splassert: sorwakeup: want 64 have 0
Starting stack trace...
splassertfail(...)
splassertfail(...)
splassertcheck(...)
sorwakeup(...)
route_input(...)
rt_ifmsg(...)
ifioctl(...)
sys_ioctl(...)
syscall(...)
--- syscall (number 959474688) ---

(I could rewrite the complete version on request as I shoted pictures
and it is reproductible easily).

It occurs at boottime during network starting.

My configuration is simple:
$ cat /etc/hostname.bce0
dhcp
rtsol

The splassert is trigged during `rtsol' processing, as removing it makes
the laptop to boot.

Below the dmesg (while running without ipv6).
-- 
Sebastien Marie

OpenBSD 6.0-current (GENERIC.MP) #424: Thu Sep 22 15:29:57 CEST 2016
semarie@bert.local:/usr/src/sys/arch/i386/compile/GENERIC.MP
cpu0: Genuine Intel(R) CPU T2400 @ 1.83GHz ("GenuineIntel" 686-class) 1.83 GHz
cpu0: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,NXE,SSE3,MWAIT,VMX,EST,TM2,xTPR,PDCM,PERF,SENSOR
real mem  = 2137354240 (2038MB)
avail mem = 2083823616 (1987MB)
mpath0 at root
scsibus0 at mpath0: 256 targets
mainbus0 at root
bios0 at mainbus0: date 06/13/07, BIOS32 rev. 0 @ 0xffa10, SMBIOS rev. 2.4 @ 
0xf7980 (44 entries)
bios0: vendor Dell Inc. version "A17" date 06/13/2007
bios0: Dell Inc. MM061
acpi0 at bios0: rev 0
acpi0: sleep states S0 S3 S4 S5
acpi0: tables DSDT FACP HPET APIC MCFG SLIC BOOT SSDT
acpi0: wakeup devices LID_(S3) PBTN(S4) MBTN(S5) PCI0(S3) USB0(S0) USB1(S0) 
USB2(S0) USB3(S0) EHCI(S0) AZAL(S3) PCIE(S4) RP01(S4) RP02(S3) RP03(S3) 
RP04(S3) RP05(S3) [...]
acpitimer0 at acpi0: 3579545 Hz, 24 bits
acpihpet0 at acpi0: 14318179 Hz
acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
mtrr: Pentium Pro MTRR support, 8 var ranges, 88 fixed ranges
cpu0: apic clock running at 166MHz
cpu0: mwait min=64, max=64, C-substates=0.2.2.2.2, IBE
cpu1 at mainbus0: apid 1 (application processor)
cpu1: Genuine Intel(R) CPU T2400 @ 1.83GHz ("GenuineIntel" 686-class) 1.83 GHz
cpu1: 
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,NXE,SSE3,MWAIT,VMX,EST,TM2,xTPR,PDCM,PERF,SENSOR
ioapic0 at mainbus0: apid 2 pa 0xfec0, version 20, 24 pins
acpimcfg0 at acpi0 addr 0xf000, bus 0-63
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus -1 (AGP_)
acpiprt2 at acpi0: bus 3 (PCIE)
acpiprt3 at acpi0: bus 11 (RP01)
acpiprt4 at acpi0: bus -1 (RP02)
acpiprt5 at acpi0: bus -1 (RP03)
acpiprt6 at acpi0: bus 12 (RP04)
acpiprt7 at acpi0: bus -1 (RP05)
acpiprt8 at acpi0: bus -1 (RP06)
acpicpu0 at acpi0: !C3(250@85 io@0x1015), !C2(500@1 io@0x1014), C1(1000@1 
halt), PSS
acpicpu1 at acpi0: !C3(250@85 io@0x1015), !C2(500@1 io@0x1014), C1(1000@1 
halt), PSS
acpitz0 at acpi0: critical temperature is 126 degC
"*pnp0c14" at acpi0 not configured
acpiac0 at acpi0: AC unit online
acpibat0 at acpi0: BAT0 model " DELLUD2649" serial 878 type LION oem "Sanyo"
acpibtn0 at acpi0: LID_
acpibtn1 at acpi0: PBTN
acpibtn2 at acpi0: SBTN
"PNP0C32" at acpi0 not configured
"PNP0F13" at acpi0 not configured
"PNP0303" at acpi0 not configured
acpivideo0 at acpi0: VID_
acpivideo1 at acpi0: VID_
acpivout0 at acpivideo1: LCD_
acpivideo2 at acpi0: VID2
bios0: ROM list: 0xc/0xe800! 0xce800/0x1800
cpu0: Enhanced SpeedStep 1829 MHz: speeds: 1833, 1333, 1000 MHz
pci0 at mainbus0 bus 0: configuration mode 1 (bios)
pchb0 at pci0 dev 0 function 0 "Intel 82945GM Host" rev 0x03
inteldrm0 at pci0 dev 2 function 0 "Intel 82945GM Video" rev 0x03
drm0 at inteldrm0
intagp0 at inteldrm0
agp0 at intagp0: aperture at 0xd000, size 0x1000
inteldrm0: apic 2 int 16
inteldrm0: 1280x800
wsdisplay0 at inteldrm0 mux 1: console (std, vt100 emulation)
wsdisplay0: screen 1-5 added (std, vt100 emulation)
"Intel 82945GM Video" rev 0x03 at pci0 dev 2 function 1 not configured
azalia0 at pci0 dev 27 function 0 "Intel 82801GB HD Audio" rev 0x01: msi
azalia0: codecs: Sigmatel STAC9200, Conexant/0x2bfa, using Sigmatel STAC9200
audio0 at azalia0
ppb0 at pci0 dev 28 function 0 "Intel 82801GB PCIE" rev 0x01: apic 2 int 16
pci1 at ppb0 bus 11
wpi0 at pci1 dev 0 function 0 "Intel PRO/Wireless 3945ABG" rev 0x02: msi, MoW2, 
address 00:13:02:2e:8b:46
ppb1 at pci0 dev 28 function 3 "Intel 82801GB PCIE" rev 0x01: apic 2 int 19
pci2 at ppb1 bus 12
uhci0 at pci0 dev 29 function 0 "Intel 82801GB USB" rev 0x01: apic 2 int 20
uhci1 at pci0 dev 29 function 1 "Intel 82801GB USB" rev 0x01: apic 2 int 21
uhci2 at pci0 dev 29 function 2 "Intel 82801GB USB" rev 0x01: apic 2 int 22
uhci3 at pci0 dev 29 function 3 "Intel 82801GB USB" rev 0x01: apic 2 int 23
ehci0 at pci0 dev 29 function 7 "Intel 82801GB USB" rev 0x01: apic 2 int 20
usb0 at ehci0: USB revision 2.0
uhub0 at usb0 configuration 1 interface 0 "Intel EHCI root hub" rev 2.00/1.00 
addr 1
ppb2 at pci0 dev 30 function 0 "Intel 82801BAM Hub-to-PCI" re