Received: by 2002:a25:31c3:0:0:0:0:0 with SMTP id x186csp561812ybx; Tue, 5 Nov 2019 01:54:27 -0800 (PST) X-Google-Smtp-Source: APXvYqx8NkxUA97XahwNyLv1Ef/JEt4V37+vaj0WkGxS0xK9wZx+c+3YGGEMaL3PmlKUvGyQzpVz X-Received: by 2002:a17:906:4d93:: with SMTP id s19mr17593739eju.285.1572947667751; Tue, 05 Nov 2019 01:54:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1572947667; cv=none; d=google.com; s=arc-20160816; b=dX9IQD6+mWHipQPdcbi7uzfOgWt3ieqx1pejSI9aEd4od8CrVUJV9A2TXm1rp5rHyB uhgY56MKbiT7h3++OhKu1PI+k94rct95tDU/3njBJdnaamntqsGigFbrGyNrrbId51uJ c3nYIIShyBJr9P+KAk/1ecgWtRE/rjWNJDvr8HTausyEJ95DknIe/bgCLGEmQtV9nEj9 HRwpwKssqlg8VsSQnlbCObmp07Q16Bc4+VI6l1urVXcxuhPQ8REm+wy9g8UtLoUFqAsq MARXSIz0ikRNmTIoQ9yinqzrkySrHIjj9L6SwPZLaLLBQn5dS7MWnueKKCIiJRzsy/HT 5LlA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:organization:from:references:cc:to:subject :dkim-signature; bh=BGggv342lFx1tfwwl12Nk/iZ58G5iqriqTxQgLV8zo8=; b=VEEehjlFL6jFa7lf8WRnLFYzTXY85xqPzn+ioT/fLki95jjFLhP0J+uvK8m/satjDU gr2XM+GTwfSZtTxfPt5BwQ9uxBNDA9QE0UyBpq30yf9lToc/qcr+ol8AhKrvt35S996Z 6JRnoUronNMZ8aZrR4uL9Y9rbrKVs/an7zAiSOSb+j8sMpMqRTK8pj/b7kt/VevNy+1w q0c5e6y3NI+joC0blW/acHTDG62fDF2JCjcoaPkcRMNAWgfbeNjm2q1ZV4AfO++jqAfY S1yzzYJ1nTjobdaA5wofCCOeOBzAwwaLz+xaxz0eiLzE/mALq0J1erO0H606P6/k591z v1Jg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=RSx8KjZD; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b5si7479205edq.173.2019.11.05.01.54.04; Tue, 05 Nov 2019 01:54:27 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=RSx8KjZD; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388177AbfKEJuP (ORCPT + 99 others); Tue, 5 Nov 2019 04:50:15 -0500 Received: from us-smtp-2.mimecast.com ([205.139.110.61]:31186 "EHLO us-smtp-delivery-1.mimecast.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1730571AbfKEJuO (ORCPT ); Tue, 5 Nov 2019 04:50:14 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1572947413; h=from:from: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; bh=BGggv342lFx1tfwwl12Nk/iZ58G5iqriqTxQgLV8zo8=; b=RSx8KjZD9qbSpR/+JE5qNDBrcu+zkk5Gg3CwxGUhx3aKFvVTTYZQiTzpZw0kmH320VnJwj b65Z8Pwuo07SJ2YJoVeEuAl/tsgQ3aJnocQ+QynGIjeniT/C1q9p00yjdg0pDT3ecVEKjQ TDTT1ibtGPS+n+AImWA+q1Clq797hh0= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-340-SL926ai3PRGUG_s0dpBfZA-1; Tue, 05 Nov 2019 04:50:11 -0500 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 261A0800C73; Tue, 5 Nov 2019 09:50:10 +0000 (UTC) Received: from [10.36.117.253] (ovpn-117-253.ams2.redhat.com [10.36.117.253]) by smtp.corp.redhat.com (Postfix) with ESMTP id B83D060CDA; Tue, 5 Nov 2019 09:50:08 +0000 (UTC) Subject: Re: [PATCH v2] mm/memory-failure.c: replace with page_shift() in add_to_kill() To: Yunfeng Ye , n-horiguchi@ah.jp.nec.com Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, "hushiyuan@huawei.com" , "linfeilong@huawei.com" References: <543d8bc9-f2e7-3023-7c35-2e7ed67c0e82@huawei.com> From: David Hildenbrand Organization: Red Hat GmbH Message-ID: Date: Tue, 5 Nov 2019 10:50:07 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.1.1 MIME-Version: 1.0 In-Reply-To: <543d8bc9-f2e7-3023-7c35-2e7ed67c0e82@huawei.com> Content-Language: en-US X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-MC-Unique: SL926ai3PRGUG_s0dpBfZA-1 X-Mimecast-Spam-Score: 0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 05.11.19 10:38, Yunfeng Ye wrote: > The function page_shift() is supported after the commit 94ad9338109f > ("mm: introduce page_shift()"). >=20 > So replace with page_shift() in add_to_kill() for readability. >=20 > Signed-off-by: Yunfeng Ye > Reviewed-by: David Hildenbrand > Acked-by: Naoya Horiguchi > --- > v1 -> v2: > - add Reviewed-by and Acked-by Note for the future: No need to resend if there were no=20 code/documentation changes. Andrew will apply the tags when picking up=20 the patch. >=20 > mm/memory-failure.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) >=20 > diff --git a/mm/memory-failure.c b/mm/memory-failure.c > index 3151c87dff73..e48c50cac889 100644 > --- a/mm/memory-failure.c > +++ b/mm/memory-failure.c > @@ -326,7 +326,7 @@ static void add_to_kill(struct task_struct *tsk, stru= ct page *p, > =09if (is_zone_device_page(p)) > =09=09tk->size_shift =3D dev_pagemap_mapping_shift(p, vma); > =09else > -=09=09tk->size_shift =3D compound_order(compound_head(p)) + PAGE_SHIFT; > +=09=09tk->size_shift =3D page_shift(compound_head(p)); >=20 > =09/* > =09 * Send SIGKILL if "tk->addr =3D=3D -EFAULT". Also, as >=20 --=20 Thanks, David / dhildenb