IIO: acpi-als: Get rid of ACPICA message printing
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Fri, 5 Mar 2021 18:42:29 +0000 (19:42 +0100)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 8 Mar 2021 18:10:30 +0000 (19:10 +0100)
Use acpi_evaluation_failure_warn() introduced previously instead of
the ACPICA-specific ACPI_EXCEPTION() macro to log warning messages
regarding ACPI object evaluation failures and drop the
ACPI_MODULE_NAME() definition only used by the ACPICA message
printing macro.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Acked-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/light/acpi-als.c

index 2be7180..5ad45f1 100644 (file)
@@ -26,8 +26,6 @@
 #define ACPI_ALS_DEVICE_NAME           "acpi-als"
 #define ACPI_ALS_NOTIFY_ILLUMINANCE    0x80
 
-ACPI_MODULE_NAME("acpi-als");
-
 /*
  * So far, there's only one channel in here, but the specification for
  * ACPI0008 says there can be more to what the block can report. Like
@@ -91,7 +89,7 @@ static int acpi_als_read_value(struct acpi_als *als, char *prop, s32 *val)
                                       &temp_val);
 
        if (ACPI_FAILURE(status)) {
-               ACPI_EXCEPTION((AE_INFO, status, "Error reading ALS %s", prop));
+               acpi_evaluation_failure_warn(als->device->handle, prop, status);
                return -EIO;
        }