Re: OpenBSD 7.4/amd64 on APU4D4 - kernel panic
but it doesn't work for another APC UPS hardware OpenBSD 7.4-current (GENERIC.MP) #1623: Tue Jan 23 22:30:16 MST 2024 dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP real mem = 4259917824 (4062MB) avail mem = 4110110720 (3919MB) random: good seed from bootblocks mpath0 at root scsibus0 at mpath0: 256 targets mainbus0 at root bios0 at mainbus0: SMBIOS rev. 3.0 @ 0xcfe97040 (13 entries) bios0: vendor coreboot version "v4.19.0.1" date 01/31/2023 bios0: PC Engines apu4 acpi0 at bios0: ACPI 6.0 acpi0: sleep states S0 S1 S4 S5 acpi0: tables DSDT FACP SSDT MCFG TPM2 APIC HEST SSDT SSDT DRTM HPET acpi0: wakeup devices PBR4(S4) PBR5(S4) PBR6(S4) PBR7(S4) PBR8(S4) UOH1(S3) UOH2(S3) UOH3(S3) UOH4(S3) UOH5(S3) UOH6(S3) XHC0(S4) acpitimer0 at acpi0: 3579545 Hz, 32 bits acpimcfg0 at acpi0 acpimcfg0: addr 0xf800, bus 0-63 acpimadt0 at acpi0 addr 0xfee0: PC-AT compat cpu0 at mainbus0: apid 0 (boot processor) cpu0: AMD GX-412TC SOC, 998.17 MHz, 16-30-01, patch 07030105 cpu0: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,PCLMUL,MWAIT,SSSE3,CX16,SSE4.1,SSE4.2,MOVBE,PT cpu0: 32KB 64b/line 8-way D-cache, 32KB 64b/line 2-way I-cache, 2MB 64b/line 16-way L2 cache cpu0: smt 0, core 0, package 0 mtrr: Pentium Pro MTRR support, 8 var ranges, 88 fixed ranges cpu0: apic clock running at 99MHz cpu0: mwait min=64, max=64, IBE cpu1 at mainbus0: apid 1 (application processor) cpu1: AMD GX-412TC SOC, 998.21 MHz, 16-30-01, patch 07030105 cpu1: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,PCLMUL,MWAIT,SSSE3,CX16,SSE4.1,SSE4.2,MOVBE,PT cpu1: 32KB 64b/line 8-way D-cache, 32KB 64b/line 2-way I-cache, 2MB 64b/line 16-way L2 cache cpu1: smt 0, core 1, package 0 cpu2 at mainbus0: apid 2 (application processor) cpu2: AMD GX-412TC SOC, 998.30 MHz, 16-30-01, patch 07030105 cpu2: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,PCLMUL,MWAIT,SSSE3,CX16,SSE4.1,SSE4.2,MOVBE,PT cpu2: 32KB 64b/line 8-way D-cache, 32KB 64b/line 2-way I-cache, 2MB 64b/line 16-way L2 cache cpu2: smt 0, core 2, package 0 cpu3 at mainbus0: apid 3 (application processor) cpu3: AMD GX-412TC SOC, 998.34 MHz, 16-30-01, patch 07030105 cpu3: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,PCLMUL,MWAIT,SSSE3,CX16,SSE4.1,SSE4.2,MOVBE,PT cpu3: 32KB 64b/line 8-way D-cache, 32KB 64b/line 2-way I-cache, 2MB 64b/line 16-way L2 cache cpu3: smt 0, core 3, package 0 ioapic0 at mainbus0: apid 4 pa 0xfec0, version 21, 24 pins ioapic1 at mainbus0: apid 5 pa 0xfec2, version 21, 32 pins acpihpet0 at acpi0: 14318180 Hz acpiprt0 at acpi0: bus 0 (PCI0) acpiprt1 at acpi0: bus 1 (PBR4) acpiprt2 at acpi0: bus 2 (PBR5) acpiprt3 at acpi0: bus 3 (PBR6) acpiprt4 at acpi0: bus 4 (PBR7) acpiprt5 at acpi0: bus -1 (PBR8) acpicpu0 at acpi0: C2(0@400 io@0x1771), C1(@1 halt!), PSS acpicpu1 at acpi0: C2(0@400 io@0x1771), C1(@1 halt!), PSS acpicpu2 at acpi0: C2(0@400 io@0x1771), C1(@1 halt!), PSS acpicpu3 at acpi0: C2(0@400 io@0x1771), C1(@1 halt!), PSS acpicpu4 at acpi0: no cpu matching ACPI ID 4 acpicpu5 at acpi0: no cpu matching ACPI ID 5 acpicpu6 at acpi0: no cpu matching ACPI ID 6 acpicpu7 at acpi0: no cpu matching ACPI ID 7 acpipci0 at acpi0 PCI0: 0x 0x0011 0x0001 acpicmos0 at acpi0 com0 at acpi0 COM1 addr 0x3f8/0x8 irq 4: ns16550a, 16 byte fifo com0: console com1 at acpi0 COM2 addr 0x2f8/0x8 irq 3: ns16550a, 16 byte fifo amdgpio0 at acpi0 GPIO uid 0 addr 0xfed81500/0x300 irq 7, 184 pins "PRP0001" at acpi0 not configured "PRP0001" at acpi0 not configured "PRP0001" at acpi0 not configured "PRP0001" at acpi0 not configured "PRP0001" at acpi0 not configured "PRP0001" at acpi0 not configured "BOOT" at acpi0 not configured acpitz0 at acpi0: critical temperature is 115 degC cpu0: 998 MHz: speeds: 1000 800 600 MHz pci0 at mainbus0 bus 0 pchb0 at pci0 dev 0 function 0 "AMD 16h Root Complex" rev 0x00 vendor "AMD", unknown product 0x1567 (class system subclass IOMMU, rev 0x00) at pci0 dev 0 function 2 not configured pchb1 at pci0 dev 2 function 0 "AMD 16h Host" rev 0x00 ppb0 at pci0 dev 2 function 1 "AMD 16h PCIE" rev 0x00: msi pci1 at ppb0 bus 1 em0 at pci1 dev 0 function 0 "Intel I211" rev 0x03: msi, address 00:0d:b9:59:e0:90 ppb1 at pci0 dev 2 function 2 "AMD 16h PCIE" rev 0x00: msi pci2 at ppb1 bus 2 em1 at pci2 dev 0 function 0 "Intel I211" rev 0x03: msi, address 00:0d:b9:59:e0:91 ppb2 at pci0 dev 2 function 3 "AMD 16h PCIE" rev 0x00: msi pci3 at ppb2 bus 3 em2 at pci3 dev 0 function 0 "Intel I211" rev 0x03: msi, address 00:0d:b9:59:e0:92 ppb3 at pci0 dev 2 function 4 "AMD 16h PCIE" rev 0x00: msi pci4 at ppb3 bus 4 em3 at pci4 dev 0 function 0 "Intel I211" rev 0x03: msi, address 00:0d:b9:59:e0:93 ccp0 at pci0 dev 8 function 0 "AMD 16h Crypto" rev 0x00 xhci0 at pci0 dev 16 function 0 "AMD Bolton xHCI" rev
Trouble with console on UART
>Synopsis:Console is lost at boot when com0 is on a UART PCI >Category:system amd64 >Environment: System : OpenBSD 7.4 Details : OpenBSD 7.4 (GENERIC.MP) #2: Fri Dec 8 15:39:04 MST 2023 r...@syspatch-74-amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP Architecture: OpenBSD.amd64 Machine : amd64 >Description: Looking for a replacement for Soekris or PCengines machines, I chose a Qotom mini-pc featured in a Servethehome video. I chose the 8GB RAM 256GB SSD, Q20321G9 C3558R model My intent is to use it as a OpenBSD router, so once I get it I started to play with it. Making a USB boot key from install74.img with Etcher (on a windows workstation, sue me) I booted without problem after setting up the boot order in the Bios/UEFI.Interestingly it comes with a preinstalled Windows install without activation number on the SSD, well I just flushed it all. The 2.5G and 10 SFP+ interfaces are seen as igc and ix interfaces, great. Now there is the problem I stumbled into, it is the console port. first, it is not enabled by default, you have to go into the Bios/UEFI to enable it (meaning connecting a USB keyboard and a VGA monitor) and it presents as such in the menus with a toggle to Enable/Disable: COM0(Pci Bus0,Dev26,Func0) and also some nice options to change like the type of console or speed. Doing so you get your display redirected on the console, fantastic. However when you boot your OpenBSD you get this on the console: Using drive 0, partition 3. Loading..probing: pc0 mem[620K 993M 928M 91M 852K 3M 6144M a20=on] disk: hd0+ >> OpenBSD/amd64 BOOT 3.65 boot>booting hd0a:/bsd: 17241420+4137992+368672+0+1241088 [1340879+128+1321080+101331 And nothing more, your main display is on the VGA monitor, expected since the redirecting of the tty on the console is not done. In all logic I then tried to boot OpenBSD with set tty com0 But when doing this here is what you get: boot> set tty com0 switching console to com0 And that's it... no more access to your keyboard and the console is lost. Booting the OS completely here's what we can see on dmesg "Intel C3000 UART" rev 0x11 at pci0 dev 26 function 0 not configured So it seems that from the moment you try telling to use the com0 port you loose all access... this UART thing is not properly recognized. For comparison on a PCengine machine: com0 at acpi0 COM1 addr 0x3f8/0x8 irq 4: ns16550a, 16 byte fifo com0: console com1 at isa0 port 0x2f8/8 irq 3: ns16550a, 16 byte fifo The com port there is ISA bus Is there something I'm missing to catch the console or enable it in OpenBSD, or is it a non-supported trouble. >How-To-Repeat: Have a Qotom mini PC with a console port being com0 on PCI UART, try to set a tty on com0
Re: Trouble with console on UART
On Sat, Jan 27, 2024 at 07:54:43PM +0900, stran...@free.fr wrote: > >Synopsis:Console is lost at boot when com0 is on a UART PCI > >Category:system amd64 > >Environment: > System : OpenBSD 7.4 > Details : OpenBSD 7.4 (GENERIC.MP) #2: Fri Dec 8 15:39:04 MST 2023 > > r...@syspatch-74-amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP > > Architecture: OpenBSD.amd64 > Machine : amd64 > >Description: > Looking for a replacement for Soekris or PCengines machines, I chose a Qotom > mini-pc featured in a Servethehome video. > > I chose the 8GB RAM 256GB SSD, Q20321G9 C3558R model > > My intent is to use it as a OpenBSD router, so once I get it I started to > play with it. > > Making a USB boot key from install74.img with Etcher (on a windows > workstation, sue me) I booted without problem after setting up the boot order > in the Bios/UEFI.Interestingly it comes with a preinstalled Windows install > without activation number on the SSD, well I just flushed it all. > > The 2.5G and 10 SFP+ interfaces are seen as igc and ix interfaces, great. > > Now there is the problem I stumbled into, it is the console port. > > first, it is not enabled by default, you have to go into the Bios/UEFI to > enable it (meaning connecting a USB keyboard and a VGA monitor) and it > presents as such in the menus with a toggle to Enable/Disable: > COM0(Pci Bus0,Dev26,Func0) > and also some nice options to change like the type of console or speed. > > Doing so you get your display redirected on the console, fantastic. > > However when you boot your OpenBSD you get this on the console: > Using drive 0, partition 3. > Loading..probing: pc0 mem[620K 993M 928M 91M 852K 3M 6144M a20=on] > disk: hd0+ > >> OpenBSD/amd64 BOOT 3.65 > boot>booting hd0a:/bsd: 17241420+4137992+368672+0+1241088 > [1340879+128+1321080+101331 > > And nothing more, your main display is on the VGA monitor, expected since the > redirecting of the tty on the console is not done. > > In all logic I then tried to boot OpenBSD with > set tty com0 > But when doing this here is what you get: > boot> set tty com0 > switching console to com0 > > And that's it... no more access to your keyboard and the console is lost. > > Booting the OS completely here's what we can see on dmesg > "Intel C3000 UART" rev 0x11 at pci0 dev 26 function 0 not configured > > So it seems that from the moment you try telling to use the com0 port you > loose all access... this UART thing is not properly recognized. > > For comparison on a PCengine machine: > com0 at acpi0 COM1 addr 0x3f8/0x8 irq 4: ns16550a, 16 byte fifo > com0: console > com1 at isa0 port 0x2f8/8 irq 3: ns16550a, 16 byte fifo > The com port there is ISA bus > > Is there something I'm missing to catch the console or enable it in OpenBSD, > or is it a non-supported trouble. pci serial is normally handled by puc(4), try this: Index: sys/dev/pci/pucdata.c === RCS file: /cvs/src/sys/dev/pci/pucdata.c,v diff -u -p -r1.118 pucdata.c --- sys/dev/pci/pucdata.c 24 Oct 2022 05:57:58 - 1.118 +++ sys/dev/pci/pucdata.c 27 Jan 2024 11:46:33 - @@ -306,6 +306,13 @@ const struct puc_device_description puc_ { PUC_PORT_COM, 0x10, 0x }, }, }, + { /* Intel C3000 UART */ + { PCI_VENDOR_INTEL, PCI_PRODUCT_INTEL_C3000_HSUART, 0x, 0x }, + { 0x, 0x, 0x, 0x }, + { + { PUC_PORT_COM, 0x10, 0x }, + }, + }, /* * XXX no entry because I have no data: * XXX Dolphin Peripherals 4006 (single parallel)
Re: Trouble with console on UART
> Date: Sat, 27 Jan 2024 19:54:43 +0900 (JST) > From: stran...@free.fr > > >Synopsis:Console is lost at boot when com0 is on a UART PCI > >Category:system amd64 > >Environment: > System : OpenBSD 7.4 > Details : OpenBSD 7.4 (GENERIC.MP) #2: Fri Dec 8 15:39:04 MST 2023 > > r...@syspatch-74-amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP > > Architecture: OpenBSD.amd64 > Machine : amd64 > >Description: > Looking for a replacement for Soekris or PCengines machines, I chose a Qotom > mini-pc featured in a Servethehome video. > > I chose the 8GB RAM 256GB SSD, Q20321G9 C3558R model > > My intent is to use it as a OpenBSD router, so once I get it I started to > play with it. > > Making a USB boot key from install74.img with Etcher (on a windows > workstation, sue me) I booted without problem after setting up the boot order > in the Bios/UEFI.Interestingly it comes with a preinstalled Windows install > without activation number on the SSD, well I just flushed it all. > > The 2.5G and 10 SFP+ interfaces are seen as igc and ix interfaces, great. > > Now there is the problem I stumbled into, it is the console port. > > first, it is not enabled by default, you have to go into the Bios/UEFI to > enable it (meaning connecting a USB keyboard and a VGA monitor) and it > presents as such in the menus with a toggle to Enable/Disable: > COM0(Pci Bus0,Dev26,Func0) > and also some nice options to change like the type of console or speed. > > Doing so you get your display redirected on the console, fantastic. > > However when you boot your OpenBSD you get this on the console: > Using drive 0, partition 3. > Loading..probing: pc0 mem[620K 993M 928M 91M 852K 3M 6144M a20=on] > disk: hd0+ > >> OpenBSD/amd64 BOOT 3.65 > boot>booting hd0a:/bsd: 17241420+4137992+368672+0+1241088 > [1340879+128+1321080+101331 > > And nothing more, your main display is on the VGA monitor, expected since the > redirecting of the tty on the console is not done. > > In all logic I then tried to boot OpenBSD with > set tty com0 > But when doing this here is what you get: > boot> set tty com0 > switching console to com0 > > And that's it... no more access to your keyboard and the console is lost. > > Booting the OS completely here's what we can see on dmesg > "Intel C3000 UART" rev 0x11 at pci0 dev 26 function 0 not configured > > So it seems that from the moment you try telling to use the com0 port you > loose all access... this UART thing is not properly recognized. > > For comparison on a PCengine machine: > com0 at acpi0 COM1 addr 0x3f8/0x8 irq 4: ns16550a, 16 byte fifo > com0: console > com1 at isa0 port 0x2f8/8 irq 3: ns16550a, 16 byte fifo > The com port there is ISA bus > > Is there something I'm missing to catch the console or enable it in OpenBSD, > or is it a non-supported trouble. Pretty much the latter. Now it may be possible to turn that into supported trouble with some minor changes to the code if you're able to test some patches for me. As a first step can you send me: * The full dmesg for this machine * The acpidump output for this machine (tar up everything in /var/db/acpi) * The output of pcidump -vxxx Cheers, Mark
Re: Trouble with console on UART
Hello Jonathan, made a kernel with the patch and here is what I get on dmesg: puc0 at pci0 dev 26 function 0 "Intel C3000 UART" rev 0x11: ports: 16 com com4 at puc0 port 0 apic 2 int 16: ns16550a, 16 byte fifo so now it seems to get the com port, however when I type "set tty com4" on the boot prompt I get the same result than before, the system freezes (or more accurately the input/output goes into the limbo). I am missing something here ? Le 27/01/2024 à 20:52, Jonathan Gray a écrit : On Sat, Jan 27, 2024 at 07:54:43PM +0900, stran...@free.fr wrote: Synopsis:Console is lost at boot when com0 is on a UART PCI Category:system amd64 Environment: System : OpenBSD 7.4 Details : OpenBSD 7.4 (GENERIC.MP) #2: Fri Dec 8 15:39:04 MST 2023 r...@syspatch-74-amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP Architecture: OpenBSD.amd64 Machine : amd64 Description: Looking for a replacement for Soekris or PCengines machines, I chose a Qotom mini-pc featured in a Servethehome video. I chose the 8GB RAM 256GB SSD, Q20321G9 C3558R model My intent is to use it as a OpenBSD router, so once I get it I started to play with it. Making a USB boot key from install74.img with Etcher (on a windows workstation, sue me) I booted without problem after setting up the boot order in the Bios/UEFI.Interestingly it comes with a preinstalled Windows install without activation number on the SSD, well I just flushed it all. The 2.5G and 10 SFP+ interfaces are seen as igc and ix interfaces, great. Now there is the problem I stumbled into, it is the console port. first, it is not enabled by default, you have to go into the Bios/UEFI to enable it (meaning connecting a USB keyboard and a VGA monitor) and it presents as such in the menus with a toggle to Enable/Disable: COM0(Pci Bus0,Dev26,Func0) and also some nice options to change like the type of console or speed. Doing so you get your display redirected on the console, fantastic. However when you boot your OpenBSD you get this on the console: Using drive 0, partition 3. Loading..probing: pc0 mem[620K 993M 928M 91M 852K 3M 6144M a20=on] disk: hd0+ OpenBSD/amd64 BOOT 3.65 boot>booting hd0a:/bsd: 17241420+4137992+368672+0+1241088 [1340879+128+1321080+101331 And nothing more, your main display is on the VGA monitor, expected since the redirecting of the tty on the console is not done. In all logic I then tried to boot OpenBSD with set tty com0 But when doing this here is what you get: boot> set tty com0 switching console to com0 And that's it... no more access to your keyboard and the console is lost. Booting the OS completely here's what we can see on dmesg "Intel C3000 UART" rev 0x11 at pci0 dev 26 function 0 not configured So it seems that from the moment you try telling to use the com0 port you loose all access... this UART thing is not properly recognized. For comparison on a PCengine machine: com0 at acpi0 COM1 addr 0x3f8/0x8 irq 4: ns16550a, 16 byte fifo com0: console com1 at isa0 port 0x2f8/8 irq 3: ns16550a, 16 byte fifo The com port there is ISA bus Is there something I'm missing to catch the console or enable it in OpenBSD, or is it a non-supported trouble. pci serial is normally handled by puc(4), try this: Index: sys/dev/pci/pucdata.c === RCS file: /cvs/src/sys/dev/pci/pucdata.c,v diff -u -p -r1.118 pucdata.c --- sys/dev/pci/pucdata.c 24 Oct 2022 05:57:58 - 1.118 +++ sys/dev/pci/pucdata.c 27 Jan 2024 11:46:33 - @@ -306,6 +306,13 @@ const struct puc_device_description puc_ { PUC_PORT_COM, 0x10, 0x }, }, }, + { /* Intel C3000 UART */ + { PCI_VENDOR_INTEL, PCI_PRODUCT_INTEL_C3000_HSUART, 0x, 0x }, + { 0x, 0x, 0x, 0x }, + { + { PUC_PORT_COM, 0x10, 0x }, + }, + }, /* * XXX no entry because I have no data: * XXX Dolphin Peripherals 4006 (single parallel)
Re: Trouble with console on UART
> Date: Sat, 27 Jan 2024 22:47:05 +0900 > From: stephane Tranchemer > > Hello Jonathan, > > made a kernel with the patch and here is what I get on dmesg: > > puc0 at pci0 dev 26 function 0 "Intel C3000 UART" rev 0x11: ports: 16 com > com4 at puc0 port 0 apic 2 int 16: ns16550a, 16 byte fifo > > so now it seems to get the com port, however when I type "set tty com4" > on the boot prompt I get the same result than before, the system freezes > (or more accurately the input/output goes into the limbo). > > I am missing something here ? Try typing "mach comaddr 0xe060" before "set tty com4".
Re: Trouble with console on UART
Works ! I actually had to do stty com4 115200 mach comaddr 0xe060 set tty com4 Le 27/01/2024 à 23:05, Mark Kettenis a écrit : Date: Sat, 27 Jan 2024 22:47:05 +0900 From: stephane Tranchemer Hello Jonathan, made a kernel with the patch and here is what I get on dmesg: puc0 at pci0 dev 26 function 0 "Intel C3000 UART" rev 0x11: ports: 16 com com4 at puc0 port 0 apic 2 int 16: ns16550a, 16 byte fifo so now it seems to get the com port, however when I type "set tty com4" on the boot prompt I get the same result than before, the system freezes (or more accurately the input/output goes into the limbo). I am missing something here ? Try typing "mach comaddr 0xe060" before "set tty com4".
Re: Trouble with console on UART
I said works with stty com4 115200 mach comaddr 0xe060 set tty com4 but not entirely... I indeed get the output of the kernel loading and the system is up, but I don't get a login prompt at the end. Here is a sample of the last lines I get throught console: [...] clearing /tmp kern.securelevel: 0 -> 1 creating runtime link editor directory cache. preserving editor files. starting network daemons: sshd smtpd sndiod. starting local daemons: cron. Sat Jan 27 23:11:02 JST 2024 Something to do with /etc/ttys ? Le 27/01/2024 à 23:05, Mark Kettenis a écrit : Date: Sat, 27 Jan 2024 22:47:05 +0900 From: stephane Tranchemer Hello Jonathan, made a kernel with the patch and here is what I get on dmesg: puc0 at pci0 dev 26 function 0 "Intel C3000 UART" rev 0x11: ports: 16 com com4 at puc0 port 0 apic 2 int 16: ns16550a, 16 byte fifo so now it seems to get the com port, however when I type "set tty com4" on the boot prompt I get the same result than before, the system freezes (or more accurately the input/output goes into the limbo). I am missing something here ? Try typing "mach comaddr 0xe060" before "set tty com4".
Re: Trouble with console on UART
On Sat, Jan 27, 2024, at 8:21 AM, stephane Tranchemer wrote: > I said works with > > stty com4 115200 > mach comaddr 0xe060 > set tty com4 > > but not entirely... > I indeed get the output of the kernel loading and the system is up, but > I don't get a login prompt at the end. > > Here is a sample of the last lines I get throught console: > [...] > > clearing /tmp > kern.securelevel: 0 -> 1 > creating runtime link editor directory cache. > preserving editor files. > starting network daemons: sshd smtpd sndiod. > starting local daemons: cron. > Sat Jan 27 23:11:02 JST 2024 > > Something to do with /etc/ttys ? Yes. https://www.openbsd.org/faq/faq7.html#SerCon Brian Conway RCE Software, LLC
Re: Trouble with console on UART
Hello Brian, Thanks for confirming, I changed in /etc/ttys the line tty00 "/usr/libexec/getty std.9600" unknown off to tty00 "/usr/libexec/getty std.115200" vt220 on secure but get no change. Le 27/01/2024 à 23:56, Brian Conway a écrit : On Sat, Jan 27, 2024, at 8:21 AM, stephane Tranchemer wrote: I said works with stty com4 115200 mach comaddr 0xe060 set tty com4 but not entirely... I indeed get the output of the kernel loading and the system is up, but I don't get a login prompt at the end. Here is a sample of the last lines I get throught console: [...] clearing /tmp kern.securelevel: 0 -> 1 creating runtime link editor directory cache. preserving editor files. starting network daemons: sshd smtpd sndiod. starting local daemons: cron. Sat Jan 27 23:11:02 JST 2024 Something to do with /etc/ttys ? Yes. https://www.openbsd.org/faq/faq7.html#SerCon Brian Conway RCE Software, LLC
Re: Trouble with console on UART
Got it ! I had a hunch so I modified all the tty0X the same way as tty00 to see if someone answers: tty00 "/usr/libexec/getty std.115200" vt220on secure and I got a tty at next reboot. However I find myself on tty04, so it would mean that com4 goes invariably to tty04 even if this port is the only com port I do have on my system as show by dmesg? I would have expected to have it on tty00. I'm all hears if you have a sensible explanation. Le 27/01/2024 à 23:56, Brian Conway a écrit : On Sat, Jan 27, 2024, at 8:21 AM, stephane Tranchemer wrote: I said works with stty com4 115200 mach comaddr 0xe060 set tty com4 but not entirely... I indeed get the output of the kernel loading and the system is up, but I don't get a login prompt at the end. Here is a sample of the last lines I get throught console: [...] clearing /tmp kern.securelevel: 0 -> 1 creating runtime link editor directory cache. preserving editor files. starting network daemons: sshd smtpd sndiod. starting local daemons: cron. Sat Jan 27 23:11:02 JST 2024 Something to do with /etc/ttys ? Yes. https://www.openbsd.org/faq/faq7.html#SerCon Brian Conway RCE Software, LLC
Re: Memory Leak on 7.4 (Stable) with nginx 1.24.0 related to TLS1.3
This should be fixed with https://cvsweb.openbsd.org/src/lib/libssl/tls13_legacy.c#rev1.43 which you should be able to backport to 7.4 without issues if you don't want to use current. The short version is that it is an unfortunate interaction between nginx fiddling with internal state of the library (which it should not be able to but is) and the SSL_shutdown() implementation for the TLSv1.3 stack not reacting as expected.
Re: Trouble with console on UART
On 2024/01/28 00:20, stephane Tranchemer wrote: > Got it ! > > I had a hunch so I modified all the tty0X the same way as tty00 to see if > someone answers: > > tty00 "/usr/libexec/getty std.115200" vt220on secure > > and I got a tty at next reboot. > However I find myself on tty04, so it would mean that com4 goes invariably to > tty04 even if this port is the only com port I do have on my system as show > by dmesg? > I would have expected to have it on tty00. on amd64/i386, 00 to 03 are reserved for serial ports at specific known addresses (0x3f8, 0x3e8, 0x2f8, 0x2e8). dynamically attached ports have higher numbers.
Re: OpenBSD 7.4/amd64 on APU4D4 - kernel panic
On 2024/01/27 10:36, Radek wrote: > but it doesn't work for another APC UPS hardware > uhidev0 at uhub0 port 3 configuration 1 interface 0 "American Power > Conversion Smart-UPS 2200 FW:UPS 09.3 / ID=18" rev 2.00/1.06 addr 2 ... > > > On 2024-01-19 13:21, Stuart Henderson wrote: > > > > ...actually, maybe it needs to be "disable uhidev". ^^
Re: Trouble with console on UART
Mark, On Sat, Jan 27, 2024 at 03:05:10PM +0100, Mark Kettenis wrote: > > Date: Sat, 27 Jan 2024 22:47:05 +0900 > > From: stephane Tranchemer > > > > Hello Jonathan, > > > > made a kernel with the patch and here is what I get on dmesg: > > > > puc0 at pci0 dev 26 function 0 "Intel C3000 UART" rev 0x11: ports: 16 com > > com4 at puc0 port 0 apic 2 int 16: ns16550a, 16 byte fifo > > > > so now it seems to get the com port, however when I type "set tty com4" > > on the boot prompt I get the same result than before, the system freezes > > (or more accurately the input/output goes into the limbo). > > > > I am missing something here ? > > Try typing "mach comaddr 0xe060" before "set tty com4". > How did you know that address to specify? -- Regards, Mikolaj
Re: TSO em(4) problem
On Sat, Jan 27, 2024 at 08:01:09AM +0100, Hrvoje Popovski wrote: > On 26.1.2024. 21:56, Marcus Glocker wrote: > > On Fri, Jan 26, 2024 at 11:41:49AM +0100, Hrvoje Popovski wrote: > > > >> I've manage to reproduce TSO em problem on anoter setup, unfortunatly > >> production. > >> > >> Setup is very simple > >> > >> em0 - carp <- uplink > >> em1 - pfsync > >> ix1 - vlans - carp > > > > Would it be possible that you also share an "ifconfig -a hwfeatures" of > > that box? You can mask the IPs if it's too sensitive. > > > > I still try to reproduce the issue here, and for now I can't. > > Maybe in your full ifconfig output I can see some specifics about your > > configuration, which makes it more likely to reproduce the issue here. > > > > Hi, > > here's ifconfig from second setup where watchdog is triggered much faster. > Originally in this setup uplink is ix0, I've change that to em0 to see > would the problem be same as in other setup and it is, and that's good > because this is pfsync setup for students and I can do whatever I want > with it :) Thanks. But still, I can do whatever I want on my em(4) I210 box, carp(4), vlan(4), creating a lot of traffic, I can't reproduce the watchdog which you are seeing :-( I'm not sure if this is something related to your I350. Also, I can't understand why the watchdog still triggers when you disable TSO by setting net.inet.tcp.tso=0. Just to rule out that you're receiving a MAXMCLBYTES (65536) packet, while EM_TSO_SIZE (65535) is one byte less, can you please apply this diff to -current and test it? I doubt it will make a difference, but I'm running a bit out of ideas here. Index: if_em.c === RCS file: /cvs/src/sys/dev/pci/if_em.c,v diff -u -p -u -p -r1.370 if_em.c --- if_em.c 31 Dec 2023 08:42:33 - 1.370 +++ if_em.c 20 Jan 2024 21:16:57 - @@ -2257,7 +2257,7 @@ em_setup_transmit_structures(struct em_s for (i = 0; i < sc->sc_tx_slots; i++) { pkt = &que->tx.sc_tx_pkts_ring[i]; - error = bus_dmamap_create(sc->sc_dmat, EM_TSO_SIZE, + error = bus_dmamap_create(sc->sc_dmat, MAXMCLBYTES, EM_MAX_SCATTER / (sc->pcix_82544 ? 2 : 1), EM_TSO_SEG_SIZE, 0, BUS_DMA_NOWAIT, &pkt->pkt_map); if (error != 0) {
Re: Trouble with console on UART
> Date: Sat, 27 Jan 2024 18:49:02 + > From: Mikolaj Kucharski > > Mark, > > On Sat, Jan 27, 2024 at 03:05:10PM +0100, Mark Kettenis wrote: > > > Date: Sat, 27 Jan 2024 22:47:05 +0900 > > > From: stephane Tranchemer > > > > > > Hello Jonathan, > > > > > > made a kernel with the patch and here is what I get on dmesg: > > > > > > puc0 at pci0 dev 26 function 0 "Intel C3000 UART" rev 0x11: ports: 16 com > > > com4 at puc0 port 0 apic 2 int 16: ns16550a, 16 byte fifo > > > > > > so now it seems to get the com port, however when I type "set tty com4" > > > on the boot prompt I get the same result than before, the system freezes > > > (or more accurately the input/output goes into the limbo). > > > > > > I am missing something here ? > > > > Try typing "mach comaddr 0xe060" before "set tty com4". > > > > How did you know that address to specify? >From pcidump output the OP sent me.
Re: TSO em(4) problem
On 27.1.2024. 21:01, Marcus Glocker wrote: > On Sat, Jan 27, 2024 at 08:01:09AM +0100, Hrvoje Popovski wrote: > >> On 26.1.2024. 21:56, Marcus Glocker wrote: >>> On Fri, Jan 26, 2024 at 11:41:49AM +0100, Hrvoje Popovski wrote: >>> I've manage to reproduce TSO em problem on anoter setup, unfortunatly production. Setup is very simple em0 - carp <- uplink em1 - pfsync ix1 - vlans - carp >>> Would it be possible that you also share an "ifconfig -a hwfeatures" of >>> that box? You can mask the IPs if it's too sensitive. >>> >>> I still try to reproduce the issue here, and for now I can't. >>> Maybe in your full ifconfig output I can see some specifics about your >>> configuration, which makes it more likely to reproduce the issue here. >>> >> Hi, >> >> here's ifconfig from second setup where watchdog is triggered much faster. >> Originally in this setup uplink is ix0, I've change that to em0 to see >> would the problem be same as in other setup and it is, and that's good >> because this is pfsync setup for students and I can do whatever I want >> with it :) > Thanks. > > But still, I can do whatever I want on my em(4) I210 box, carp(4), > vlan(4), creating a lot of traffic, I can't reproduce the watchdog which > you are seeing :-( I'm not sure if this is something related to your > I350. > > Also, I can't understand why the watchdog still triggers when you disable > TSO by setting net.inet.tcp.tso=0. > > Just to rule out that you're receiving a MAXMCLBYTES (65536) packet, > while EM_TSO_SIZE (65535) is one byte less, can you please apply this > diff to -current and test it? I doubt it will make a difference, but > I'm running a bit out of ideas here. Hi, with this diff I'm still getting em watchdog Jan 28 00:14:12 bcbnfw1 /bsd: em0: watchdog: head 120 tail 185 TDH 185 TDT 120
Re: Trouble with console on UART
On Sun, Jan 28, 2024 at 10:46:43AM +0900, Tranchemer Stéphane wrote: > Thanks so much for this very clear explanation, I didn’t know that one. > > I have a question regarding the patch I successfully applied on the kernel, > could such modification be accepted as a syspatch in the actual 7.4 release > or should it be expected in CURRENT and planned for the next to come 7.5 > release? I have committed it to -current, so it will be in 7.5. Hardware support changes don't normally get backported to stable branches. > > Also Mark, I honestly would have never found myself the "mach comaddr 0xe060" > option to set at boot, is it something that there’s no other way than set it > yourself or could it be part of a patch to set up automatically? the line can be placed in /etc/boot.conf commands are described in boot(8) > > Thank you all. > > > > > Le 2024/01/28 à 03:46, Stuart Henderson a écrit : > > > > On 2024/01/28 00:20, stephane Tranchemer wrote: > >> Got it ! > >> I had a hunch so I modified all the tty0X the same way as tty00 to see if > >> someone answers: > >> tty00 "/usr/libexec/getty std.115200" vt220on secure > >> and I got a tty at next reboot. > >> However I find myself on tty04, so it would mean that com4 goes invariably > >> to tty04 even if this port is the only com port I do have on my system as > >> show by dmesg? > >> I would have expected to have it on tty00. > > > > on amd64/i386, 00 to 03 are reserved for serial ports at specific known > > addresses (0x3f8, 0x3e8, 0x2f8, 0x2e8). dynamically attached ports have > > higher numbers. >
Re: Trouble with console on UART
Thanks so much for this very clear explanation, I didn’t know that one. I have a question regarding the patch I successfully applied on the kernel, could such modification be accepted as a syspatch in the actual 7.4 release or should it be expected in CURRENT and planned for the next to come 7.5 release? Also Mark, I honestly would have never found myself the "mach comaddr 0xe060" option to set at boot, is it something that there’s no other way than set it yourself or could it be part of a patch to set up automatically? Thank you all. > > Le 2024/01/28 à 03:46, Stuart Henderson a écrit : > > On 2024/01/28 00:20, stephane Tranchemer wrote: >> Got it ! >> I had a hunch so I modified all the tty0X the same way as tty00 to see if >> someone answers: >> tty00 "/usr/libexec/getty std.115200" vt220on secure >> and I got a tty at next reboot. >> However I find myself on tty04, so it would mean that com4 goes invariably >> to tty04 even if this port is the only com port I do have on my system as >> show by dmesg? >> I would have expected to have it on tty00. > > on amd64/i386, 00 to 03 are reserved for serial ports at specific known > addresses (0x3f8, 0x3e8, 0x2f8, 0x2e8). dynamically attached ports have > higher numbers.