kettenis figured out what the problem is.
There might be a solution tomorrow.
Johan Huldtgren <johan+openbsd-misc@huldtgren.com> wrote:
> hello,
>
> On 2023-01-16 10:23, Stuart Henderson wrote:
> > On 2023-01-15, Barry Grumbine <barry.grumbine@gmail.com> wrote:
> > > In case someone else runs in to this, and bothers to check misc@
> > >
> > > In this commit:
> > > https://marc.info/?l=openbsd-cvs&m=167283731726983&w=2
> > >
> > > --execute-only (aka NX bit, aka XD bit, aka Data Execution Prevention)
> > > was turned on
> >
> > NX ("no execute") is used with kernel protections that can prevent
> > memory which is mapped as being _writable_ from being executed. That afaik
> > didn't change recently (at least not on purpose?).
> >
> > execute-only is something else, it relates to mappings which are
> > protected such that they _can_ be executed but not _read_. It's now used
> > on aarch64 and riscv64 in snapshots (not everything in ports has been
> > fixed to work with it yet). There's work towards using it on amd64 but
> > the necessary cpu feature is only available on fairly new AMD machines
> > and very (for my version of 'very') new Intel machines.
> >
> > > On my ancient T520 I had to go in to BIOS and set:
> > > -> Security
> > > --> Memory Protection
> > > ---> Execution Prevention [Enable]
> > >
> > > Everything works just peachy now.
> >
> > It would be interesting to figure out what is happening with your
> > system (e.g. which change actually broke things) - there's no way it can
> > be the commit you point out. That's "restore previous behaviour when
> > compiling the EFI boot loader on aarch64/riscv64 which had got changed
> > in a different diff".
> >
> > Any idea whether the problem is just in ramdisk kernels or did it affect
> > normal boot e.g. GENERIC.MP as well?
>
> I see this issue on my old Soekris net5501s as well. Using Barry's data
> from above regarding dates I can confirm that the Janusary 6th snapshot
> on hostserver.de's archive works, but trying to install the January 7th
> snapshot results in the init message rolling until the system is power
> cycled:
>
> init: single user shell terminated, restarting
>
> If I boot the January 7th bsd (with the January 6th userland) I see
> the same behaviour as Barry reported if he upgraded using an older
> bsd.rd, ie it gets to mounting the drives and then blows up:
>
> root on wd0a (14df1105db104991.a) swap on wd0b dump on wd0b
> init: /bin/sh on /etc/rc terminated abnormally, going to single user mode
> Enter pathname of shell or RETURN for sh:
> # ls
> .cshrc boot bsd.rd home sys
> .profile bsd bsd.upgrade mnt tmp
> altroot bsd.booted dev root usr
> bin bsd.jan7 etc sbin var
> init: single user shell terminated, restarting
> Enter pathname of shell or RETURN for sh:
> # reboot
>
> Here is dmesg with January 6th snapshot installed (where everything
> works)
>
> OpenBSD 7.2-current (GENERIC) #509: Thu Jan 5 08:26:46 MST 2023
> deraadt@i386.openbsd.org:/usr/src/sys/arch/i386/compile/GENERIC
> real mem = 536363008 (511MB)
> avail mem = 509444096 (485MB)
> random: good seed from bootblocks
> mpath0 at root
> scsibus0 at mpath0: 256 targets
> mainbus0 at root
> bios0 at mainbus0: date 20/71/05, BIOS32 rev. 0 @ 0xfac40
> pcibios0 at bios0: rev 2.0 @ 0xf0000/0x10000
> pcibios0: pcibios_get_intr_routing - function not supported
> pcibios0: PCI IRQ Routing information unavailable.
> pcibios0: PCI bus #0 is the last bus
> bios0: ROM list: 0xc8000/0xa800
> cpu0 at mainbus0: (uniprocessor)
> cpu0: Geode(TM) Integrated Processor by AMD PCS ("AuthenticAMD" 586-class) 500 MHz, 05-0a-02
> cpu0: FPU,DE,PSE,TSC,MSR,CX8,SEP,PGE,CMOV,CFLUSH,MMX,MMXX,3DNOW2,3DNOW
> mtrr: K6-family MTRR support (2 registers)
> amdmsr0 at mainbus0
> pci0 at mainbus0 bus 0: configuration mode 1 (no bios)
> 0:20:0: io address conflict 0x6100/0x100
> 0:20:0: io address conflict 0x6200/0x200
> pchb0 at pci0 dev 1 function 0 "AMD Geode LX" rev 0x31
> glxsb0 at pci0 dev 1 function 2 "AMD Geode LX Crypto" rev 0x00: RNG AES
> vr0 at pci0 dev 6 function 0 "VIA VT6105M RhineIII" rev 0x96: irq 11, address 00:00:24:c9:58:4c
> ukphy0 at vr0 phy 1: Generic IEEE 802.3u media interface, rev. 3: OUI 0x004063, model 0x0034
> vr1 at pci0 dev 7 function 0 "VIA VT6105M RhineIII" rev 0x96: irq 5, address 00:00:24:c9:58:4d
> ukphy1 at vr1 phy 1: Generic IEEE 802.3u media interface, rev. 3: OUI 0x004063, model 0x0034
> vr2 at pci0 dev 8 function 0 "VIA VT6105M RhineIII" rev 0x96: irq 9, address 00:00:24:c9:58:4e
> ukphy2 at vr2 phy 1: Generic IEEE 802.3u media interface, rev. 3: OUI 0x004063, model 0x0034
> vr3 at pci0 dev 9 function 0 "VIA VT6105M RhineIII" rev 0x96: irq 12, address 00:00:24:c9:58:4f
> ukphy3 at vr3 phy 1: Generic IEEE 802.3u media interface, rev. 3: OUI 0x004063, model 0x0034
> ral0 at pci0 dev 17 function 0 "Ralink RT2561S" rev 0x00: irq 15, address 00:12:0e:61:7f:b0
> ral0: MAC/BBP RT2561C, RF RT5225
> glxpcib0 at pci0 dev 20 function 0 "AMD CS5536 ISA" rev 0x03: rev 3, 32-bit 3579545Hz timer, watchdog, gpio, i2c
> gpio0 at glxpcib0: 32 pins
> iic0 at glxpcib0
> pciide0 at pci0 dev 20 function 2 "AMD CS5536 IDE" rev 0x01: DMA, channel 0 wired to compatibility, channel 1 wired to compatibility
> wd0 at pciide0 channel 0 drive 0: <SanDisk SDCFX4-8192>
> wd0: 4-sector PIO, LBA, 7815MB, 16007040 sectors
> wd0(pciide0:0:0): using PIO mode 4, Ultra-DMA mode 2
> pciide0: channel 1 ignored (disabled)
> ohci0 at pci0 dev 21 function 0 "AMD CS5536 USB" rev 0x02: irq 7, version 1.0, legacy support
> ehci0 at pci0 dev 21 function 1 "AMD CS5536 USB" rev 0x02: irq 7
> usb0 at ehci0: USB revision 2.0
> uhub0 at usb0 configuration 1 interface 0 "AMD EHCI root hub" rev 2.00/1.00 addr 1
> isa0 at glxpcib0
> isadma0 at isa0
> com0 at isa0 port 0x3f8/8 irq 4: ns16550a, 16 byte fifo
> com0: console
> com1 at isa0 port 0x2f8/8 irq 3: ns16550a, 16 byte fifo
> pckbc0 at isa0 port 0x60/5 irq 1 irq 12
> pckbc0: unable to establish interrupt for irq 12
> pckbd0 at pckbc0 (kbd slot)
> wskbd0 at pckbd0: console keyboard
> pcppi0 at isa0 port 0x61
> spkr0 at pcppi0
> nsclpcsio0 at isa0 port 0x2e/2: NSC PC87366 rev 10: GPIO VLM TMS
> gpio1 at nsclpcsio0: 29 pins
> npx0 at isa0 port 0xf0/16: reported by CPUID; using exception 16
> usb1 at ohci0: USB revision 1.0
> uhub1 at usb1 configuration 1 interface 0 "AMD OHCI root hub" rev 1.00/1.00 addr 1
> vscsi0 at root
> scsibus1 at vscsi0: 256 targets
> softraid0 at root
> scsibus2 at softraid0: 256 targets
> root on wd0a (14df1105db104991.a) swap on wd0b dump on wd0b
>
> Here is the dmesg first booting the January 7th bsd.rd followed by trying to
> boot just bsd (here named bsd.jan7)
>
> comBIOS ver. 1.32i 20071005 Copyright (C) 2000-2007 Soekris Engineering.
>
> net5501
>
> 0512 Mbyte Memory CPU Geode LX 500 Mhz
>
> Pri Mas SanDisk SDCFX4-8192 LBA Xlt 996-255-63 8003 Mbyte
>
> Slot Vend Dev ClassRev Cmd Stat CL LT HT Base1 Base2 Int
> -------------------------------------------------------------------
> 0:01:2 1022 2082 10100000 0006 0220 08 00 00 A0000000 00000000 10
> 0:06:0 1106 3053 02000096 0117 0210 08 40 00 0000E101 A0004000 11
> 0:07:0 1106 3053 02000096 0117 0210 08 40 00 0000E201 A0004100 05
> 0:08:0 1106 3053 02000096 0117 0210 08 40 00 0000E301 A0004200 09
> 0:09:0 1106 3053 02000096 0117 0210 08 40 00 0000E401 A0004300 12
> 0:17:0 1814 0301 02800000 0117 0410 08 40 00 A0008000 00000000 15
> 0:20:0 1022 2090 06010003 0009 02A0 08 40 80 00006001 00006101
> 0:20:2 1022 209A 01018001 0005 02A0 08 00 00 00000000 00000000
> 0:21:0 1022 2094 0C031002 0006 0230 08 00 80 A0010000 00000000 07
> 0:21:1 1022 2095 0C032002 0006 0230 08 00 00 A0011000 00000000 07
>
> 4 Seconds to automatic boot. Press Ctrl-P for entering Monitor.
> Using drive 0, partition 3.
> Loading......
> probing: pc0 com0 com1 mem[639K 511M a20=on]
> disk: hd0+
> >> OpenBSD/i386 BOOT 3.44
> upgrade detected: switching to /bsd.upgrade
> switching console to com0
> >> OpenBSD/i386 BOOT 3.44
> boot>
> booting hd0a:/bsd.upgrade: 3271191+1442816+4358152+0+417792 [88+160+28]=0x90f300
> entry point at 0x201000
>
> Copyright (c) 1982, 1986, 1989, 1991, 1993
> The Regents of the University of California. All rights reserved.
> Copyright (c) 1995-2023 OpenBSD. All rights reserved. https://www.OpenBSD.org
>
> OpenBSD 7.2-current (RAMDISK_CD) #505: Thu Jan 5 16:05:47 MST 2023
> deraadt@i386.openbsd.org:/usr/src/sys/arch/i386/compile/RAMDISK_CD
> real mem = 536408064 (511MB)
> avail mem = 516382720 (492MB)
> random: good seed from bootblocks
> mainbus0 at root
> bios0 at mainbus0: date 20/71/05, BIOS32 rev. 0 @ 0xfac40
> pcibios0 at bios0: rev 2.0 @ 0xf0000/0x10000
> pcibios0: pcibios_get_intr_routing - function not supported
> pcibios0: PCI IRQ Routing information unavailable.
> pcibios0: PCI bus #0 is the last bus
> bios0: ROM list: 0xc8000/0xa800
> cpu0 at mainbus0: (uniprocessor)
> cpu0: Geode(TM) Integrated Processor by AMD PCS ("AuthenticAMD" 586-class) 500 MHz, 05-0a-02
> cpu0: FPU,DE,PSE,TSC,MSR,CX8,SEP,PGE,CMOV,CFLUSH,MMX,MMXX,3DNOW2,3DNOW
> pci0 at mainbus0 bus 0: configuration mode 1 (no bios)
> 0:20:0: io address conflict 0x6100/0x100
> 0:20:0: io address conflict 0x6200/0x200
> pchb0 at pci0 dev 1 function 0 "AMD Geode LX" rev 0x31
> "AMD Geode LX Crypto" rev 0x00 at pci0 dev 1 function 2 not configured
> vr0 at pci0 dev 6 function 0 "VIA VT6105M RhineIII" rev 0x96: irq 11, address 00:00:24:c9:58:4c
> ukphy0 at vr0 phy 1: Generic IEEE 802.3u media interface, rev. 3: OUI 0x004063, model 0x0034
> vr1 at pci0 dev 7 function 0 "VIA VT6105M RhineIII" rev 0x96: irq 5, address 00:00:24:c9:58:4d
> ukphy1 at vr1 phy 1: Generic IEEE 802.3u media interface, rev. 3: OUI 0x004063, model 0x0034
> vr2 at pci0 dev 8 function 0 "VIA VT6105M RhineIII" rev 0x96: irq 9, address 00:00:24:c9:58:4e
> ukphy2 at vr2 phy 1: Generic IEEE 802.3u media interface, rev. 3: OUI 0x004063, model 0x0034
> vr3 at pci0 dev 9 function 0 "VIA VT6105M RhineIII" rev 0x96: irq 12, address 00:00:24:c9:58:4f
> ukphy3 at vr3 phy 1: Generic IEEE 802.3u media interface, rev. 3: OUI 0x004063, model 0x0034
> ral0 at pci0 dev 17 function 0 "Ralink RT2561S" rev 0x00: irq 15, address 00:12:0e:61:7f:b0
> ral0: MAC/BBP RT2561C, RF RT5225
> pcib0 at pci0 dev 20 function 0 "AMD CS5536 ISA" rev 0x03
> pciide0 at pci0 dev 20 function 2 "AMD CS5536 IDE" rev 0x01: DMA, channel 0 wired to compatibility, channel 1 wired to compatibility
> wd0 at pciide0 channel 0 drive 0: <SanDisk SDCFX4-8192>
> wd0: 4-sector PIO, LBA, 7815MB, 16007040 sectors
> wd0(pciide0:0:0): using PIO mode 4, Ultra-DMA mode 2
> pciide0: channel 1 ignored (disabled)
> ohci0 at pci0 dev 21 function 0 "AMD CS5536 USB" rev 0x02: irq 7, version 1.0, legacy support
> ehci0 at pci0 dev 21 function 1 "AMD CS5536 USB" rev 0x02: irq 7
> usb0 at ehci0: USB revision 2.0
> uhub0 at usb0 configuration 1 interface 0 "AMD EHCI root hub" rev 2.00/1.00 addr 1
> isa0 at pcib0
> isadma0 at isa0
> com0 at isa0 port 0x3f8/8 irq 4: ns16550a, 16 byte fifo
> com0: console
> com1 at isa0 port 0x2f8/8 irq 3: ns16550a, 16 byte fifo
> pckbc0 at isa0 port 0x60/5 irq 1 irq 12
> pckbc0: unable to establish interrupt for irq 12
> pckbd0 at pckbc0 (kbd slot)
> wskbd0 at pckbd0: console keyboard
> npx0 at isa0 port 0xf0/16: reported by CPUID; using exception 16
> usb1 at ohci0: USB revision 1.0
> uhub1 at usb1 configuration 1 interface 0 "AMD OHCI root hub" rev 1.00/1.00 addr 1
> softraid0 at root
> scsibus0 at softraid0: 256 targets
> root on rd0a swap on rd0b dump on rd0b
> WARNING: CHECK AND RESET THE DATE!
> init: single user shell terminated, restarting
> init: single user shell terminated, restarting
> init: single user shell terminated, restarting
> init: single user shell terminated, restarting
> init: single user shell terminated, restarting
> init: single user shell terminated, restarting
> init: single user shell terminated, restarting
>
>
> POST: 012345689bcefghips1234ajklnopqr,,,tvwxy
>
> comBIOS ver. 1.32i 20071005 Copyright (C) 2000-2007 Soekris Engineering.
>
> net5501
>
> 0512 Mbyte Memory CPU Geode LX 500 Mhz
>
> Pri Mas SanDisk SDCFX4-8192 LBA Xlt 996-255-63 8003 Mbyte
>
> Slot Vend Dev ClassRev Cmd Stat CL LT HT Base1 Base2 Int
> -------------------------------------------------------------------
> 0:01:2 1022 2082 10100000 0006 0220 08 00 00 A0000000 00000000 10
> 0:06:0 1106 3053 02000096 0117 0210 08 40 00 0000E101 A0004000 11
> 0:07:0 1106 3053 02000096 0117 0210 08 40 00 0000E201 A0004100 05
> 0:08:0 1106 3053 02000096 0117 0210 08 40 00 0000E301 A0004200 09
> 0:09:0 1106 3053 02000096 0117 0210 08 40 00 0000E401 A0004300 12
> 0:17:0 1814 0301 02800000 0117 0410 08 40 00 A0008000 00000000 15
> 0:20:0 1022 2090 06010003 0009 02A0 08 40 80 00006001 00006101
> 0:20:2 1022 209A 01018001 0005 02A0 08 00 00 00000000 00000000
> 0:21:0 1022 2094 0C031002 0006 0230 08 00 80 A0010000 00000000 07
> 0:21:1 1022 2095 0C032002 0006 0230 08 00 00 A0011000 00000000 07
>
> 4 Seconds to automatic boot. Press Ctrl-P for entering Monitor.
> Using drive 0, partition 3.
> Loading......
> probing: pc0 com0 com1 mem[639K 511M a20=on]
> disk: hd0+
> >> OpenBSD/i386 BOOT 3.44
> upgrade detected: switching to /bsd.upgrade
> switching console to com0
> >> OpenBSD/i386 BOOT 3.44
> boot> bsd.jan7
> booting hd0a:bsd.jan7: 10590743+2569220+204808+0+1130496 [736823+107+608336+658451]=0xfbe544
> entry point at 0x201000
>
> [ using 2004292 bytes of bsd ELF symbol table ]
> Copyright (c) 1982, 1986, 1989, 1991, 1993
> The Regents of the University of California. All rights reserved.
> Copyright (c) 1995-2023 OpenBSD. All rights reserved. https://www.OpenBSD.org
>
> OpenBSD 7.2-current (GENERIC) #511: Thu Jan 5 15:41:22 MST 2023
> deraadt@i386.openbsd.org:/usr/src/sys/arch/i386/compile/GENERIC
> real mem = 536363008 (511MB)
> avail mem = 509448192 (485MB)
> random: good seed from bootblocks
> mpath0 at root
> scsibus0 at mpath0: 256 targets
> mainbus0 at root
> bios0 at mainbus0: date 20/71/05, BIOS32 rev. 0 @ 0xfac40
> pcibios0 at bios0: rev 2.0 @ 0xf0000/0x10000
> pcibios0: pcibios_get_intr_routing - function not supported
> pcibios0: PCI IRQ Routing information unavailable.
> pcibios0: PCI bus #0 is the last bus
> bios0: ROM list: 0xc8000/0xa800
> cpu0 at mainbus0: (uniprocessor)
> cpu0: Geode(TM) Integrated Processor by AMD PCS ("AuthenticAMD" 586-class) 500 MHz, 05-0a-02
> cpu0: FPU,DE,PSE,TSC,MSR,CX8,SEP,PGE,CMOV,CFLUSH,MMX,MMXX,3DNOW2,3DNOW
> mtrr: K6-family MTRR support (2 registers)
> amdmsr0 at mainbus0
> pci0 at mainbus0 bus 0: configuration mode 1 (no bios)
> 0:20:0: io address conflict 0x6100/0x100
> 0:20:0: io address conflict 0x6200/0x200
> pchb0 at pci0 dev 1 function 0 "AMD Geode LX" rev 0x31
> glxsb0 at pci0 dev 1 function 2 "AMD Geode LX Crypto" rev 0x00: RNG AES
> vr0 at pci0 dev 6 function 0 "VIA VT6105M RhineIII" rev 0x96: irq 11, address 00:00:24:c9:58:4c
> ukphy0 at vr0 phy 1: Generic IEEE 802.3u media interface, rev. 3: OUI 0x004063, model 0x0034
> vr1 at pci0 dev 7 function 0 "VIA VT6105M RhineIII" rev 0x96: irq 5, address 00:00:24:c9:58:4d
> ukphy1 at vr1 phy 1: Generic IEEE 802.3u media interface, rev. 3: OUI 0x004063, model 0x0034
> vr2 at pci0 dev 8 function 0 "VIA VT6105M RhineIII" rev 0x96: irq 9, address 00:00:24:c9:58:4e
> ukphy2 at vr2 phy 1: Generic IEEE 802.3u media interface, rev. 3: OUI 0x004063, model 0x0034
> vr3 at pci0 dev 9 function 0 "VIA VT6105M RhineIII" rev 0x96: irq 12, address 00:00:24:c9:58:4f
> ukphy3 at vr3 phy 1: Generic IEEE 802.3u media interface, rev. 3: OUI 0x004063, model 0x0034
> ral0 at pci0 dev 17 function 0 "Ralink RT2561S" rev 0x00: irq 15, address 00:12:0e:61:7f:b0
> ral0 at pci0 dev 17 function 0 "Ralink RT2561S" rev 0x00: irq 15, address 00:12:0e:61:7f:b0
> ral0: MAC/BBP RT2561C, RF RT5225
> glxpcib0 at pci0 dev 20 function 0 "AMD CS5536 ISA" rev 0x03: rev 3, 32-bit 3579545Hz timer, watchdog, gpio, i2c
> gpio0 at glxpcib0: 32 pins
> iic0 at glxpcib0
> pciide0 at pci0 dev 20 function 2 "AMD CS5536 IDE" rev 0x01: DMA, channel 0 wired to compatibility, channel 1 wired to compatibility
> wd0 at pciide0 channel 0 drive 0: <SanDisk SDCFX4-8192>
> wd0: 4-sector PIO, LBA, 7815MB, 16007040 sectors
> wd0(pciide0:0:0): using PIO mode 4, Ultra-DMA mode 2
> pciide0: channel 1 ignored (disabled)
> ohci0 at pci0 dev 21 function 0 "AMD CS5536 USB" rev 0x02: irq 7, version 1.0, legacy support
> ehci0 at pci0 dev 21 function 1 "AMD CS5536 USB" rev 0x02: irq 7
> usb0 at ehci0: USB revision 2.0
> uhub0 at usb0 configuration 1 interface 0 "AMD EHCI root hub" rev 2.00/1.00 addr 1
> isa0 at glxpcib0
> isadma0 at isa0
> com0 at isa0 port 0x3f8/8 irq 4: ns16550a, 16 byte fifo
> com0: console
> com1 at isa0 port 0x2f8/8 irq 3: ns16550a, 16 byte fifo
> pckbc0 at isa0 port 0x60/5 irq 1 irq 12
> pckbc0: unable to establish interrupt for irq 12
> pckbd0 at pckbc0 (kbd slot)
> wskbd0 at pckbd0: console keyboard
> pcppi0 at isa0 port 0x61
> spkr0 at pcppi0
> nsclpcsio0 at isa0 port 0x2e/2: NSC PC87366 rev 10: GPIO VLM TMS
> gpio1 at nsclpcsio0: 29 pins
> npx0 at isa0 port 0xf0/16: reported by CPUID; using exception 16
> usb1 at ohci0: USB revision 1.0
> uhub1 at usb1 configuration 1 interface 0 "AMD OHCI root hub" rev 1.00/1.00 addr 1
> vscsi0 at root
> scsibus1 at vscsi0: 256 targets
> softraid0 at root
> scsibus2 at softraid0: 256 targets
> root on wd0a (14df1105db104991.a) swap on wd0b dump on wd0b
> init: /bin/sh on /etc/rc terminated abnormally, going to single user mode
> Enter pathname of shell or RETURN for sh:
> # ls
> .cshrc boot bsd.rd home sys
> .profile bsd bsd.upgrade mnt tmp
> altroot bsd.booted dev root usr
> bin bsd.jan7 etc sbin var
> init: single user shell terminated, restarting
> Enter pathname of shell or RETURN for sh:
> # reboot
> syncing disks... done
> rebooting...
>
> thanks,
>
> .jh
>
No comments:
Post a Comment