t945s hangs on ttyflags -a

2024-03-31 Thread Landry Breuil
hi,

istr this has been discussed/fixed at some point and it used to work
last year, but the t495s i have here on -current hangs at ttyflags -a in
/etc/rc, commenting it again allows boot to succeed.

dmesg attached with -current. i dont boot that machine often enough, so
the regression window is .. large.. guess i'll try bisecting.

last known working: #1463: Wed Nov 22 21:13:03 MST 2023.
OpenBSD 7.5-current (RAMDISK_CD) #1: Sat Mar 30 06:11:20 MDT 2024
dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/RAMDISK_CD
real mem = 14860877824 (14172MB)
avail mem = 14406131712 (13738MB)
random: good seed from bootblocks
mainbus0 at root
bios0 at mainbus0: SMBIOS rev. 3.1 @ 0xb9eaa000 (62 entries)
bios0: vendor LENOVO version "R13ET54W(1.28 )" date 01/12/2023
bios0: LENOVO 20QJCTO1WW
acpi0 at bios0: ACPI 5.0
acpi0: tables DSDT FACP SSDT SSDT SSDT TPM2 SSDT MSDM SLIC BATB HPET APIC MCFG 
SBST WSMT IVRS SSDT CRAT CDIT FPDT SSDT SSDT SSDT UEFI SSDT
acpihpet0 at acpi0: 14318180 Hz
acpimadt0 at acpi0 addr 0xfee0: PC-AT compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: AMD Ryzen 7 PRO 3700U w/ Radeon Vega Mobile Gfx, 2300.00 MHz, 17-18-01, 
patch 08108109
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,FMA3,CX16,SSE4.1,SSE4.2,MOVBE,POPCNT,AES,XSAVE,AVX,F16C,RDRAND,NXE,MMXX,FFXSR,PAGE1GB,RDTSCP,LONG,LAHF,CMPLEG,SVM,EAPICSP,AMCR8,ABM,SSE4A,MASSE,3DNOWP,OSVW,SKINIT,TCE,TOPEXT,CPCTR,DBKP,PCTRL3,MWAITX,HWPSTATE,ITSC,FSGSBASE,BMI1,AVX2,SMEP,BMI2,RDSEED,ADX,SMAP,CLFLUSHOPT,SHA,IBPB,XSAVEOPT,XSAVEC,XGETBV1,XSAVES
cpu0: 32KB 64b/line 8-way D-cache, 64KB 64b/line 4-way I-cache, 512KB 64b/line 
8-way L2 cache, 4MB 64b/line 16-way L3 cache
cpu0: apic clock running at 25MHz
cpu0: mwait min=64, max=64, C-substates=1.1, IBE
cpu at mainbus0: not configured
cpu at mainbus0: not configured
cpu at mainbus0: not configured
cpu at mainbus0: not configured
cpu at mainbus0: not configured
cpu at mainbus0: not configured
cpu at mainbus0: not configured
ioapic0 at mainbus0: apid 32 pa 0xfec0, version 21, 24 pins, can't remap
ioapic1 at mainbus0: apid 33 pa 0xfec01000, version 21, 32 pins, can't remap
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus -1 (GPP0)
acpiprt2 at acpi0: bus 1 (GPP1)
acpiprt3 at acpi0: bus 2 (GPP2)
acpiprt4 at acpi0: bus 3 (GPP3)
acpiprt5 at acpi0: bus -1 (GPP4)
acpiprt6 at acpi0: bus -1 (GPP5)
acpiprt7 at acpi0: bus 4 (GPP6)
acpiprt8 at acpi0: bus 5 (GP17)
acpiprt9 at acpi0: bus -1 (GP18)
acpiec0 at acpi0
"PNP0C0C" at acpi0 not configured
acpipci0 at acpi0 PCI0: 0x0010 0x0011 0x
acpicmos0 at acpi0
"PNP0C0A" at acpi0 not configured
"ACPI0003" at acpi0 not configured
"LEN0268" at acpi0 not configured
"SMB0001" at acpi0 not configured
"PNP0C14" at acpi0 not configured
"PNP0C0D" at acpi0 not configured
"PNP0C0E" at acpi0 not configured
"PNP0C14" at acpi0 not configured
"PNP0C14" at acpi0 not configured
"PNP0C14" at acpi0 not configured
amdgpio0 at acpi0 GPIO uid 0 addr 0xfed81500/0x400 irq 9, 184 pins
"USBC000" at acpi0 not configured
"STM7308" at acpi0 not configured
"PNP0C14" at acpi0 not configured
acpicpu at acpi0 not configured
acpipwrres at acpi0 not configured
acpipwrres at acpi0 not configured
pci0 at mainbus0 bus 0
pchb0 at pci0 dev 0 function 0 "AMD 17h/1xh Root Complex" rev 0x00
"AMD 17h/1xh IOMMU" rev 0x00 at pci0 dev 0 function 2 not configured
pchb1 at pci0 dev 1 function 0 "AMD 17h PCIE" rev 0x00
ppb0 at pci0 dev 1 function 2 "AMD 17h/1xh PCIE" rev 0x00: msi
pci1 at ppb0 bus 1
iwm0 at pci1 dev 0 function 0 "Intel Dual Band Wireless-AC 9260" rev 0x29, msix
ppb1 at pci0 dev 1 function 3 "AMD 17h/1xh PCIE" rev 0x00: msi
pci2 at ppb1 bus 2
nvme0 at pci2 dev 0 function 0 "Samsung SM981/PM981 NVMe" rev 0x00: msix, NVMe 
1.3
nvme0: SAMSUNG MZVLB1T0HBLR-000L7, firmware 4M2QEXF7, serial S4EMNX0N762169
scsibus0 at nvme0: 2 targets, initiator 0
sd0 at scsibus0 targ 1 lun 0: 
sd0: 976762MB, 512 bytes/sector, 2000409264 sectors
ppb2 at pci0 dev 1 function 4 "AMD 17h/1xh PCIE" rev 0x00: msi
pci3 at ppb2 bus 3
re0 at pci3 dev 0 function 0 "Realtek 8168" rev 0x0e: RTL8168EP/8111EP 
(0x5000), msi, address 00:2b:67:e6:c7:83
rgephy0 at re0 phy 7: RTL8251 PHY, rev. 0
"Realtek RealManage Serial" rev 0x0e at pci3 dev 0 function 1 not configured
"Realtek RealManage Serial" rev 0x0e at pci3 dev 0 function 2 not configured
"Realtek RealManage IPMI" rev 0x0e at pci3 dev 0 function 3 not configured
ehci0 at pci3 dev 0 function 4 "Realtek RealManage USB" rev 0x0e: apic 33 int 15
ehci0: pre-2.0 USB rev
ppb3 at pci0 dev 1 function 7 "AMD 17h/1xh PCIE" rev 0x00: msi
pci4 at ppb3 bus 4
rtsx0 at pci4 dev 0 function 0 "Realtek RTS522A Card Reader" rev 0x01: msi
sdmmc0 at rtsx0: 4-bit, dma
pchb2 at pci0 dev 8 function 0 "AMD 17h PCIE" rev 0x00
ppb4 at pci0 dev 8 function 1 "AMD 17h/1xh PCIE" rev 0x00
pci5 at ppb4 bus 5
"ATI Picasso" rev 0xd1 at pci5 dev 0 function 0 not configured
"ATI Radeon Vega HD Audio" rev 0x00

Re: t945s hangs on ttyflags -a

2024-03-31 Thread Landry Breuil
Le Sun, Mar 31, 2024 at 09:30:05AM +0200, Landry Breuil a écrit :
> hi,
> 
> istr this has been discussed/fixed at some point and it used to work
> last year, but the t495s i have here on -current hangs at ttyflags -a in
> /etc/rc, commenting it again allows boot to succeed.
> 
> dmesg attached with -current. i dont boot that machine often enough, so
> the regression window is .. large.. guess i'll try bisecting.
> 
> last known working: #1463: Wed Nov 22 21:13:03 MST 2023.

after bisecting a bit, i'm puzzled because it seems ttyflags -a hangs
only happen when a spurious com0 is found in dmesg:

com0 at isa0 port 0x3f8/8 irq 4: ns16550a, 16 byte fifo
com0: probed fifo depth: 0 bytes

but that device isnt present in the working boots from various kernel
versions (tried kernels from end of december to 1 feb so far)

it's enough to test with boot -s and ttyflags -a, i think i triggered it
once with a kernel from #1587: Sat Dec 30 22:44:51 MST 2023, next boots
on the same kernel were okay..

I've tried differentiating cold boots vs reboots, but that didn't help.

Landry



M2 Pro 2023 works, but stuck with our apple-boot firmware

2024-03-31 Thread Klemens Nanni
Default snapshot install works with the intial UEFI/u-boot from macOS/Asahi.

After manual fw_update(8) via urndis(4) tethering to install apple-boot-1.2
and cold reboot, it still boots the initial UEFI/u-boot and works.

Once I run sysupgrade(8), after the upgrade the boot firmware is switched to
our apple-boot (visible via tobhe's OpenBSD logo) which gets stuck before
reaching our bootloader.

First time using Apple silicon, so I don't have a clue yet what's going on.

Loose transcription, picture attached.

  Chip-ID: 0x6020

OS FW version: 13.5 (iBoot-8422.141.2)
System FW version: unknown (iBoot 10151.101.3)
[...]
Initialization complete.
Cechking for payloads...
Devicetree compatible value: apple,j416s
Found a gzip compressed payload at 0x100041dc200
Uncompressing... 272386 bytes uncompressed to 562704 bytes
Found a kernel at 0x10006a0
Found a variable at 0x1000421ea02: chosen.asahi,efi-system-partition=...
No more payloads at 0x1000421ea19
ERROR: Kernel found but not devicetree for apple,j416s available.
No valid payload found
dart: dart /arm-io/dart-usb0 at 0x... is a t8110
USB0: initialized at 0x...
[same for USB1/2]
Runnig proxy...


Below dmesg is from a previous install (with root on softraid).

OpenBSD 7.5-current (GENERIC.MP) #139: Sat Mar 30 11:13:12 MDT 2024
dera...@arm64.openbsd.org:/usr/src/sys/arch/arm64/compile/GENERIC.MP
real mem  = 33464909824 (31914MB)
avail mem = 32294658048 (30798MB)
random: good seed from bootblocks
mainbus0 at root: Apple MacBook Pro (16-inch, M2 Pro, 2023)
efi0 at mainbus0: UEFI 2.10
efi0: Das U-Boot rev 0x20230700
cpu0 at mainbus0 mpidr 0: Apple Blizzard Pro r1p0
cpu0: 128KB 64b/line 4-way L1 PIPT I-cache, 64KB 64b/line 8-way L1 D-cache
cpu0: 4096KB 128b/line 16-way L2 cache
cpu0: 
TLBIOS+IRANGE,TS+AXFLAG,FHM,DP,SHA3,RDM,Atomic,CRC32,SHA2+SHA512,SHA1,AES+PMULL,SPECRES,SB,FRINTTS,GPI,LRCPC+LDAPUR,FCMA,JSCVT,API+PAC,DPB,SpecSEI,PAN+ATS1E1,LO,HPDS,VH,CSV3,CSV2,DIT,BT,SSBS+MSR
cpu1 at mainbus0 mpidr 1: Apple Blizzard Pro r1p0
cpu1: 128KB 64b/line 4-way L1 PIPT I-cache, 64KB 64b/line 8-way L1 D-cache
cpu1: 4096KB 128b/line 16-way L2 cache
cpu2 at mainbus0 mpidr 2: Apple Blizzard Pro r1p0
cpu2: 128KB 64b/line 4-way L1 PIPT I-cache, 64KB 64b/line 8-way L1 D-cache
cpu2: 4096KB 128b/line 16-way L2 cache
cpu3 at mainbus0 mpidr 3: Apple Blizzard Pro r1p0
cpu3: 128KB 64b/line 4-way L1 PIPT I-cache, 64KB 64b/line 8-way L1 D-cache
cpu3: 4096KB 128b/line 16-way L2 cache
cpu4 at mainbus0 mpidr 10100: Apple Avalanche Pro r1p0
cpu4: 192KB 64b/line 6-way L1 PIPT I-cache, 128KB 64b/line 8-way L1 D-cache
cpu4: 16384KB 128b/line 16-way L2 cache
cpu5 at mainbus0 mpidr 10101: Apple Avalanche Pro r1p0
cpu5: 192KB 64b/line 6-way L1 PIPT I-cache, 128KB 64b/line 8-way L1 D-cache
cpu5: 16384KB 128b/line 16-way L2 cache
cpu6 at mainbus0 mpidr 10102: Apple Avalanche Pro r1p0
cpu6: 192KB 64b/line 6-way L1 PIPT I-cache, 128KB 64b/line 8-way L1 D-cache
cpu6: 16384KB 128b/line 16-way L2 cache
cpu7 at mainbus0 mpidr 10103: Apple Avalanche Pro r1p0
cpu7: 192KB 64b/line 6-way L1 PIPT I-cache, 128KB 64b/line 8-way L1 D-cache
cpu7: 16384KB 128b/line 16-way L2 cache
cpu8 at mainbus0 mpidr 10200: Apple Avalanche Pro r1p0
cpu8: 192KB 64b/line 6-way L1 PIPT I-cache, 128KB 64b/line 8-way L1 D-cache
cpu8: 16384KB 128b/line 16-way L2 cache
cpu9 at mainbus0 mpidr 10201: Apple Avalanche Pro r1p0
cpu9: 192KB 64b/line 6-way L1 PIPT I-cache, 128KB 64b/line 8-way L1 D-cache
cpu9: 16384KB 128b/line 16-way L2 cache
cpu10 at mainbus0 mpidr 10202: Apple Avalanche Pro r1p0
cpu10: 192KB 64b/line 6-way L1 PIPT I-cache, 128KB 64b/line 8-way L1 D-cache
cpu10: 16384KB 128b/line 16-way L2 cache
cpu11 at mainbus0 mpidr 10203: Apple Avalanche Pro r1p0
cpu11: 192KB 64b/line 6-way L1 PIPT I-cache, 128KB 64b/line 8-way L1 D-cache
cpu11: 16384KB 128b/line 16-way L2 cache
"asc-firmware" at mainbus0 not configured
"asc-firmware" at mainbus0 not configured
"framebuffer" at mainbus0 not configured
"asc-firmware" at mainbus0 not configured
"asc-firmware" at mainbus0 not configured
"region157" at mainbus0 not configured
"region95" at mainbus0 not configured
"region94" at mainbus0 not configured
"region57" at mainbus0 not configured
"dcp_data" at mainbus0 not configured
"asc-firmware" at mainbus0 not configured
"uat-handoff" at mainbus0 not configured
"uat-pagetables" at mainbus0 not configured
"uat-ttbs" at mainbus0 not configured
"isp-heap" at mainbus0 not configured
apm0 at mainbus0
"opp-table-0" at mainbus0 not configured
"opp-table-1" at mainbus0 not configured
"opp-table-gpu" at mainbus0 not configured
"opp-table-gpu-cs" at mainbus0 not configured
"opp-table-gpu-afr" at mainbus0 not configured
"pmu-e" at mainbus0 not configured
"pmu-p" at mainbus0 not configured
agtimer0 at mainbus0: 24000 kHz
"clock-ref" at mainbus0 not configured
"clock-200m" at mainbus0 not configured
"clock-dis

Re: M2 Pro 2023 works, but stuck with our apple-boot firmware

2024-03-31 Thread Mark Kettenis
> Date: Sun, 31 Mar 2024 13:23:41 +
> From: Klemens Nanni 
> 
> Default snapshot install works with the intial UEFI/u-boot from macOS/Asahi.
> 
> After manual fw_update(8) via urndis(4) tethering to install apple-boot-1.2
> and cold reboot, it still boots the initial UEFI/u-boot and works.
> 
> Once I run sysupgrade(8), after the upgrade the boot firmware is switched to
> our apple-boot (visible via tobhe's OpenBSD logo) which gets stuck before
> reaching our bootloader.
> 
> First time using Apple silicon, so I don't have a clue yet what's going on.
> 
> Loose transcription, picture attached.
> 
> Chip-ID: 0x6020
> 
>   OS FW version: 13.5 (iBoot-8422.141.2)
>   System FW version: unknown (iBoot 10151.101.3)
>   [...]
>   Initialization complete.
>   Cechking for payloads...
>   Devicetree compatible value: apple,j416s
>   Found a gzip compressed payload at 0x100041dc200
>   Uncompressing... 272386 bytes uncompressed to 562704 bytes
>   Found a kernel at 0x10006a0
>   Found a variable at 0x1000421ea02: chosen.asahi,efi-system-partition=...
>   No more payloads at 0x1000421ea19
>   ERROR: Kernel found but not devicetree for apple,j416s available.

Looks like I missed hooking up the devicetree for your model to the
build.  Instead I added apple,j414s twice :(.

Looks like the last PLIST updated was botched as well.

Diff below should fix things.  Stuart, what are the chances of
updating the firmware for the release?


Index: sysutils/u-boot-asahi/Makefile
===
RCS file: /cvs/ports/sysutils/u-boot-asahi/Makefile,v
retrieving revision 1.15
diff -u -p -r1.15 Makefile
--- sysutils/u-boot-asahi/Makefile  8 Jan 2024 19:59:11 -   1.15
+++ sysutils/u-boot-asahi/Makefile  31 Mar 2024 16:15:34 -
@@ -6,6 +6,7 @@ VERSION=2024.01
 GH_ACCOUNT=AsahiLinux
 GH_PROJECT=u-boot
 GH_TAGNAME=openbsd-v${VERSION}
+REVISION=  0
 
 PKGNAME=   u-boot-asahi-${VERSION:S/-/./g}
 
Index: sysutils/u-boot-asahi/patches/patch-arch_arm_dts_Makefile
===
RCS file: sysutils/u-boot-asahi/patches/patch-arch_arm_dts_Makefile
diff -N sysutils/u-boot-asahi/patches/patch-arch_arm_dts_Makefile
--- /dev/null   1 Jan 1970 00:00:00 -
+++ sysutils/u-boot-asahi/patches/patch-arch_arm_dts_Makefile   31 Mar 2024 
16:15:34 -
@@ -0,0 +1,12 @@
+Index: arch/arm/dts/Makefile
+--- arch/arm/dts/Makefile.orig
 arch/arm/dts/Makefile
+@@ -40,7 +40,7 @@ dtb-$(CONFIG_ARCH_APPLE) += \
+   t6001-j375c.dtb \
+   t6002-j375d.dtb \
+   t6020-j414s.dtb \
+-  t6020-j414s.dtb \
++  t6020-j416s.dtb \
+   t6020-j474s.dtb \
+   t6021-j414c.dtb \
+   t6021-j416c.dtb \
Index: sysutils/u-boot-asahi/pkg/PLIST
===
RCS file: /cvs/ports/sysutils/u-boot-asahi/pkg/PLIST,v
retrieving revision 1.4
diff -u -p -r1.4 PLIST
--- sysutils/u-boot-asahi/pkg/PLIST 3 Dec 2023 22:55:16 -   1.4
+++ sysutils/u-boot-asahi/pkg/PLIST 31 Mar 2024 16:15:34 -
@@ -9,10 +9,13 @@ share/u-boot/apple_m1/dts/t6001-j316c.dt
 share/u-boot/apple_m1/dts/t6001-j375c.dtb
 share/u-boot/apple_m1/dts/t6002-j375d.dtb
 share/u-boot/apple_m1/dts/t6020-j414s.dtb
+share/u-boot/apple_m1/dts/t6020-j416s.dtb
 share/u-boot/apple_m1/dts/t6020-j474s.dtb
 share/u-boot/apple_m1/dts/t6021-j414c.dtb
 share/u-boot/apple_m1/dts/t6021-j416c.dtb
+share/u-boot/apple_m1/dts/t6021-j475c.dtb
 share/u-boot/apple_m1/dts/t6022-j180d.dtb
+share/u-boot/apple_m1/dts/t6022-j475d.dtb
 share/u-boot/apple_m1/dts/t8103-j274.dtb
 share/u-boot/apple_m1/dts/t8103-j293.dtb
 share/u-boot/apple_m1/dts/t8103-j313.dtb
Index: sysutils/firmware/apple-boot/Makefile
===
RCS file: /cvs/ports/sysutils/firmware/apple-boot/Makefile,v
retrieving revision 1.16
diff -u -p -r1.16 Makefile
--- sysutils/firmware/apple-boot/Makefile   8 Jan 2024 20:00:31 -   
1.16
+++ sysutils/firmware/apple-boot/Makefile   31 Mar 2024 16:15:34 -
@@ -1,5 +1,5 @@
 FW_DRIVER= apple-boot
-FW_VER=1.2
+FW_VER=1.3
 
 WRKDIST=   ${WRKDIR}
 DISTFILES=
@@ -10,7 +10,7 @@ PERMIT_PACKAGE= firmware
 PERMIT_DISTFILES= Yes
 
 BUILD_DEPENDS= m1n1-=1.4.11:sysutils/m1n1:build \
-   u-boot-asahi-=2024.01:sysutils/u-boot-asahi:build
+   u-boot-asahi-=2024.01p0:sysutils/u-boot-asahi:build
 
 ASAHI_BUILD=   ${WRKSRC}/sysutils/u-boot-asahi/u-boot-*/build
 M1N1_BUILD=${WRKSRC}/sysutils/m1n1/m1n1-*/build



Re: M2 Pro 2023 works, but stuck with our apple-boot firmware

2024-03-31 Thread Klemens Nanni
On Sun, Mar 31, 2024 at 06:18:22PM +0200, Mark Kettenis wrote:
> > Date: Sun, 31 Mar 2024 13:23:41 +
> > From: Klemens Nanni 
> > 
> > Default snapshot install works with the intial UEFI/u-boot from macOS/Asahi.
> > 
> > After manual fw_update(8) via urndis(4) tethering to install apple-boot-1.2
> > and cold reboot, it still boots the initial UEFI/u-boot and works.
> > 
> > Once I run sysupgrade(8), after the upgrade the boot firmware is switched to
> > our apple-boot (visible via tobhe's OpenBSD logo) which gets stuck before
> > reaching our bootloader.
> > 
> > First time using Apple silicon, so I don't have a clue yet what's going on.
> > 
> > Loose transcription, picture attached.
> > 
> >   Chip-ID: 0x6020
> > 
> > OS FW version: 13.5 (iBoot-8422.141.2)
> > System FW version: unknown (iBoot 10151.101.3)
> > [...]
> > Initialization complete.
> > Cechking for payloads...
> > Devicetree compatible value: apple,j416s
> > Found a gzip compressed payload at 0x100041dc200
> > Uncompressing... 272386 bytes uncompressed to 562704 bytes
> > Found a kernel at 0x10006a0
> > Found a variable at 0x1000421ea02: chosen.asahi,efi-system-partition=...
> > No more payloads at 0x1000421ea19
> > ERROR: Kernel found but not devicetree for apple,j416s available.
> 
> Looks like I missed hooking up the devicetree for your model to the
> build.  Instead I added apple,j414s twice :(.
> 
> Looks like the last PLIST updated was botched as well.

That unbreaks my machine, OK kn

I nuked everyting non-macOS and installed again via urndis(4) and bsd.rd
on the EFI Sys partition, which installed -current firmware.  Then at the
final [R]eboot I updated via

# DESTDIR=/mnt /mnt/usr/sbin/fw_update -d apple-boot
# mount /dev/sd0l /mnt2
# DESTDIR=/mnt /mnt/usr/sbin/fw_update /mnt2/apple-boot-firmware-1.3.tgz

first boot after install showed the puffy logo, but with correct resolution,
font size and it made it through to the login: prompt.

Thanks for the quick fix.

> Diff below should fix things.  Stuart, what are the chances of
> updating the firmware for the release?
> 
> 
> Index: sysutils/u-boot-asahi/Makefile
> ===
> RCS file: /cvs/ports/sysutils/u-boot-asahi/Makefile,v
> retrieving revision 1.15
> diff -u -p -r1.15 Makefile
> --- sysutils/u-boot-asahi/Makefile8 Jan 2024 19:59:11 -   1.15
> +++ sysutils/u-boot-asahi/Makefile31 Mar 2024 16:15:34 -
> @@ -6,6 +6,7 @@ VERSION=  2024.01
>  GH_ACCOUNT=  AsahiLinux
>  GH_PROJECT=  u-boot
>  GH_TAGNAME=  openbsd-v${VERSION}
> +REVISION=0
>  
>  PKGNAME= u-boot-asahi-${VERSION:S/-/./g}
>  
> Index: sysutils/u-boot-asahi/patches/patch-arch_arm_dts_Makefile
> ===
> RCS file: sysutils/u-boot-asahi/patches/patch-arch_arm_dts_Makefile
> diff -N sysutils/u-boot-asahi/patches/patch-arch_arm_dts_Makefile
> --- /dev/null 1 Jan 1970 00:00:00 -
> +++ sysutils/u-boot-asahi/patches/patch-arch_arm_dts_Makefile 31 Mar 2024 
> 16:15:34 -
> @@ -0,0 +1,12 @@
> +Index: arch/arm/dts/Makefile
> +--- arch/arm/dts/Makefile.orig
>  arch/arm/dts/Makefile
> +@@ -40,7 +40,7 @@ dtb-$(CONFIG_ARCH_APPLE) += \
> + t6001-j375c.dtb \
> + t6002-j375d.dtb \
> + t6020-j414s.dtb \
> +-t6020-j414s.dtb \
> ++t6020-j416s.dtb \
> + t6020-j474s.dtb \
> + t6021-j414c.dtb \
> + t6021-j416c.dtb \
> Index: sysutils/u-boot-asahi/pkg/PLIST
> ===
> RCS file: /cvs/ports/sysutils/u-boot-asahi/pkg/PLIST,v
> retrieving revision 1.4
> diff -u -p -r1.4 PLIST
> --- sysutils/u-boot-asahi/pkg/PLIST   3 Dec 2023 22:55:16 -   1.4
> +++ sysutils/u-boot-asahi/pkg/PLIST   31 Mar 2024 16:15:34 -
> @@ -9,10 +9,13 @@ share/u-boot/apple_m1/dts/t6001-j316c.dt
>  share/u-boot/apple_m1/dts/t6001-j375c.dtb
>  share/u-boot/apple_m1/dts/t6002-j375d.dtb
>  share/u-boot/apple_m1/dts/t6020-j414s.dtb
> +share/u-boot/apple_m1/dts/t6020-j416s.dtb
>  share/u-boot/apple_m1/dts/t6020-j474s.dtb
>  share/u-boot/apple_m1/dts/t6021-j414c.dtb
>  share/u-boot/apple_m1/dts/t6021-j416c.dtb
> +share/u-boot/apple_m1/dts/t6021-j475c.dtb
>  share/u-boot/apple_m1/dts/t6022-j180d.dtb
> +share/u-boot/apple_m1/dts/t6022-j475d.dtb
>  share/u-boot/apple_m1/dts/t8103-j274.dtb
>  share/u-boot/apple_m1/dts/t8103-j293.dtb
>  share/u-boot/apple_m1/dts/t8103-j313.dtb
> Index: sysutils/firmware/apple-boot/Makefile
> ===
> RCS file: /cvs/ports/sysutils/firmware/apple-boot/Makefile,v
> retrieving revision 1.16
> diff -u -p -r1.16 Makefile
> --- sysutils/firmware/apple-boot/Makefile 8 Jan 2024 20:00:31 -   
> 1.16
> +++ sysutils/firmware/apple-boot/Makefile 31 Mar 2024 16:15:34 -
> @@ -1,5 +1,5 @@
>  FW_DRIVER=   apple-boot
> -FW_VER=  1.2
> +FW_V

Re: t945s hangs on ttyflags -a

2024-03-31 Thread Mark Kettenis
> Date: Sun, 31 Mar 2024 10:47:53 +0200
> From: Landry Breuil 
> 
> Le Sun, Mar 31, 2024 at 09:30:05AM +0200, Landry Breuil a écrit :
> > hi,
> > 
> > istr this has been discussed/fixed at some point and it used to work
> > last year, but the t495s i have here on -current hangs at ttyflags -a in
> > /etc/rc, commenting it again allows boot to succeed.
> > 
> > dmesg attached with -current. i dont boot that machine often enough, so
> > the regression window is .. large.. guess i'll try bisecting.
> > 
> > last known working: #1463: Wed Nov 22 21:13:03 MST 2023.
> 
> after bisecting a bit, i'm puzzled because it seems ttyflags -a hangs
> only happen when a spurious com0 is found in dmesg:
> 
> com0 at isa0 port 0x3f8/8 irq 4: ns16550a, 16 byte fifo
> com0: probed fifo depth: 0 bytes
> 
> but that device isnt present in the working boots from various kernel
> versions (tried kernels from end of december to 1 feb so far)
> 
> it's enough to test with boot -s and ttyflags -a, i think i triggered it
> once with a kernel from #1587: Sat Dec 30 22:44:51 MST 2023, next boots
> on the same kernel were okay..
> 
> I've tried differentiating cold boots vs reboots, but that didn't help.

Bleah.  Those ISA-style probes are not very sophisticated and if
vendors are stupid enough to put something at the same address as the
legacy COM ports, it may be detected as a phantom port.

Maybe we should stop doing the ISA probes on systems where ACPI tells
us there are no legacy devices.  Although I'm not sure if that would
help your system.

Can you send me the files from /var/db/acpi?