Received: by 2002:a25:31c3:0:0:0:0:0 with SMTP id x186csp1503654ybx; Thu, 7 Nov 2019 12:49:32 -0800 (PST) X-Google-Smtp-Source: APXvYqyWXU38CzYGm+J1sqKutxy4oHv0O7L9cbnmip1I488Z5QQSxjaeo39H8eAHGeEdeQANKu+C X-Received: by 2002:a17:906:448e:: with SMTP id y14mr5297740ejo.136.1573159772499; Thu, 07 Nov 2019 12:49:32 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1573159772; cv=none; d=google.com; s=arc-20160816; b=UkD/SfTjlCIVjsdu4eDwBQI4ixO6v8P1BF34qxovA+Q7+PoCReSgCPCqfSUIWNXtcN q5wVRyLnKEbAC0tdfu6arQWCGA5HOrB53OhQSHxQXL5SxRjeoAOU34tcJL5FEkPDghR2 PIGqVdWYW+SX8wmtIMmtvgtiWDCv90kz2WOis1G1jlrPzvYJwTuhREIXXIjMbMJRFyrM rjcn1fGIvRclo121optg+2S3r6aUu9Nk/lvU0t5WGGmOHtcmrXFNPfiea9Iv+fc5IJ3V vjFRySirAUsgrO5ZCI0/R+hwQXGPyiSobIn1Ty9DUwGNV1q+Xtwbe/kgfoGxeqdXwvZG R80Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :message-id:in-reply-to:subject:cc:to:from:date:dkim-signature; bh=JwhsjFXL+RY1sUbjvE8fwB+ZL/JKNehRxoaYrePu9kQ=; b=bFjnKaWGiXhqnbwoS4BcJztZKaFrehBwuCtZpTJ0cZTO9JU+wHUwavstiJQmiWYWg8 pCcRZ3MrQb1StwZt0d7Fp6a6IF4aH3kQhG7nSmZAMZ1iZ4Uk7tzZhJ2PRaTfjRVJ/6hL rYGmq3qIZ51p2pNw1G0pD0hOZXVuT4nEKJc1ykDNdrfRjX6v0NDnSiuh4xkiB+5r3Im6 p1uM7gaxI+SejvakSZxOwNWiGcPJy5ypRz/P5lk19R3usWWxbuk9ZaF40+VG0Wxw/mZJ sQaqCuFeEf+qy/ir/oYdCMxNyUPKh269f56JOssC0K/rRJvfQn3fTbzwqFLoz+Msx+cW lWsQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=Db4tHNgn; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c5si2217847eja.205.2019.11.07.12.49.09; Thu, 07 Nov 2019 12:49:32 -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=@google.com header.s=20161025 header.b=Db4tHNgn; 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=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727295AbfKGUsM (ORCPT + 99 others); Thu, 7 Nov 2019 15:48:12 -0500 Received: from mail-pl1-f196.google.com ([209.85.214.196]:46035 "EHLO mail-pl1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725497AbfKGUsL (ORCPT ); Thu, 7 Nov 2019 15:48:11 -0500 Received: by mail-pl1-f196.google.com with SMTP id y24so2392094plr.12 for ; Thu, 07 Nov 2019 12:48:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:from:to:cc:subject:in-reply-to:message-id:references :user-agent:mime-version; bh=JwhsjFXL+RY1sUbjvE8fwB+ZL/JKNehRxoaYrePu9kQ=; b=Db4tHNgnwbiKUQQBjTMR0BNEUAL8a5ipvo2TbmNtUEJbzAu8RlKa6uhhd5aFftsQ0T F4kd7FDyZGOMI1Jn2Ady7sMtkff3mQU5vj21YIKxUIDWe3mzZA+e2X3wS6qaGGdo2h6j CROaJhOezoBE5fyBtHxs0z4+m6jtUiaouXO/grqPU5yi+nh4h0QkiXgnwZyOQo7Wu/NY PtN954C/mOUI18lQP053JcZVOAXNb6cMnHnnYCvkt/1qKusp5e3xS3DJ7Z3zaUHYNncM JA0jxdur16ge7pCLtb7FNHEzIT9TyQAV4U/oSnXGprSYOEtFh4UYNhj/re2T87B6uuwZ CFvw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:in-reply-to:message-id :references:user-agent:mime-version; bh=JwhsjFXL+RY1sUbjvE8fwB+ZL/JKNehRxoaYrePu9kQ=; b=T4tsNYyx7ItlNL9l9kAKeCzodVnMROMYqhrmllyMWTxP/k4am6I/IeIujCeoVAtv/Z 2ayQTL55h7ETZbt048Mhcxg/+b72udOOSbsCwyB8AfMQNGvRRBMLjS/R9Rm3qzCXJ3Y7 S6nXw+TlculHBF1t0WJkDn/jMJkuJfbIxXIrPzpPCuwUSYUBqcxRX7psVODHZuKdSSTl gUD9TiTwedAslHmKsErt16ErnGk/CCHLZmAeqpTaPw45Boq3cBZxJm11YU+EJlhnZCkB YHBKFTaO5LyAq7h+UrDqn4FvoZaBqDhVZYPHQTNqPrFLFXx4aQH2/3Fy+RP11N4RANAE GPBg== X-Gm-Message-State: APjAAAUceZ+tYHildblFvt9K5oE8OOXEuexRtFKBAQ6ShgH+ErpbbVkA hftdGZSSTRqquieuY1EAkstyjQ== X-Received: by 2002:a17:902:a508:: with SMTP id s8mr5955147plq.26.1573159690626; Thu, 07 Nov 2019 12:48:10 -0800 (PST) Received: from [2620:15c:17:3:3a5:23a7:5e32:4598] ([2620:15c:17:3:3a5:23a7:5e32:4598]) by smtp.gmail.com with ESMTPSA id h9sm4965652pjh.8.2019.11.07.12.48.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Nov 2019 12:48:09 -0800 (PST) Date: Thu, 7 Nov 2019 12:48:09 -0800 (PST) From: David Rientjes X-X-Sender: rientjes@chino.kir.corp.google.com To: Yunfeng Ye cc: akpm@linux-foundation.org, jgg@ziepe.ca, mhocko@suse.com, jglisse@redhat.com, minchan@kernel.org, peterz@infradead.org, jack@suse.cz, rppt@linux.ibm.com, linux-mm@kvack.org, linux-kernel@vger.kernel.org, "hushiyuan@huawei.com" , "linfeilong@huawei.com" Subject: Re: [PATCH] mm/madvise: replace with page_size() in madvise_inject_error() In-Reply-To: <7296c9ca-f8a7-f31b-d090-cc6bf5ee1df4@huawei.com> Message-ID: References: <29dce60c-38d6-0220-f292-e298f0c78c4d@huawei.com> <7296c9ca-f8a7-f31b-d090-cc6bf5ee1df4@huawei.com> User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 7 Nov 2019, Yunfeng Ye wrote: > >> The function page_size() is supported after the commit a50b854e073c > >> ("mm: introduce page_size()"). > >> > >> Replace with page_size() in madvise_inject_error() for readability. > >> > >> Signed-off-by: Yunfeng Ye > >> --- > >> mm/madvise.c | 8 ++++---- > >> 1 file changed, 4 insertions(+), 4 deletions(-) > >> > >> diff --git a/mm/madvise.c b/mm/madvise.c > >> index 2be9f3fdb05e..38c4e7fcf850 100644 > >> --- a/mm/madvise.c > >> +++ b/mm/madvise.c > >> @@ -856,13 +856,13 @@ static int madvise_inject_error(int behavior, > >> { > >> struct page *page; > >> struct zone *zone; > >> - unsigned int order; > >> + unsigned int size; > > > > Should be unsinged long. > > > ok, thanks. Andrew has already help me modify the patch and add to -mm tree. > Good deal, in that case: Acked-by: David Rientjes