The branch main has been updated by olce:

URL: 
https://cgit.FreeBSD.org/src/commit/?id=91d3fb31e858404f62d4a3afae2e209796968c3d

commit 91d3fb31e858404f62d4a3afae2e209796968c3d
Author:     Olivier Certner <[email protected]>
AuthorDate: 2026-05-07 16:15:21 +0000
Commit:     Olivier Certner <[email protected]>
CommitDate: 2026-05-13 12:38:26 +0000

    acpi_spmc(4): If verbose, print called functions
    
    ...as a debugging aid, in order to be able to check that some functions
    are effectively called and to identify them quickly if they cause
    a hang.
    
    Reviewed by:    obiwac
    Sponsored by:   The FreeBSD Foundation
    Differential Revision:  https://reviews.freebsd.org/D56883
---
 sys/dev/acpica/acpi_spmc.c | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)

diff --git a/sys/dev/acpica/acpi_spmc.c b/sys/dev/acpica/acpi_spmc.c
index fcd4105b2a76..8cb1d2878d88 100644
--- a/sys/dev/acpica/acpi_spmc.c
+++ b/sys/dev/acpica/acpi_spmc.c
@@ -763,7 +763,8 @@ acpi_spmc_get_constraints(struct acpi_spmc_softc *const sc)
        if (ACPI_FAILURE(status)) {
                failed_to_call_dsm(sc, dsm, DSM_GET_DEVICE_CONSTRAINTS);
                return (ENXIO);
-       }
+       } else if (VERBOSE())
+               device_printf(sc->dev, "Constraints: Retrieved successfully\n");
 
        object = (ACPI_OBJECT *)result.Pointer;
        if (dsm == &dsm_intel)
@@ -864,14 +865,21 @@ acpi_spmc_run(device_t dev, const struct dsm_desc *const 
dsm,
            (force_call_expected_functions && has_dsm(sc, dsm->index))))
                return;
 
+       if (VERBOSE())
+               device_printf(dev, "DSM %s: Calling function %s\n",
+                   dsm->name, dsm_function_name(dsm, function_index));
        status = acpi_EvaluateDSMTyped(sc->handle, (const uint8_t *)&dsm->uuid,
            get_revision(sc, dsm->index), function_index, NULL,
            &result, ACPI_TYPE_ANY);
 
        if (ACPI_FAILURE(status))
                failed_to_call_dsm(sc, dsm, function_index);
-       else
+       else {
+               if (VERBOSE())
+                       device_printf(dev, "DSM %s: Function %s successful\n",
+                           dsm->name, dsm_function_name(dsm, function_index));
                AcpiOsFree(result.Pointer);
+       }
 }
 
 /*

Reply via email to