From patchwork Sun Jul 8 09:14:20 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Rafael J. Wysocki" X-Patchwork-Id: 10513043 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id E589B603D7 for ; Sun, 8 Jul 2018 09:16:17 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D3EDC2893C for ; Sun, 8 Jul 2018 09:16:17 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id C7B4C28964; Sun, 8 Jul 2018 09:16:17 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 6D7372893C for ; Sun, 8 Jul 2018 09:16:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=mEHFglFYJm2ngAfu0qjDWlBMVxrrK6cE+PZRvgiXEjY=; b=SpIljhjkl/oJrG kqRl5emFNcOaSaQzvAU+U1QLDnrlgL5bF3e1ri/7XdKi+d96zvpKNkcnknks2IhOBCohgbz1rM4nU kul+yyjj8C0KDk4WxtDyKg/0R35vtNyCIREGsQjdoynkhe/eJ2C3Sfo/HMOIWBNb96pSuSj/pS8L6 P7BU9LMWFfz0xrk+ANv3NlTX2lDrfgThWlMoZ0D2m0dvxd0q38C4svbzitHlPgDdmGi7AUrnKIcCq hQFLQgqUgW53f4aveHeuS7O+mRE2c+KDHmGa/kxPBO1h3QnO1UU0epft0q4GSQPWH94aavcagWRDd xx8+tZeF95Ysu7f9pKHg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1fc5ne-0007tz-Cc; Sun, 08 Jul 2018 09:16:10 +0000 Received: from cloudserver094114.home.pl ([79.96.170.134]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1fc5nb-0007s2-3d for linux-arm-kernel@lists.infradead.org; Sun, 08 Jul 2018 09:16:09 +0000 Received: from 79.184.255.246.ipv4.supernova.orange.pl (79.184.255.246) (HELO aspire.rjw.lan) by serwer1319399.home.pl (79.96.170.134) with SMTP (IdeaSmtpServer 0.83) id e1743833ad883a3a; Sun, 8 Jul 2018 11:15:49 +0200 From: "Rafael J. Wysocki" To: Jeremy Linton Subject: Re: 4.18rc3 TX2 boot failure with "ACPICA: AML parser: attempt to continue loading table after error" Date: Sun, 08 Jul 2018 11:14:20 +0200 Message-ID: <6074707.jx9F3QFrWC@aspire.rjw.lan> In-Reply-To: References: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180708_021607_310110_F7893C99 X-CRM114-Status: GOOD ( 14.77 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "linux-acpi@vger.kernel.org" , Lorenzo Pieralisi , erik.schmauss@intel.com, "linux-kernel@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP On Monday, July 2, 2018 11:41:42 PM CEST Jeremy Linton wrote: > Hi, > > I'm experiencing two problems with commit 5088814a6e931 which is > "ACPICA: AML parser: attempt to continue loading table after error" > > The first is this boot failure on a thunderX2: > > [ 10.770098] ACPI Error: Ignore error and continue table load > (20180531/psobject-604) > [ 10.777926] Unable to handle kernel NULL pointer dereference at > virtual address 0000000000000000 > [ 10.786809] Mem abort info: > [ 10.789623] ESR = 0x96000004 > [ 10.792702] Exception class = DABT (current EL), IL = 32 bits > [ 10.798682] SET = 0, FnV = 0 > [ 10.801760] EA = 0, S1PTW = 0 > [ 10.804925] Data abort info: > [ 10.807827] ISV = 0, ISS = 0x00000004 > [ 10.811698] CM = 0, WnR = 0 > [ 10.814689] [0000000000000000] user address but active_mm is swapper > [ 10.821108] Internal error: Oops: 96000004 [#1] SMP > [ 10.826032] Modules linked in: > [ 10.829113] CPU: 30 PID: 1 Comm: swapper/0 Not tainted > 4.18.0-rc3PPTT4k+ #53 > [ 10.836234] Hardware name: Default string Cavium > ThunderX2/Default string, BIOS L50_5.13_1.0.0 05/16/2018 > [ 10.845905] pstate: 00400009 (nzcv daif +PAN -UAO) > [ 10.850746] pc : acpi_ps_peek_opcode+0x1c/0x40 > [ 10.855231] lr : acpi_ps_create_op+0x54/0x278 > [ 10.859627] sp : ffff000009a8ba30 > [ 10.862969] x29: ffff000009a8ba30 x28: 0000000054445353 > [ 10.868334] x27: 0000000000004008 x26: 0000000000000000 > [ 10.873698] x25: ffff000009767f23 x24: ffff000008d59000 > [ 10.879063] x23: ffff802672799030 x22: ffff000009a8bb28 > [ 10.884427] x21: 0000000000000000 x20: ffff000008d59000 > [ 10.889791] x19: ffff802672799030 x18: ffffffffffffffff > [ 10.895155] x17: 0000000000000013 x16: 0000000000000000 > [ 10.900519] x15: ffff000008d59708 x14: 2d7463656a626f73 > [ 10.905883] x13: 702f313335303831 x12: 3032282064616f6c > [ 10.911246] x11: 20656c6261742065 x10: 756e69746e6f6320 > [ 10.916610] x9 : 0000000000000058 x8 : ffff000008570998 > [ 10.921974] x7 : 203a726f72724520 x6 : 0000000000000334 > [ 10.927338] x5 : 0000000000000012 x4 : 0000000000000000 > [ 10.932701] x3 : 0000000000000000 x2 : ffff000009a8bb28 > [ 10.938065] x1 : 0000000000000000 x0 : ffff000008505790 > [ 10.943430] Process swapper/0 (pid: 1, stack limit = > 0x(____ptrval____)) > [ 10.950199] Call trace: > [ 10.952663] acpi_ps_peek_opcode+0x1c/0x40 > [ 10.956797] acpi_ps_create_op+0x54/0x278 > [ 10.960842] acpi_ps_parse_loop+0x1b4/0x6c8 > [ 10.965063] acpi_ps_parse_aml+0xe0/0x2b4 > [ 10.969108] acpi_ps_execute_table+0xa0/0x104 > [ 10.973505] acpi_ns_execute_table+0x120/0x194 > [ 10.977989] acpi_ns_parse_table+0x34/0x68 > [ 10.982122] acpi_ns_load_table+0x4c/0xbc > [ 10.986169] acpi_tb_load_namespace+0x1d4/0x240 > [ 10.990744] acpi_load_tables+0x50/0xbc > [ 10.994614] acpi_init+0xb8/0x374 > [ 10.997959] do_one_initcall+0x54/0x208 > [ 11.001829] kernel_init_freeable+0x224/0x300 > [ 11.006229] kernel_init+0x18/0x118 > [ 11.009747] ret_from_fork+0x10/0x18 > [ 11.013354] Code: aa0003f3 aa1e03e0 d503201f f9400661 (39400020) > [ 11.019535] ---[ end trace 2bd8068593cf8acc ]--- > [ 11.024195] Kernel panic - not syncing: Fatal exception > [ 11.029488] SMP: stopping secondary CPUs > [ 11.033480] ---[ end Kernel panic - not syncing: Fatal exception > ]--- > > Which does appear to be the result of some bad data in the table, but it > was working with 4.17, and reverting this commit solves the problem. Does the patch below make any difference? --- drivers/acpi/acpica/psobject.c | 3 +++ 1 file changed, 3 insertions(+) Index: linux-pm/drivers/acpi/acpica/psobject.c =================================================================== --- linux-pm.orig/drivers/acpi/acpica/psobject.c +++ linux-pm/drivers/acpi/acpica/psobject.c @@ -39,6 +39,9 @@ static acpi_status acpi_ps_get_aml_opcod ACPI_FUNCTION_TRACE_PTR(ps_get_aml_opcode, walk_state); walk_state->aml = walk_state->parser_state.aml; + if (!walk_state->aml) + return AE_CTRL_PARSE_CONTINUE; + walk_state->opcode = acpi_ps_peek_opcode(&(walk_state->parser_state)); /*