Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp2336102pxb; Tue, 23 Feb 2021 04:47:03 -0800 (PST) X-Google-Smtp-Source: ABdhPJzd7V9TVkdYDWVbgLKdLDDGdNxPgVaQMI8SD3JuEbdrgVfuKpwORFstY6EE6qnDW/ySfdSM X-Received: by 2002:a17:907:9856:: with SMTP id jj22mr25285612ejc.377.1614084423215; Tue, 23 Feb 2021 04:47:03 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614084423; cv=none; d=google.com; s=arc-20160816; b=T42VKU/NbwwrqYJt5rrWWsKoxOOnGQxCAp23utfo9h7KNZpTw1jAsEqbukQ+ZYQmJd DSNG1NBVV0GMw9cv5+QDM/bTldN5AYuIStswPlyEtcaY0dowcyzAqi4Bgj3BWUync+fh Jyo7EzAGN36rQsddrCVJLDsD+/kvH1XxdNQhQiyMZVk0cED6YPCn6Vzb/jTGfqNEnQiA Qdti3bl2h6t5FrgGrBqT0WHxRBRYfoDLHnI1p6myatZktlgFVS8DdMm43ODNR+I1fNgj FaZlG3USwK+q4zuc3PN6eTVvLIAYndipM8ccrj545EvxC+5o5I4ZKKLtvBGkZg8pqZa4 vAhA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :organization:references:in-reply-to:message-id:subject:cc:to:from :date; bh=aleM5eFfT6brhD1uMjH1Vi4Bq+aza+uomJmXw7NYJs0=; b=AFKuzpw3D82S4oX/z8SeVJIScvGgva24GHymoSq5yH/CG4fOKTJx3wtxKl6tuvKc5B 70R0+5mTSs7614YUn1Lf5N6g0G4vvCu9xpxoxMwQB3BV7O3L3DykgeGBEnNwLF9eluW0 lXBk83Rsm+8GTkVYfU50hcNIa7Hk1+oYNUfR+G/m1nGdFRx6XpEPHihFCAP4CfPCHYed HAL/lvT0O0kIh17LYvEw7o2cFJSffLA/hTJ9Rsq0q/LUyCmraX5Yb78bH0pSb+tdKJkd bW225EXzsDqCsRtLkTrh7aGeKg+iYDMyPrW2BPet11A8+tocCFKFIGBy/baWaQp/R7Ww buKQ== ARC-Authentication-Results: i=1; mx.google.com; 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 gv50si10248538ejc.145.2021.02.23.04.46.37; Tue, 23 Feb 2021 04:47:03 -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; 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 S232473AbhBWMpY (ORCPT + 99 others); Tue, 23 Feb 2021 07:45:24 -0500 Received: from mail.kingsoft.com ([114.255.44.145]:12139 "EHLO mail.kingsoft.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232452AbhBWMpX (ORCPT ); Tue, 23 Feb 2021 07:45:23 -0500 X-AuditID: 0a580155-713ff700000550c6-4e-6034f1ae9785 Received: from mail.kingsoft.com (localhost [10.88.1.32]) (using TLS with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mail.kingsoft.com (SMG-2-NODE-85) with SMTP id 6C.18.20678.EA1F4306; Tue, 23 Feb 2021 20:14:38 +0800 (HKT) Received: from alex-virtual-machine (172.16.253.254) by KSBJMAIL2.kingsoft.cn (10.88.1.32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1979.3; Tue, 23 Feb 2021 20:44:37 +0800 Date: Tue, 23 Feb 2021 20:44:36 +0800 From: Aili Yao To: "HORIGUCHI =?UTF-8?B?TkFPWUE=?=(=?UTF-8?B?5aCA5Y+j44CA55u05Lmf?=)" CC: "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" Subject: Re: [PATCH v3] x86/fault: Send a SIGBUS to user process always for hwpoison page access. Message-ID: <20210223204436.1df73153@alex-virtual-machine> In-Reply-To: <20210205170135.22f771a2@alex-virtual-machine> References: <20210201161749.0e8dc212.yaoaili@kingsoft.com> <20210204072555.GA22850@hori.linux.bs1.fc.nec.co.jp> <20210205170135.22f771a2@alex-virtual-machine> Organization: kingsoft X-Mailer: Claws Mail 3.17.5 (GTK+ 2.24.30; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Originating-IP: [172.16.253.254] X-ClientProxiedBy: KSBJMAIL1.kingsoft.cn (10.88.1.31) To KSBJMAIL2.kingsoft.cn (10.88.1.32) X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFprOIsWRmVeSWpSXmKPExsXCFcGooLvuo0mCwa9fVhafN/xjs3ixoZ3R YtpGcYvLu+awWdxb85/V4vyutawWlw4sYLK42HiA0eJ47wEmi82bpjJbvLlwj8Xix4bHrA48 Ht9b+1g8Nq/Q8li85yWTx6ZVnWwemz5NYvd4d+4cu8e8k4EeL65uZPF4v+8qm8fnTXIeJ1q+ sAZwR3HZpKTmZJalFunbJXBlLL08l6ngJVvF9wUZDYx7WbsYOTkkBEwkPj/7yNTFyMUhJDCd SWLmuZmsEM4rRokXb+4wglSxCKhKTH+8hR3EZgOyd92bBdYtIpAksXj2V7BuZoEFLBLz1kIU CQskS5yZ9ACsmVfASuLQ44MsIDangLXEzY2XWCA2LGKU2Pv+JzNIgl9ATKL3yn8miJvsJdq2 LIJqFpQ4OfMJWDOzgI7EiVXHmCFseYntb+eA2UICihKHl/xih+hVkjjSPYMNwo6VWDbvFesE RuFZSEbNQjJqFpJRCxiZVzGyFOemG21ihMRd6A7GGU0f9Q4xMnEwHmKU4GBWEuFlu2uUIMSb klhZlVqUH19UmpNafIhRmoNFSZx36laTBCGB9MSS1OzU1ILUIpgsEwenVAOTiKPksZT0aXaW qZpTTVqaf4V0ruMxN963O+FaQmdXxrXGm5fmNnXWyFiXv9q/8oVEgWiGh2eF+NNZ7QoOjpHu W0yfbZyY+G9+16PSq+zFh5mXRJzfvLi78+l1gULpu+9Da4xto64f27rsEctfEbn9+094bIoR s5n88TrvNvGGc92amwLju8UPTWUxXSj+tH4Fg/exj0z/ohZH8kqbvjhza7V8w3V3x+d6rGcv G0qtTVcLlD2/aUPcRL22G1PKHb/rryvi/y7nPllW+MUk9qfdfluVOP59++n78WJeor7FnsPp 4UrHYg2eOC40NzPa5NqwbfGvhMkGq8WKjoqJC96dWHZf+dPT1E3beHTv769QYinOSDTUYi4q TgQAYhT6lSoDAAA= Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 5 Feb 2021 17:01:35 +0800 Aili Yao wrote: > 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. > > 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. > > Suggested-by: Feng Yang > Signed-off-by: Aili Yao > --- > arch/x86/mm/fault.c | 62 +++++++++++++++++++++++++++++---------------- > 1 file changed, 40 insertions(+), 22 deletions(-) > Hi luto; Is there any feedback? Thanks Aili Yao