Issues installing OpenBSD 7.7 on FW13-AMD-AI-370

wondering if anyone has tried to install OpenBSD 7.7, i encountered what i believe to be a driver issue with an output of “panic: aml_die aml_convert:2094 \n the operating system has halted. \n please press any key to reboot.”. and hitting just an infinite loop of being requested to press a key to reboot. i believe it’s an i/o apic but i couldn’t find any toggle to shut that off. happy to post the error report but figured i’d just throw this question out there first. i believe openbsd added support for the cpu though with the latest 7.7 version.

happy to have joined the framework community in any case.

Same machine, same problem here. I was able to avoid the panic with the disable acpi kernel option (run boot -c on startup to be able to set options, see boot_config(8)). Unfortunately, that only led me to a second problem where the keyboard repeats each key exactly seven times each time a key is pressed. I tried a workaround, but no luck. Accordingly, I’ve been unable to install thus far.

If time allows, and if no one else gets to it first, I’ll attempt to look into the issues in the coming weeks. OpenBSD is not my forte though. If nothing else, I should send a proper report to the appropriate mailing list.

i see, i’ll give that a try with boot_config. i submitted a report yesterday to Framework to let them know. happy to collaborate on this issue!

Hi there! I got the laptop yesterday and naturally ran into this as well. Since my C is pretty decent and I’ve done some OpenBSD kernel debugging in the past, I couldn’t help but have a look. It’s a subtle bug in the ACPI driver. The TLDR is that it’s missing an implicit type conversion. Here’s my report to bugs@:

I’ve got my machine to boot, so a patch to tech@ is coming.

2 Likes

thank you so much!! i was going to write up an OpenBSD bug report. unfortunately a cold and fever got in the way. will be following attentively!

Patch posted. I’ll include it here for convenience.

Index: dev/acpi/dsdt.c
===================================================================
RCS file: /cvs/src/sys/dev/acpi/dsdt.c,v
retrieving revision 1.274
diff -u -p -r1.274 dsdt.c
--- dev/acpi/dsdt.c	22 Mar 2025 18:14:37 -0000	1.274
+++ dev/acpi/dsdt.c	6 Jun 2025 22:16:44 -0000
@@ -1753,6 +1753,7 @@ struct aml_scope *aml_pushscope(struct a
 struct aml_scope *aml_popscope(struct aml_scope *);
 
 void		aml_showstack(struct aml_scope *);
+struct aml_value *aml_tryconv(struct aml_value *, int, int);
 struct aml_value *aml_convert(struct aml_value *, int, int);
 
 int		aml_matchtest(int64_t, int64_t, int);
@@ -1766,6 +1767,8 @@ int		aml_ccrlen(int, union acpi_resource
 
 void		aml_store(struct aml_scope *, struct aml_value *, int64_t,
     struct aml_value *);
+void		aml_rwfield(struct aml_value *, int, int, struct aml_value *,
+    int);
 
 /*
  * Reference Count functions
@@ -2022,7 +2025,7 @@ aml_hextoint(const char *str)
 }
 
 struct aml_value *
-aml_convert(struct aml_value *a, int ctype, int clen)
+aml_tryconv(struct aml_value *a, int ctype, int clen)
 {
 	struct aml_value *c = NULL;
 
@@ -2045,6 +2048,11 @@ aml_convert(struct aml_value *a, int cty
 			c = aml_allocvalue(AML_OBJTYPE_BUFFER, a->length,
 			    a->v_string);
 			break;
+		case AML_OBJTYPE_BUFFERFIELD:
+		case AML_OBJTYPE_FIELDUNIT:
+			c = aml_allocvalue(AML_OBJTYPE_BUFFER, 0, NULL);
+			aml_rwfield(a, 0, a->v_field.bitlen, c, ACPI_IOREAD);
+			break;
 		}
 		break;
 	case AML_OBJTYPE_INTEGER:
@@ -2062,6 +2070,13 @@ aml_convert(struct aml_value *a, int cty
 		case AML_OBJTYPE_UNINITIALIZED:
 			c = aml_allocvalue(AML_OBJTYPE_INTEGER, 0, NULL);
 			break;
+		case AML_OBJTYPE_BUFFERFIELD:
+		case AML_OBJTYPE_FIELDUNIT:
+			if (a->v_field.bitlen > aml_intlen)
+				break;
+			c = aml_allocvalue(AML_OBJTYPE_INTEGER, 0, NULL);
+			aml_rwfield(a, 0, a->v_field.bitlen, c, ACPI_IOREAD);
+			break;
 		}
 		break;
 	case AML_OBJTYPE_STRING:
@@ -2087,7 +2102,15 @@ aml_convert(struct aml_value *a, int cty
 		}
 		break;
 	}
-	if (c == NULL) {
+	return c;
+}
+
+struct aml_value *
+aml_convert(struct aml_value *a, int ctype, int clen)
+{
+	struct aml_value *c;
+
+	if ((c = aml_tryconv(a, ctype, clen)) == NULL) {
 #ifndef SMALL_KERNEL
 		aml_showvalue(a);
 #endif
@@ -2099,8 +2122,26 @@ aml_convert(struct aml_value *a, int cty
 int
 aml_compare(struct aml_value *a1, struct aml_value *a2, int opcode)
 {
+	struct aml_value *cv;		/* value after conversion */
 	int rc = 0;
 
+	/*
+	 * Convert A1 to integer, string, or buffer.
+	 *
+	 * The possible conversions listed in Table 19.6 of the ACPI spec
+	 * imply that unless we already got one of the three supported types,
+	 * the conversion must be from field unit or buffer field. In both
+	 * cases, the rules (Table 19.7) state that we should convert to
+	 * integer if possible with buffer as a fallback.
+	 */
+	if (a1->type != AML_OBJTYPE_INTEGER && a1->type != AML_OBJTYPE_STRING
+	    && a1->type != AML_OBJTYPE_BUFFER) {
+		cv = aml_tryconv(a1, AML_OBJTYPE_INTEGER, -1);
+		if (cv == NULL)
+			cv = aml_convert(a1, AML_OBJTYPE_BUFFER, -1);
+		a1 = cv;
+	}
+
 	/* Convert A2 to type of A1 */
 	a2 = aml_convert(a2, a1->type, -1);
 	if (a1->type == AML_OBJTYPE_INTEGER)
@@ -2127,6 +2168,14 @@ aml_concat(struct aml_value *a1, struct 
 {
 	struct aml_value *c = NULL;
 
+	/*
+	 * Make A1 an integer, string, or buffer. Unless we already got one
+	 * of these three types, convert to string.
+	 */
+	if (a1->type != AML_OBJTYPE_INTEGER && a1->type != AML_OBJTYPE_STRING
+	    && a1->type != AML_OBJTYPE_BUFFER)
+		a1 = aml_convert(a1, AML_OBJTYPE_STRING, -1);
+
 	/* Convert arg2 to type of arg1 */
 	a2 = aml_convert(a2, a1->type, -1);
 	switch (a1->type) {
@@ -2292,7 +2341,6 @@ void aml_rwgen(struct aml_value *, int, 
 void aml_rwgpio(struct aml_value *, int, int, struct aml_value *, int, int);
 void aml_rwgsb(struct aml_value *, int, int, int, struct aml_value *, int, int);
 void aml_rwindexfield(struct aml_value *, struct aml_value *val, int);
-void aml_rwfield(struct aml_value *, int, int, struct aml_value *, int);
 
 /* Get PCI address for opregion objects */
 int
1 Like

thanks a lot! i imagine they’ll incorporate the patch into the file sets soon!

Thank you so much for taking the time to look into this! I haven’t had a chance to use the laptop at all this past week, so I’m glad someone else was able to step up. Really, thank you.

Do you have the same keyboard issue I mentioned (repeating keys) after boot, or does this patch solve that issue as well?

It should resolve that, because it is tangential.

As far as I understand, several makes of laptops needlessly emulate a legacy keyboard using the wrong (i.e. modern) signaling, level-triggered vs. edge-triggered. Here is the relevant post where I read it: 'chromebook keyboards' - MARC

The workaround is to prioritice attaching the keyboard driver via ACPI rather than legacy. But if you disable acpi…

For reference, the workaround seems to have landed in OpenBSD in February: 'Re: return of the chromebook keyboard diff' - MARC

PS: Since these mails explicitly mention Chromebooks, I wonder if this misbehavior is in our (Framework) EC, inherited from ChromeOS.

FYI, there is another issue that can cause the system to hang on shutdown out of a running X session. Seems related to switching consoles. As a workround, log out of the session first and press the power button on the xenodm login screen.