Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp2460743pxb; Tue, 23 Feb 2021 07:36:08 -0800 (PST) X-Google-Smtp-Source: ABdhPJwbvdqQEyZJNyHM2dmKw4lDnCgses3X8eaKT4NVT7Te6I3x8qO0OePKKoMcIhJclBaujVE1 X-Received: by 2002:a17:906:3052:: with SMTP id d18mr12849469ejd.530.1614094568674; Tue, 23 Feb 2021 07:36:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614094568; cv=none; d=google.com; s=arc-20160816; b=TIugnbKKfblRqEH22HqlPDaVaQ4z3mQXyBl5MU+FON/GvDPWfS7Z4/PUkB4+RCpCbF JKq/1RWTLam6PcftuQjTgyd96YVRp6gwHlwzBc0L5S25pjmJTVTmmh42sDLPrlgu8lWX MxinKIColq7gb8vdkHFFWhhnKFe5QNhK2ZRRT6pEm8s0gijsKk3+RZCHN4U/VnpdFvfo VMFF/DkaLgNR+uJl4yzjByuArc5H461TtLTk6jJAe+YbEFvvlzS+5GiXLcokr7alU8Tb jK+87MWawLbDeXTZ3ekEtlIpT8nIxK5gSTIvtjsmXa2jZHdpdlQlUzpofMCu82rlv4Du 8kPQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:in-reply-to:cc:references:message-id:date :subject:mime-version:from:content-transfer-encoding:dkim-signature; bh=S1+694tF7E6JOAf32EqgTXj/ubixpJ18hXdr8aPWDgI=; b=PYz9xr3ETaC57F9lCGJbIHpdzXUO9NdC059thWWqY8CeXIiRlmFozu6Hya+GfcKekS +r9TD8Snh6sj/S/8uvUO97EfCNMLGEOTezNQ/1sODMcPdYA1FtmFfnsGJvrZdKo86OrA 7NeHMbaBHpRMXyyYBpF2QMcanMVzIqToAiukS5EQX+LbSckHrt3yTH4XS1vtGRNSrQw3 oXX25lt/f1Bk9DR5vKXyqwdqbz3YX4NNcrPXB7o+fB7JErAlP0C9mq1VHedigu5CRcOc f0UB/Endge1cetizoHcpm5SEkXqnWNbPQCcKNNQEzCL7njTWTJL+NN3mojzZ2I0PRdrJ EOQQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@amacapital-net.20150623.gappssmtp.com header.s=20150623 header.b=ngI0rU01; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d17si2954064edp.404.2021.02.23.07.35.44; Tue, 23 Feb 2021 07:36:08 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=fail header.i=@amacapital-net.20150623.gappssmtp.com header.s=20150623 header.b=ngI0rU01; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233173AbhBWPeb (ORCPT + 99 others); Tue, 23 Feb 2021 10:34:31 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43022 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232307AbhBWPea (ORCPT ); Tue, 23 Feb 2021 10:34:30 -0500 Received: from mail-pl1-x631.google.com (mail-pl1-x631.google.com [IPv6:2607:f8b0:4864:20::631]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 46E97C061786 for ; Tue, 23 Feb 2021 07:33:49 -0800 (PST) Received: by mail-pl1-x631.google.com with SMTP id s16so10032025plr.9 for ; Tue, 23 Feb 2021 07:33:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amacapital-net.20150623.gappssmtp.com; s=20150623; h=content-transfer-encoding:from:mime-version:subject:date:message-id :references:cc:in-reply-to:to; bh=S1+694tF7E6JOAf32EqgTXj/ubixpJ18hXdr8aPWDgI=; b=ngI0rU01hqa40qg2u4VlRUqm7wgIOZH9Lo+aTRNgzkK1of1tdZYDsLDeM3bnImibnp 1i/0USARwUi98V6w1t1REkAkyscY8CtbG6D13TkF4Aq1YoRYzalAzBe/6tuySpb41ZBZ MArEOMogQRMgVIgfD7EPHqJVo1YMTyltkKXMlnpRhSzfa10s2YM2AlxIiM3OvMzTKFT3 UU3ROBZ/1pWcAKZhdK4AeN7Ubo6z4W/hqW+tMs1XEzLk+l8XoTglqEbFaVV3FvPXYeTM QHo4xkQfOZ0k2ZXsVFH6cU2hSf2YovEtg5Nz7y4mIqvz3T/09pUhzL30+00ayJcHXwKA 35hw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:content-transfer-encoding:from:mime-version :subject:date:message-id:references:cc:in-reply-to:to; bh=S1+694tF7E6JOAf32EqgTXj/ubixpJ18hXdr8aPWDgI=; b=Qk1fOj74tBxCchmxcSXBBhNGpObni7lOCRrucY6EWA6UWfm7S7aQrKUvLZcH9lyZqS Cbtwsj/UFuiUWZw/9FnLY/aeqAvs6ss/YFcLdWq1RtY8FMq4o/2+gZUvSnYbukKBphhq UCGpAg5eXx52FN/fPIk19I2URVtp44e4blFGLHT4bSnHK+Zl2nJdcjx8q2Q/69SEJgvu 56KQSO9DZ2o2cCt0plQEHOfRZ3cieoxc7xQY60mhdZ0F9EylQkZE94GwrD6r00qLEtxK kPZ8fwLUVel8g9Ge+2cLTUcW2o6NxSiupWrdQej1hG8hnjYKn6UDv7LKyDMFyFQWq/Ke b1vQ== X-Gm-Message-State: AOAM533r2IuEtUymDJHZuvHcxp6p/NiK9TnH/kxYYOGz8HAFP/HY5Vda pu/iKDzHoDhMui4O2oFUZV1UwQ== X-Received: by 2002:a17:90a:b292:: with SMTP id c18mr29248288pjr.134.1614094428836; Tue, 23 Feb 2021 07:33:48 -0800 (PST) Received: from ?IPv6:2601:646:c200:1ef2:2488:1c5a:27b:935? ([2601:646:c200:1ef2:2488:1c5a:27b:935]) by smtp.gmail.com with ESMTPSA id 3sm21357516pfd.45.2021.02.23.07.33.47 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 23 Feb 2021 07:33:47 -0800 (PST) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable From: Andy Lutomirski Mime-Version: 1.0 (1.0) Subject: Re: [PATCH v3] x86/fault: Send a SIGBUS to user process always for hwpoison page access. Date: Tue, 23 Feb 2021 07:33:46 -0800 Message-Id: <788DFBA0-903F-4548-9C2F-B1A1543EE770@amacapital.net> References: <20210223204436.1df73153@alex-virtual-machine> Cc: =?utf-8?Q? "HORIGUCHI_NAOYA=28=E5=A0=80=E5=8F=A3=E3=80=80=E7=9B=B4?= =?utf-8?Q?=E4=B9=9F=29" ?= , tony.luck@intel.com, dave.hansen@linux.intel.com, luto@kernel.org, peterz@infradead.org, tglx@linutronix.de, mingo@redhat.com, bp@alien8.de, hpa@zytor.com, x86@kernel.org, yangfeng1@kingsoft.com, linux-mm@kvack.org, linux-kernel@vger.kernel.org In-Reply-To: <20210223204436.1df73153@alex-virtual-machine> To: Aili Yao X-Mailer: iPhone Mail (18D52) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > On Feb 23, 2021, at 4:44 AM, Aili Yao wrote: >=20 > =EF=BB=BFOn Fri, 5 Feb 2021 17:01:35 +0800 > Aili Yao wrote: >=20 >> When one page is already hwpoisoned by MCE AO action, processes may not >> be killed, processes mapping this page may make a syscall include this >> page and result to trigger a VM_FAULT_HWPOISON fault, as it's in kernel >> mode it may be fixed by fixup_exception, current code will just return >> error code to user code. >>=20 >> This is not sufficient, we should send a SIGBUS to the process and log >> the info to console, as we can't trust the process will handle the error >> correctly. >>=20 >> Suggested-by: Feng Yang >> Signed-off-by: Aili Yao >> --- >> arch/x86/mm/fault.c | 62 +++++++++++++++++++++++++++++---------------- >> 1 file changed, 40 insertions(+), 22 deletions(-) >>=20 > Hi luto; > Is there any feedback? At the very least, this needs a clear explanation of why your proposed behav= ior is better than the existing behavior. >=20 > Thanks > Aili Yao