Skip to content

Commit c48cf1b

Browse files
committed
ACPI / utils: Drop error messages from acpi_evaluate_reference()
Some of the error messages printed by acpi_evaluate_reference() with the KERN_ERR priority should really be debug messages, but then they would be redundant, because acpi_util_eval_error() is called too at the same spots (except for one). Drop the kernel messages from there entirely and leave the acpi_util_eval_error() to handle the debug printing. In one case, replace the kernel message with a call to acpi_util_eval_error(). Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
1 parent b2776bf commit c48cf1b

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

drivers/acpi/utils.c

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -347,22 +347,16 @@ acpi_evaluate_reference(acpi_handle handle,
347347
package = buffer.pointer;
348348

349349
if ((buffer.length == 0) || !package) {
350-
printk(KERN_ERR PREFIX "No return object (len %X ptr %p)\n",
351-
(unsigned)buffer.length, package);
352350
status = AE_BAD_DATA;
353351
acpi_util_eval_error(handle, pathname, status);
354352
goto end;
355353
}
356354
if (package->type != ACPI_TYPE_PACKAGE) {
357-
printk(KERN_ERR PREFIX "Expecting a [Package], found type %X\n",
358-
package->type);
359355
status = AE_BAD_DATA;
360356
acpi_util_eval_error(handle, pathname, status);
361357
goto end;
362358
}
363359
if (!package->package.count) {
364-
printk(KERN_ERR PREFIX "[Package] has zero elements (%p)\n",
365-
package);
366360
status = AE_BAD_DATA;
367361
acpi_util_eval_error(handle, pathname, status);
368362
goto end;
@@ -381,17 +375,13 @@ acpi_evaluate_reference(acpi_handle handle,
381375

382376
if (element->type != ACPI_TYPE_LOCAL_REFERENCE) {
383377
status = AE_BAD_DATA;
384-
printk(KERN_ERR PREFIX
385-
"Expecting a [Reference] package element, found type %X\n",
386-
element->type);
387378
acpi_util_eval_error(handle, pathname, status);
388379
break;
389380
}
390381

391382
if (!element->reference.handle) {
392-
printk(KERN_WARNING PREFIX "Invalid reference in"
393-
" package %s\n", pathname);
394383
status = AE_NULL_ENTRY;
384+
acpi_util_eval_error(handle, pathname, status);
395385
break;
396386
}
397387
/* Get the acpi_handle. */

0 commit comments

Comments
 (0)