Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp4530210ybz; Tue, 21 Apr 2020 02:14:46 -0700 (PDT) X-Google-Smtp-Source: APiQypKDoEaKWxLZSYbEQn7zO2I5oPY8Zrdpqlnslxz/tanE4Bod6tQ45zhzd+MGKgQP+Z8vNr1Y X-Received: by 2002:a17:906:d291:: with SMTP id ay17mr20417972ejb.183.1587460486585; Tue, 21 Apr 2020 02:14:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1587460486; cv=none; d=google.com; s=arc-20160816; b=waLyNU6qRlB9oi9r6V3r6L6zYGoQI7CDPE7tynBaIP9b303nySEn2j4p74dFFYcCas bEh+J6/chf/uNEr4ihogJBD3DluDWZ24uxWS5xljrVLn/x5vRFzUOWavvyTm2pLAbYL8 U84aomVL2x8cabhgTsWGCH/fZeCOFUuoP6wfLPW8Za31KdlnIQJTug8YOF+kuGLnXiAR ewJ+0my9DuKX6XyJ5S7E7ruptoFhiZe7dLbBnZnJ6G2ItmNhdM+wYtxVfpkCpEC0VXvg /FI0PC5XXfQI2deSeqUafGQne6Un9Dk61mBFtmpU/rpXZyhH9PaNsK+gTWBOUt/wJ9Un X0jA== 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:in-reply-to :mime-version:user-agent:date:message-id:from:references:cc:to :subject; bh=nr8derKhEV++bOSbiqBtpTwCDaHdUl08AjeyueUgzmk=; b=cMG0WHhpa7W+YbibX6GA/tIDbb4hjK/WcvZAA1fTL2VHs72NQWH7bMr7QNXLdVbbAJ h+Q9kp/Hi6dHq8FoOfu+LOviiZw+7Fxxpi/ss58EDQeYxz0eorV1ubuxyVsMAX57WVCM 7eSmJSa/1cynOcNykgntmKiRPzt0T6qAuqgdksl/hO7hiKQ8bkV7SY5a+ZbKlZkrLL5E UuX6AFgEuIWsCyVxH7nGpvz82ZUthssKZt6AFSG7Z+J5UkxGAzC2ZCRfBPLPiPtfjSR8 PBKqWsJQqHJ3PSeWE1XWL6sfbt4MVIUq1Koemp9HjJvEoEby92s4Ri+/AboDKpMoE+9S 8Hhw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id n26si1222095ejy.188.2020.04.21.02.14.24; Tue, 21 Apr 2020 02:14:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728335AbgDUJMq (ORCPT + 99 others); Tue, 21 Apr 2020 05:12:46 -0400 Received: from out30-43.freemail.mail.aliyun.com ([115.124.30.43]:48645 "EHLO out30-43.freemail.mail.aliyun.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726018AbgDUJMq (ORCPT ); Tue, 21 Apr 2020 05:12:46 -0400 X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R711e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=e01e01419;MF=alex.shi@linux.alibaba.com;NM=1;PH=DS;RN=11;SR=0;TI=SMTPD_---0TwDj0Hd_1587460361; Received: from IT-FVFX43SYHV2H.local(mailfrom:alex.shi@linux.alibaba.com fp:SMTPD_---0TwDj0Hd_1587460361) by smtp.aliyun-inc.com(127.0.0.1); Tue, 21 Apr 2020 17:12:42 +0800 Subject: Re: [PATCH 04/18] mm: memcontrol: move out cgroup swaprate throttling To: Johannes Weiner , Joonsoo Kim Cc: Shakeel Butt , Hugh Dickins , Michal Hocko , "Kirill A. Shutemov" , Roman Gushchin , linux-mm@kvack.org, cgroups@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-team@fb.com References: <20200420221126.341272-1-hannes@cmpxchg.org> <20200420221126.341272-5-hannes@cmpxchg.org> From: Alex Shi Message-ID: <37002d8a-1711-4ec7-af57-1072a397ced3@linux.alibaba.com> Date: Tue, 21 Apr 2020 17:11:35 +0800 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:68.0) Gecko/20100101 Thunderbird/68.6.0 MIME-Version: 1.0 In-Reply-To: <20200420221126.341272-5-hannes@cmpxchg.org> Content-Type: text/plain; charset=gbk Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org ?? 2020/4/21 ????6:11, Johannes Weiner ะด??: > The cgroup swaprate throttling is about matching new anon allocations > to the rate of available IO when that is being throttled. It's the io > controller hooking into the VM, rather than a memory controller thing. > > Rename mem_cgroup_throttle_swaprate() to cgroup_throttle_swaprate(), > and drop the @memcg argument which is only used to check whether the > preceding page charge has succeeded and the fault is proceeding. > > We could decouple the call from mem_cgroup_try_charge() here as well, > but that would cause unnecessary churn: the following patches convert > all callsites to a new charge API and we'll decouple as we go along. > > Signed-off-by: Johannes Weiner Reviewed-by: Alex Shi