Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp3600104ybc; Mon, 18 Nov 2019 18:25:47 -0800 (PST) X-Google-Smtp-Source: APXvYqyBgMpkxDg0WKWyvmebNrmfjAQETmiuZiuobzK0yrvzlrMftEHSu8zZwSYYA9Re1dj4R3lD X-Received: by 2002:a17:906:6c95:: with SMTP id s21mr32001106ejr.205.1574130346935; Mon, 18 Nov 2019 18:25:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574130346; cv=none; d=google.com; s=arc-20160816; b=G9u0PFBxCo7o+ZqPi0uwA0w19Sz+qJfJFXBz7RMXtZoMJFsS5I8k5dv+0OdkdYE4OW PdoY/6qLdnARSVASW95Z8/Ze96+wn7Rzv35cF/LL6TinX1T/1K9GIsNKzImvIdEmKf6k tGLLtrTkx1myamz6FXUQnu9i3L4FWcs1FGTHrcR1KnRLCUaYIyDHxlNvnZJBYKG33T87 3rsruPGFBWtLN187bdx55fCWuzJ+Ss5gHvD/X30KRoUKsKZx2TX6jWSM6Iwzh41GpZ9H Ll58wbx8q+1BZCqq9CjGPn/BPpGlxss9oJCu05LD3wpuOdQsOvHsbYe8pdP9nQBwzj1g 4a+A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=lRmgD9Eg7+mUYBR15f4Na7ONQ+VILjZ9nKEevEnyW2w=; b=KRFajqk8KJO4Uqq/EtpmC0CUAQaaYBSHJBez1grEEgK+zYZM6FWnIks5+aR2TP1+E4 OWsl7zAp2ish/wMKKMQxT6tAOZ02Ks86FpDqENtzjEcqF9E2riRWammrqCL7xGpip4aE ZjWbcpD2sxTIKKTXYil+aQFbDLp747QEa/r6a+ruOKC6DCPmkGGivhU6HsCoKnylXdmu 0X8Bsk6Ghg/u8KR2cJJCkfeE//I7l30ymQ1bQyBloMOhfQdua/H4QOKYtdr3yUGKSngZ gDbSzv9CgseLTimNEobIiQ4y1JQRVj4+Q5sZEHOYHXZQHN5Z6iE/OTPwZkg43ILca/0W s4LQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b19si14160995edb.40.2019.11.18.18.25.22; Mon, 18 Nov 2019 18:25:46 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727261AbfKSCWg (ORCPT + 99 others); Mon, 18 Nov 2019 21:22:36 -0500 Received: from szxga07-in.huawei.com ([45.249.212.35]:57154 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726761AbfKSCWg (ORCPT ); Mon, 18 Nov 2019 21:22:36 -0500 Received: from DGGEMS407-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id 09AD612459B90E74DFA0; Tue, 19 Nov 2019 10:22:33 +0800 (CST) Received: from [127.0.0.1] (10.177.251.225) by DGGEMS407-HUB.china.huawei.com (10.3.19.207) with Microsoft SMTP Server id 14.3.439.0; Tue, 19 Nov 2019 10:22:26 +0800 Subject: Re: [PATCH v2] ACPI: sysfs: Change ACPI_MASKABLE_GPE_MAX to 0x100 To: "Rafael J. Wysocki" , Dexuan-Linux Cui CC: Dan Williams , "Rafael J. Wysocki" , Len Brown , Linux ACPI , Linux Kernel Mailing List , "open list:DOCUMENTATION" , "hushiyuan@huawei.com" , "linfeilong@huawei.com" , Dexuan Cui References: From: Yunfeng Ye Message-ID: <9eff3584-a25b-ca47-d38f-ce83862baa18@huawei.com> Date: Tue, 19 Nov 2019 10:22:05 +0800 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.177.251.225] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2019/11/19 5:15, Rafael J. Wysocki wrote: > On Mon, Nov 18, 2019 at 8:44 PM Dexuan-Linux Cui wrote: >> >> On Mon, Nov 18, 2019 at 1:04 AM Rafael J. Wysocki wrote: >>> >>> On Sat, Nov 16, 2019 at 9:06 PM Dan Williams wrote: >>>> >>>> On Wed, Nov 13, 2019 at 11:17 PM Yunfeng Ye wrote: >>>>> >>>>> The commit 0f27cff8597d ("ACPI: sysfs: Make ACPI GPE mask kernel >>>>> parameter cover all GPEs") says: >>>>> "Use a bitmap of size 0xFF instead of a u64 for the GPE mask so 256 >>>>> GPEs can be masked" >>>>> >>>>> But the masking of GPE 0xFF it not supported and the check condition >>>>> "gpe > ACPI_MASKABLE_GPE_MAX" is not valid because the type of gpe is >>>>> u8. >>>>> >>>>> So modify the macro ACPI_MASKABLE_GPE_MAX to 0x100, and drop the "gpe > >>>>> ACPI_MASKABLE_GPE_MAX" check. In addition, update the docs "Format" for >>>>> acpi_mask_gpe parameter. >>>>> >>>>> Fixes: 0f27cff8597d ("ACPI: sysfs: Make ACPI GPE mask kernel parameter cover all GPEs") >>>>> Signed-off-by: Yunfeng Ye >>>>> --- >>>>> v1 -> v2: >>>>> - drop the "gpe > ACPI_MASKABLE_GPE_MAX" check >>>>> - update the docs "Format" from to for acpi_mask_gpe parameter >>>>> - update the commit comment >>>>> >>>>> Documentation/admin-guide/kernel-parameters.txt | 2 +- >>>>> drivers/acpi/sysfs.c | 4 ++-- >>>>> 2 files changed, 3 insertions(+), 3 deletions(-) >>>> >>>> Bisect flags commit eb09878e1301 "ACPI: sysfs: Change >>>> ACPI_MASKABLE_GPE_MAX to 0x100" in -next as the reason for a boot >>>> regression in my qemu-kvm test environment. It spews: >>>> >>>> [ 1.456728] ACPI: Masking GPE 0x0. >>>> ... >>>> [ 161.721420] ACPI: Masking GPE 0x0. >>>> >>>> ...and then hangs. >>>> >>>> A straight revert gets the configuration back on its feet. >>>> >>>> qemu-system-x86_64 --version >>>> QEMU emulator version 4.0.50 (v4.0.0-928-g49c6c6ac0cd8) >>> >>> OK, I'll drop it then, thanks! >> >> We're seeing the same issue wtih 5.4.0-rc7-next-20191118 on a Linux VM >> running on Hyper-V : >> >> [ 0.133029] ACPI: 1 ACPI AML tables successfully acquired and loaded >> [ 0.144023] ACPI: Interpreter enabled >> [ 0.145023] ACPI: (supports S0 S5) >> [ 0.146023] ACPI: Using IOAPIC for interrupt routing >> [ 0.147024] PCI: Using host bridge windows from ACPI; if necessary, >> use "pci=nocrs" and report a bug >> [ 0.148031] ACPI: Masking GPE 0x0. >> ... >> [ 774.839023] ACPI: Masking GPE 0x0. >> [ 774.840023] ACPI: Masking GPE 0x0. >> >> I guess the patch is only tested on a physical machine and not on a VM... > > It looks like the patch hasn't been tested at all. > > Please try to change the data type of gpe in > acpi_gpe_apply_masked_gpes() to u16 and see if that helps. > Sorry for this problem, I have no good test after modification according to inspection opinions. The first version patch is ok, the type of gpe is changed to u32. and I have test it before. thanks. > . >