From patchwork Thu Jun 14 14:06:02 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Colin Ian King X-Patchwork-Id: 164937 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from chlorine.canonical.com (chlorine.canonical.com [91.189.94.204]) by ozlabs.org (Postfix) with ESMTP id 98F4DB7048 for ; Fri, 15 Jun 2012 00:06:06 +1000 (EST) Received: from localhost ([127.0.0.1] helo=chlorine.canonical.com) by chlorine.canonical.com with esmtp (Exim 4.71) (envelope-from ) id 1SfAgW-0002pU-Of for incoming@patchwork.ozlabs.org; Thu, 14 Jun 2012 14:06:04 +0000 Received: from youngberry.canonical.com ([91.189.89.112]) by chlorine.canonical.com with esmtp (Exim 4.71) (envelope-from ) id 1SfAgV-0002nq-9e for fwts-devel@lists.ubuntu.com; Thu, 14 Jun 2012 14:06:03 +0000 Received: from cpc19-craw6-2-0-cust5.croy.cable.virginmedia.com ([77.102.228.6] helo=localhost) by youngberry.canonical.com with esmtpsa (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1SfAgV-0003CN-6H for fwts-devel@lists.ubuntu.com; Thu, 14 Jun 2012 14:06:03 +0000 From: Colin King To: fwts-devel@lists.ubuntu.com Subject: [PATCH] apci: checksum: RSDT and XSDT checksum failures should not be critical (LP: #1013168) Date: Thu, 14 Jun 2012 15:06:02 +0100 Message-Id: <1339682762-26456-1-git-send-email-colin.king@canonical.com> X-Mailer: git-send-email 1.7.10.4 X-BeenThere: fwts-devel@lists.ubuntu.com X-Mailman-Version: 2.1.13 Precedence: list List-Id: Firmware Test Suite Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: fwts-devel-bounces@lists.ubuntu.com Errors-To: fwts-devel-bounces@lists.ubuntu.com From: Colin Ian King It seems that the kernel is quite happy to handle RSDT and XSDT tables that fail on their checksum checks, so lets not fail these as critical failures anymore. Signed-off-by: Colin Ian King --- src/acpi/checksum/checksum.c | 41 +++++++---------------------------------- 1 file changed, 7 insertions(+), 34 deletions(-) diff --git a/src/acpi/checksum/checksum.c b/src/acpi/checksum/checksum.c index 264e7d0..2c41cce 100644 --- a/src/acpi/checksum/checksum.c +++ b/src/acpi/checksum/checksum.c @@ -89,16 +89,6 @@ static void checksum_rsdp(fwts_framework *fw, fwts_acpi_table_info *table) } -/* - * The following tables the kernel requires the checksum to be valid otherwise - * it will not load them, so checksum failures here are considered critical errors. - */ -static char *critical_checksum[] = { - "RSDT", - "XSDT", - NULL -}; - static int checksum_scan_tables(fwts_framework *fw) { int i; @@ -131,35 +121,18 @@ static int checksum_scan_tables(fwts_framework *fw) fwts_passed(fw, "Table %s has correct checksum 0x%x.", table->name, hdr->checksum); else { - int i; - int log_level = LOG_LEVEL_LOW; - - for (i = 0; critical_checksum[i]; i++) { - if (!strcmp(table->name, critical_checksum[i])) { - log_level = LOG_LEVEL_CRITICAL; - break; - } - } - - fwts_failed(fw, log_level, "ACPITableChecksum", + fwts_failed(fw, LOG_LEVEL_LOW, "ACPITableChecksum", "Table %s has incorrect checksum, " "expected 0x%2.2x, got 0x%2.2x.", table->name, (uint8_t)(hdr->checksum-checksum), hdr->checksum); - /* Give some contextual explanation of the error */ - if (log_level == LOG_LEVEL_CRITICAL) - fwts_advice(fw, - "The kernel requires this table to have a " - "valid checksum and will not load it. This " - "will lead to ACPI not working correctly."); - else - fwts_advice(fw, - "The kernel will warn that this table has " - "an invalid checksum but will ignore the " - "error and still load it. This is not a " - "critical issue, but should be fixed if " - "possible to avoid the warning messages."); + fwts_advice(fw, + "The kernel will warn that this table has " + "an invalid checksum but will ignore the " + "error and still load it. This is not a " + "critical issue, but should be fixed if " + "possible to avoid the warning messages."); fwts_tag_failed(fw, FWTS_TAG_ACPI_TABLE_CHECKSUM); }