Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1762973AbYJKGuw (ORCPT ); Sat, 11 Oct 2008 02:50:52 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1756755AbYJKGjA (ORCPT ); Sat, 11 Oct 2008 02:39:00 -0400 Received: from vms172071pub.verizon.net ([206.46.172.71]:52181 "EHLO vms172071pub.verizon.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753879AbYJKGhR (ORCPT ); Sat, 11 Oct 2008 02:37:17 -0400 Date: Sat, 11 Oct 2008 02:36:35 -0400 From: Len Brown Subject: [PATCH 75/85] ACPI processor: Debug interface used for error message cleanup In-reply-to: <1223707005-26864-1-git-send-email-lenb@kernel.org> In-reply-to: <1d80ebdb81444701024ad9b9f026516561496a43.1223706853.git.len.brown@intel.com> To: linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Thomas Renninger , Andi Kleen , Len Brown Message-id: Organization: Intel Open Source Technology Center X-Mailer: git-send-email 1.6.0.2.307.gc427 References: <1223707005-26864-1-git-send-email-lenb@kernel.org> References: <1d80ebdb81444701024ad9b9f026516561496a43.1223706853.git.len.brown@intel.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 3604 Lines: 108 From: Thomas Renninger Signed-off-by: Thomas Renninger Signed-off-by: Andi Kleen Signed-off-by: Len Brown --- drivers/acpi/processor_perflib.c | 17 ++++++----------- drivers/acpi/processor_throttling.c | 17 ++++++----------- 2 files changed, 12 insertions(+), 22 deletions(-) diff --git a/drivers/acpi/processor_perflib.c b/drivers/acpi/processor_perflib.c index 80c251e..bf183e7 100644 --- a/drivers/acpi/processor_perflib.c +++ b/drivers/acpi/processor_perflib.c @@ -523,14 +523,9 @@ static int acpi_processor_get_psd(struct acpi_processor *pr) } psd = buffer.pointer; - if (!psd || (psd->type != ACPI_TYPE_PACKAGE)) { - ACPI_DEBUG_PRINT((ACPI_DB_ERROR, "Invalid _PSD data\n")); - result = -EFAULT; - goto end; - } - - if (psd->package.count != 1) { - ACPI_DEBUG_PRINT((ACPI_DB_ERROR, "Invalid _PSD data\n")); + if (!psd || (psd->type != ACPI_TYPE_PACKAGE) + || psd->package.count != 1) { + printk(KERN_ERR "Invalid _PSD data\n"); result = -EFAULT; goto end; } @@ -543,19 +538,19 @@ static int acpi_processor_get_psd(struct acpi_processor *pr) status = acpi_extract_package(&(psd->package.elements[0]), &format, &state); if (ACPI_FAILURE(status)) { - ACPI_DEBUG_PRINT((ACPI_DB_ERROR, "Invalid _PSD data\n")); + ACPI_EXCEPTION((AE_INFO, status, "Invalid _PSD data")); result = -EFAULT; goto end; } if (pdomain->num_entries != ACPI_PSD_REV0_ENTRIES) { - ACPI_DEBUG_PRINT((ACPI_DB_ERROR, "Unknown _PSD:num_entries\n")); + printk(KERN_ERR "Unknown _PSD:num_entries\n"); result = -EFAULT; goto end; } if (pdomain->revision != ACPI_PSD_REV0_REVISION) { - ACPI_DEBUG_PRINT((ACPI_DB_ERROR, "Unknown _PSD:revision\n")); + printk(KERN_ERR "Unknown _PSD:revision\n"); result = -EFAULT; goto end; } diff --git a/drivers/acpi/processor_throttling.c b/drivers/acpi/processor_throttling.c index a56fc6c..ce4540d 100644 --- a/drivers/acpi/processor_throttling.c +++ b/drivers/acpi/processor_throttling.c @@ -527,14 +527,9 @@ static int acpi_processor_get_tsd(struct acpi_processor *pr) } tsd = buffer.pointer; - if (!tsd || (tsd->type != ACPI_TYPE_PACKAGE)) { - ACPI_DEBUG_PRINT((ACPI_DB_ERROR, "Invalid _TSD data\n")); - result = -EFAULT; - goto end; - } - - if (tsd->package.count != 1) { - ACPI_DEBUG_PRINT((ACPI_DB_ERROR, "Invalid _TSD data\n")); + if (!tsd || (tsd->type != ACPI_TYPE_PACKAGE) + || tsd->package.count != 1) { + printk(KERN_INFO "Invalid _TSD data\n"); result = -EFAULT; goto end; } @@ -547,19 +542,19 @@ static int acpi_processor_get_tsd(struct acpi_processor *pr) status = acpi_extract_package(&(tsd->package.elements[0]), &format, &state); if (ACPI_FAILURE(status)) { - ACPI_DEBUG_PRINT((ACPI_DB_ERROR, "Invalid _TSD data\n")); + ACPI_EXCEPTION((AE_INFO, status, "Invalid _TSD data")); result = -EFAULT; goto end; } if (pdomain->num_entries != ACPI_TSD_REV0_ENTRIES) { - ACPI_DEBUG_PRINT((ACPI_DB_ERROR, "Unknown _TSD:num_entries\n")); + printk(KERN_ERR "Unknown _TSD:num_entries\n"); result = -EFAULT; goto end; } if (pdomain->revision != ACPI_TSD_REV0_REVISION) { - ACPI_DEBUG_PRINT((ACPI_DB_ERROR, "Unknown _TSD:revision\n")); + printk(KERN_ERR "Unknown _TSD:revision\n"); result = -EFAULT; goto end; } -- 1.5.5.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/