debug ACPI to solve sysctl hang


New Member

Messages: 10

I installed the standard FreeBSD 11 on a Dell Latitude 7480 laptop, and got the same problem of . sysctl -a hangs after the line
hw.acpi.battery.units: 1
Unfortunately on this latest business laptop, disabling ACPI is NOT an option, as confirmed by Dell support. So I am following the Handbook to recompile AML. The compilation failed with the following error:
# iasl -f my.asl

Intel ACPI Component Architecture
ASL+ Optimizing Compiler version 20160527-64
Copyright (c) 2000 - 2016 Intel Corporation

Ignoring all errors, forcing AML file generation

Compiler aborting due to parser-detected syntax error(s)
my.asl    39909:                     If (Local1 = (Local0 & 0x80) {}
Error    6126 -                                   syntax error ^

my.asl    39911:                     If (Local1 = (Local0 & 0x20) {}
Error    6126 -                                   syntax error ^

my.asl    39921:                     {
Error    6126 -      syntax error ^

my.asl    39929:                     {
Error    6126 -      syntax error ^

ASL Input:     my.asl - 39933 lines, 1437746 bytes, 18897 keywords

Compilation complete. 4 Errors, 0 Warnings, 0 Remarks, 0 Optimizations
The error is fairly obvious to any programmer as the source code there is:
                    If (Local1 = (Local0 & 0x80) {}
                    If (Local1 = (Local0 & 0x40) {}
                    If (Local1 = (Local0 & 0x20) {}
                    If (Local1 = (Local0 & 0x10)
So it's clear there are unmatched parenthesis there. I can see elsewhere there are other working lines like
            If (Local0 == 0x04)
But what's beyond me is: what should I change these broken lines to?

EDIT: please ignore this question/post, as I played around with the code and realized there is too much I don't know about this ACPI.
Last edited: