From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 82791C5478C for ; Tue, 27 Feb 2024 01:23:51 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 0EF394401D4; Mon, 26 Feb 2024 20:23:51 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 09F9844017F; Mon, 26 Feb 2024 20:23:51 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id EA8F44401D4; Mon, 26 Feb 2024 20:23:50 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0016.hostedemail.com [216.40.44.16]) by kanga.kvack.org (Postfix) with ESMTP id DB21844017F for ; Mon, 26 Feb 2024 20:23:50 -0500 (EST) Received: from smtpin16.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay04.hostedemail.com (Postfix) with ESMTP id B40681A0385 for ; Tue, 27 Feb 2024 01:23:50 +0000 (UTC) X-FDA: 81835837020.16.D46F973 Received: from out30-119.freemail.mail.aliyun.com (out30-119.freemail.mail.aliyun.com [115.124.30.119]) by imf09.hostedemail.com (Postfix) with ESMTP id 4DEE1140013 for ; Tue, 27 Feb 2024 01:23:46 +0000 (UTC) Authentication-Results: imf09.hostedemail.com; dkim=pass header.d=linux.alibaba.com header.s=default header.b=Mn8SD9gT; spf=pass (imf09.hostedemail.com: domain of xueshuai@linux.alibaba.com designates 115.124.30.119 as permitted sender) smtp.mailfrom=xueshuai@linux.alibaba.com; dmarc=pass (policy=none) header.from=linux.alibaba.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1708997029; a=rsa-sha256; cv=none; b=mHg1gK3YVqfmXaNRfu2SY5oCaXVs3RO42QjbQFjQtJH/+LhfEuLnnxVKxm0ur2Sp/dn9JD 2sFxJ92xKhGurxFFq3UcFZVMsiEV6x3/+QyF1FxotZ2K6sh79hhCi4F0lZ/xrNGeT/zNyi ZY79SLa7ulhFzyojtD43lIwa71z/y+4= ARC-Authentication-Results: i=1; imf09.hostedemail.com; dkim=pass header.d=linux.alibaba.com header.s=default header.b=Mn8SD9gT; spf=pass (imf09.hostedemail.com: domain of xueshuai@linux.alibaba.com designates 115.124.30.119 as permitted sender) smtp.mailfrom=xueshuai@linux.alibaba.com; dmarc=pass (policy=none) header.from=linux.alibaba.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1708997029; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=EsQRPyCzYcqHVkgKl+Bj2Ur2lyhbd0alTetMHoXUoF0=; b=pEkbO7z4x7mzNdloRGO3DAwHJEfRYjQkBX2CZUGCoZm4/gLHAqkaSXpE2bQaeB3LlnQPWX ORbnlEae1nJ2RMXuFJ5v5B+FtLo+DEn8uFHDSQ9h9U9JrulRD5FGo7cTG3jC15hwAWmJ3Q oM37YfvAF6ut2Zodg3y1LAei11N+q1M= DKIM-Signature:v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.alibaba.com; s=default; t=1708997023; h=Message-ID:Date:MIME-Version:Subject:To:From:Content-Type; bh=EsQRPyCzYcqHVkgKl+Bj2Ur2lyhbd0alTetMHoXUoF0=; b=Mn8SD9gT4Yo1hTDYF9VNyJ8I4Sc+ipWTMY0lBsBk4HRJnV0oZwxw7jsDHEJq25tt9uguvkr8Dn41Sk7d9SG+hMfWOo38Sj1wccOcJx/ULn8BT/RbzRKvvs0HX6oG9P8pWPq9qTicni1+IOtTFTzHmGuJ+YJisUlNAMs4SxyRquI= X-Alimail-AntiSpam:AC=PASS;BC=-1|-1;BR=01201311R181e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018045170;MF=xueshuai@linux.alibaba.com;NM=1;PH=DS;RN=35;SR=0;TI=SMTPD_---0W1Kw74F_1708997019; Received: from 30.240.112.180(mailfrom:xueshuai@linux.alibaba.com fp:SMTPD_---0W1Kw74F_1708997019) by smtp.aliyun-inc.com; Tue, 27 Feb 2024 09:23:42 +0800 Message-ID: Date: Tue, 27 Feb 2024 09:23:39 +0800 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v11 1/3] ACPI: APEI: send SIGBUS to current task if synchronous memory error not recovered Content-Language: en-US To: Borislav Petkov , "james.morse@arm.com" Cc: Jonathan Cameron , Dan Williams , Ira Weiny , "Luck, Tony" , rafael@kernel.org, wangkefeng.wang@huawei.com, tanxiaofei@huawei.com, mawupeng1@huawei.com, linmiaohe@huawei.com, naoya.horiguchi@nec.com, gregkh@linuxfoundation.org, will@kernel.org, jarkko@kernel.org, linux-acpi@vger.kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, akpm@linux-foundation.org, linux-edac@vger.kernel.org, x86@kernel.org, justin.he@arm.com, ardb@kernel.org, ying.huang@intel.com, ashish.kalra@amd.com, baolin.wang@linux.alibaba.com, tglx@linutronix.de, mingo@redhat.com, dave.hansen@linux.intel.com, lenb@kernel.org, hpa@zytor.com, robert.moore@intel.com, lvying6@huawei.com, xiexiuqi@huawei.com, zhuo.song@linux.alibaba.com References: <20221027042445.60108-1-xueshuai@linux.alibaba.com> <20240204080144.7977-2-xueshuai@linux.alibaba.com> <20240219092528.GTZdMeiDWIDz613VeT@fat_crate.local> <65d82c9352e78_24f3f294d5@dwillia2-mobl3.amr.corp.intel.com.notmuch> <20240223120813.00005d1f@Huawei.com> <20240223121701.00004bcf@Huawei.com> <00126cf9-bb59-4c05-8046-478d0d7f4297@linux.alibaba.com> <20240226102918.GBZdxn_v0NbVjs2XMB@fat_crate.local> From: Shuai Xue In-Reply-To: <20240226102918.GBZdxn_v0NbVjs2XMB@fat_crate.local> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Rspamd-Server: rspam08 X-Rspamd-Queue-Id: 4DEE1140013 X-Stat-Signature: ji54ahbzzqbmyihnwaxu1kiooroeinkk X-Rspam-User: X-HE-Tag: 1708997026-58226 X-HE-Meta: U2FsdGVkX18wWxjDB5Q+tOsfQopzgGauhZx34M+o/jKu3nA2IBDFj8kF+iTHFB/K2ryyasGB0mzHAOqJocS+SejgZEgf28qP0I+zaqoYFxGFoQT1FQpM9mZHV/3qNWQFmkXATid9GbH5yFwG2iMco6FxHBcpXi0m0P3lMfC3lUDruVARFXWhY+ns6RTE3wX5kIUmnqini0vVzTx7IBvAMe+Kf+VhNmuxdV1ESLsO+W3LxmVumNYeIXNzJTm9zXUCG6xD3ejMG+JGA0bFEFj6mtOXZkl3gJsbbE1/M3NC8wt+MGimUvxxmko40r0N2CvOH7pjQVNyTHrhThQghs2W5pZqpcN2L7wdpGhNjQ7/Zb2jVy+KQFPLZTg8olvu2qf87KseKz5WBLOt9aEQJkEzd6A2KUatE+n9WDBw0xax4fi7GazUKjY7vo/730wnEjSNezHKI5Wl4k9PAthyy1Ozhf+LsUiLWPH3V7h2hxSUw9ghza0pBcsH8F40N+dC/gqeX1bESlr77ssPc5deZAKqfXq0TijRDUg+eWObklNGGQ51b1ZSL91n7v22iBXu56/lNWa1FN1W+fgR8iGkRZFU/Nt7j+fuDV0r2+VK9AKlGfEAs/G8J8qBwCk8Ni7IkKMO9TAxrhD6RJkeEI31utwe2zvEOMZgKJBb52ISJlipy/anwe+b8HQbCqvsUgatQ2YaP9NXNqN6QKpn0qM+WN7+XtfZzwEtMw1WOW3ShtW6vYEHpI2PRJ7c/dfXagpUrPIWXe1dkgCORVCpwcKtD9T7DngTH2xHLrXg6aMpwHKJAQN2fpkoVwu+Mmd/lyZOIPPi15lNf+6ocyuxgeD3iV2Po2oj6jItVopqQp0de5dQEdcbiK780xGeIhCIpDvg0DyL9UniZwjn6SDp60Wd8bwObeJAh8nfpwAtvOo1Z4kvm/R702xVGGATECBbo4KNNNNZWfxZZxAhZLE= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: On 2024/2/26 18:29, Borislav Petkov wrote: > On Sat, Feb 24, 2024 at 02:08:42PM +0800, Shuai Xue wrote: >> @Borislav, do you have any other concerns? > > Yes, this change needs to be further reviewed by an ARM person: I have > no clue what those "abnormal synchronous errors" on ARM are Hi, Borislav, May the `abnormal` is not inaccurate and misled you. I mean the preconditions check before memory_failure_queue(): - `if (!(mem_err->validation_bits & CPER_MEM_VALID_PA))` in ghes_handle_memory_failure() - `if (flags == -1)` in ghes_handle_memory_failure() - `if (!IS_ENABLED(CONFIG_ACPI_APEI_MEMORY_FAILURE))` in ghes_do_memory_failure() - `if (!pfn_valid(pfn) && !arch_is_platform_page(physical_addr)) ` in ghes_do_memory_failure() If the preconditions are not passed, the user-space process will trigger SEA again. This loop can potentially exceed the platform firmware threshold or even trigger a kernel hard lockup, leading to a system reboot. > and how > they're supposed to be handled properly there: > > - what happens if you get such an error when ghes is disabled there? If ghes_disable is set, the GHES driver will not be inited by acpi_ghes_init(), so none of error notifications will be handled. IMHO, it is expected. > > - is that even the right place to handle them? > > James? > Leave this to @James. Thank you. Best Regards, Shuai