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 X-Spam-Level: X-Spam-Status: No, score=-3.9 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,T_DKIMWL_WL_HIGH autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id EC30BC4321A for ; Tue, 11 Jun 2019 00:23:04 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id B8BEA2086A for ; Tue, 11 Jun 2019 00:23:04 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=oracle.com header.i=@oracle.com header.b="d4F1P2X1" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390320AbfFKAUD (ORCPT ); Mon, 10 Jun 2019 20:20:03 -0400 Received: from userp2120.oracle.com ([156.151.31.85]:48192 "EHLO userp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388749AbfFKAUC (ORCPT ); Mon, 10 Jun 2019 20:20:02 -0400 Received: from pps.filterd (userp2120.oracle.com [127.0.0.1]) by userp2120.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x5B09Qak178531; Tue, 11 Jun 2019 00:19:51 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=subject : to : cc : references : from : message-id : date : mime-version : in-reply-to : content-type : content-transfer-encoding; s=corp-2018-07-02; bh=SN1DHavmoz1vQkJTLVb+wvWfnTmq3aQZzTCx5KVXGak=; b=d4F1P2X1cdzomcjxDD8rWoT8K4BELOdxfIPlPmW8bMauny6na8dpFxQ0mDkhCrEYuRrw FkmZvsbz3d2Y7Hc/dzhaVpLL4sXE4fQmHKq+ZeCRr30/Y735i+AjuxdAolrKfmuR3yRP nxGd5Z91iaIMAHXSWJ9TRGmQOV08dS0KRFsn1SEWuuV54ukLz+GMBo5kd3DaMVtAWhSU ryutHlUL3j1oGSqoNkuqFA439H5ECkXF1QsFZaWb76MqivRXDamIHR/WuQ+oaoqDiOe0 JJefijaTqIN7ZNWUsCrmQv1Kusjse86kPgk9l/uxSxqE3i3kJ2wKDyXBVW5d4FADRWTB kA== Received: from aserp3020.oracle.com (aserp3020.oracle.com [141.146.126.70]) by userp2120.oracle.com with ESMTP id 2t05nqhtk4-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 11 Jun 2019 00:19:51 +0000 Received: from pps.filterd (aserp3020.oracle.com [127.0.0.1]) by aserp3020.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x5B0IEM0043654; Tue, 11 Jun 2019 00:19:50 GMT Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by aserp3020.oracle.com with ESMTP id 2t0p9r0a6x-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 11 Jun 2019 00:19:50 +0000 Received: from abhmp0009.oracle.com (abhmp0009.oracle.com [141.146.116.15]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id x5B0JlsJ032551; Tue, 11 Jun 2019 00:19:47 GMT Received: from [192.168.1.222] (/71.63.128.209) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Mon, 10 Jun 2019 17:19:46 -0700 Subject: Re: [PATCH v2 1/2] mm: soft-offline: return -EBUSY if set_hwpoison_free_buddy_page() fails To: Naoya Horiguchi , linux-mm@kvack.org Cc: Andrew Morton , Michal Hocko , xishi.qiuxishi@alibaba-inc.com, "Chen, Jerry T" , "Zhuo, Qiuxu" , linux-kernel@vger.kernel.org References: <1560154686-18497-1-git-send-email-n-horiguchi@ah.jp.nec.com> <1560154686-18497-2-git-send-email-n-horiguchi@ah.jp.nec.com> From: Mike Kravetz Message-ID: <8e8e6afc-cddb-9e79-c8ae-c2814b73cbe9@oracle.com> Date: Mon, 10 Jun 2019 17:19:45 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 In-Reply-To: <1560154686-18497-2-git-send-email-n-horiguchi@ah.jp.nec.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9284 signatures=668687 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=2 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1906110000 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9284 signatures=668687 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=2 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1906110000 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 6/10/19 1:18 AM, Naoya Horiguchi wrote: > The pass/fail of soft offline should be judged by checking whether the > raw error page was finally contained or not (i.e. the result of > set_hwpoison_free_buddy_page()), but current code do not work like that. > So this patch is suggesting to fix it. > > Signed-off-by: Naoya Horiguchi > Fixes: 6bc9b56433b76 ("mm: fix race on soft-offlining") > Cc: # v4.19+ Reviewed-by: Mike Kravetz To follow-up on Andrew's comment/question about user visible effects. Without this fix, there are cases where madvise(MADV_SOFT_OFFLINE) may not offline the original page and will not return an error. Are there any other visible effects? -- Mike Kravetz