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=-1.0 required=3.0 tests=MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=no 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 83DDCC2D0CE for ; Tue, 21 Jan 2020 08:43:56 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 4D01222522 for ; Tue, 21 Jan 2020 08:43:56 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 4D01222522 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 009D56B0006; Tue, 21 Jan 2020 03:43:56 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id EADF06B0007; Tue, 21 Jan 2020 03:43:55 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id D4F3B6B0008; Tue, 21 Jan 2020 03:43:55 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0253.hostedemail.com [216.40.44.253]) by kanga.kvack.org (Postfix) with ESMTP id BA8D86B0006 for ; Tue, 21 Jan 2020 03:43:55 -0500 (EST) Received: from smtpin26.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with SMTP id 7C81A8248076 for ; Tue, 21 Jan 2020 08:43:55 +0000 (UTC) X-FDA: 76401003630.26.boats12_223a5eeea4d41 X-HE-Tag: boats12_223a5eeea4d41 X-Filterd-Recvd-Size: 3261 Received: from mail-wm1-f68.google.com (mail-wm1-f68.google.com [209.85.128.68]) by imf39.hostedemail.com (Postfix) with ESMTP for ; Tue, 21 Jan 2020 08:43:55 +0000 (UTC) Received: by mail-wm1-f68.google.com with SMTP id p17so2031510wma.1 for ; Tue, 21 Jan 2020 00:43:54 -0800 (PST) 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:message-id:references :mime-version:content-disposition:in-reply-to; bh=p1miCEumvBZXojM3ziPoJ3SDCJDQgzFEnuJYN1G9228=; b=K4pavdnwe1kxr2dffVOorPmocroTrvlprnrFUsplrpWVApnYYob9nK77xadB8ysJS2 FhxVnSwX3/j6yXdRDgCv4TeerUk2aG0pNvKJLsL7Y4Pscchh+pgAYU8DLQsN1u1f625H i/C2lETyp6uz9kn+4UFbE+Mx6RYziRA/83nC3l06JuVwiyE8DhtbgBi481F5eNTCrmkH eJlc4iIIKdeyzU5TsrWMHyouRFGe7UqQgFOeEX36keSGjbD6MPqFKShdtFy3R/WoTNl6 kcNN8YWiHpz8GDSvIUkX8IGuGydwtwo6NDG0VPLH+k79HEc3T83VmOzrfmkNUgiYRbfp V7Ww== X-Gm-Message-State: APjAAAUdzBLOD57XQqr02Jlb3/xCbeKnAfpAot/fl/lkEB4LU/nLtM/D PE/EZPNdFbrNnkW+rzy3Api5kiSm X-Google-Smtp-Source: APXvYqwYudapVU8PoPSwbA44q1zIHoW7i923mC1fEQEvAPemabET9G4XEzRgom6tH9Wi1RBaQ+1ACg== X-Received: by 2002:a1c:a50e:: with SMTP id o14mr3086072wme.2.1579596234154; Tue, 21 Jan 2020 00:43:54 -0800 (PST) Received: from localhost (prg-ext-pat.suse.com. [213.151.95.130]) by smtp.gmail.com with ESMTPSA id f12sm3048208wmf.28.2020.01.21.00.43.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 21 Jan 2020 00:43:53 -0800 (PST) Date: Tue, 21 Jan 2020 09:43:52 +0100 From: Michal Hocko To: Wei Yang Cc: akpm@linux-foundation.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, yang.shi@linux.alibaba.com Subject: Re: [PATCH 7/8] mm/migrate.c: move page on next iteration Message-ID: <20200121084352.GE29276@dhcp22.suse.cz> References: <20200119030636.11899-1-richardw.yang@linux.intel.com> <20200119030636.11899-8-richardw.yang@linux.intel.com> <20200120100203.GR18451@dhcp22.suse.cz> <20200121012200.GA1567@richard> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200121012200.GA1567@richard> X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Tue 21-01-20 09:22:00, Wei Yang wrote: > On Mon, Jan 20, 2020 at 11:02:03AM +0100, Michal Hocko wrote: > >On Sun 19-01-20 11:06:35, Wei Yang wrote: > >> When page is not successfully queued for migration, we would move pages > >> on pagelist immediately. Actually, this could be done in the next > >> iteration by telling it we need some help. > >> > >> This patch adds a new variable need_move to be an indication. After > >> this, we only need to call move_pages_and_store_status() twice. > > > >No! Not another iterator. There are two and this makes the function > >quite hard to follow already. We do not want to add a third one. > > > > Two iterators here are? I don't get your point. i is the main iterator to process the whole imput. start is another one to control the batch to migrate. We do not need/want more. More clear? -- Michal Hocko SUSE Labs