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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id AD091C433FE for ; Tue, 18 Oct 2022 06:21:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229796AbiJRGVT (ORCPT ); Tue, 18 Oct 2022 02:21:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36446 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229630AbiJRGVQ (ORCPT ); Tue, 18 Oct 2022 02:21:16 -0400 Received: from szxga03-in.huawei.com (szxga03-in.huawei.com [45.249.212.189]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DFE9168CD4 for ; Mon, 17 Oct 2022 23:21:14 -0700 (PDT) Received: from canpemm500002.china.huawei.com (unknown [172.30.72.55]) by szxga03-in.huawei.com (SkyGuard) with ESMTP id 4Ms3Zz0YxtzJn2G; Tue, 18 Oct 2022 14:18:35 +0800 (CST) Received: from [10.174.151.185] (10.174.151.185) by canpemm500002.china.huawei.com (7.192.104.244) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Tue, 18 Oct 2022 14:21:12 +0800 Subject: Re: [PATCH V3 1/1] x86/sgx: Add code to inject hwpoison into SGX memory To: Thomas Tai References: <20221017223305.578073-1-thomas.tai@oracle.com> <20221017223305.578073-2-thomas.tai@oracle.com> From: Miaohe Lin CC: , , , , , , , Message-ID: <4a7c4187-5df3-f153-189b-62fae7de4cd2@huawei.com> Date: Tue, 18 Oct 2022 14:21:12 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.6.0 MIME-Version: 1.0 In-Reply-To: <20221017223305.578073-2-thomas.tai@oracle.com> Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.174.151.185] X-ClientProxiedBy: dggems701-chm.china.huawei.com (10.3.19.178) To canpemm500002.china.huawei.com (7.192.104.244) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2022/10/18 6:33, Thomas Tai wrote: > Inspired by commit c6acb1e7bf46 ("x86/sgx: Add hook to error injection > address validation"), add a similar code in hwpoison_inject function to > check if the address is located in SGX Memory. The error will then be > handled by the arch_memory_failure function in the SGX driver. After > injection, the action_result() will print out the page type and the > action taken. > > Signed-off-by: Thomas Tai Many thanks for your work. The patch looks good to me. Reviewed-by: Miaohe Lin Thanks, Miaohe Lin