Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp2169967ybi; Sun, 9 Jun 2019 05:31:13 -0700 (PDT) X-Google-Smtp-Source: APXvYqzop3J7lXavFCCH8RfjmtTBAoA2ChjV3uF6G+02ZMh0mV2KrX7zuqCYh9Ja2bRv0aLYnJXn X-Received: by 2002:a62:2a0a:: with SMTP id q10mr65750705pfq.79.1560083473237; Sun, 09 Jun 2019 05:31:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560083473; cv=none; d=google.com; s=arc-20160816; b=Wzan7ZbLwqPQWXss4tGhpCFeu6UM1v6Z22+LRzQlzmjFN8Tcc8z+EPA/mbhNVBCbDp Qur94uGpxTYjwiv+Df1D1UU4yCR/ckdB0Smu3sJuI77AAD9wsF2tiHXOsytJrcR0jT7i 7/pWYfxkSPpuErhBxvWsDlqD9TrUUH47N0eSg7Kj0BzMbhvc0HF9ir3X/gwO7hYuipHy WfTcBNSGv7m4NGCewFSSRQaJ7DS+L2dYtg1zF/FL76oplIp30O7IbIdQyaMtE/Mdgjmz Z2wYSQRUsyENg55lcb5wQfOoDFBrlIYs3MXBkCvE2t3s/GzTn/JJJ5hXp7n7odAtpPn7 guuQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=MXL4qzS5tDYfPtk0bERwMQ8xPqTAnXucMreBi2SqrNs=; b=m7NEXlcAEtuWvg2KuN/Y2Wen+yaY3n5JT2r/OQNCs9JcB9pUWow/ElHL5zsDn2n7aT RAsS0k0JjchFBzZ0k3IDhUUNA0Fa/c4GJxCWvYH4vsydLW7Fw0OmDzb6RUhakhW8eEW3 yb1yohyt6buumVtLXPne2GSJjOHLMUfbIGEpTmRzS89biBoVAOMi3iVcCNfn16gKkE6r KjDiquwknn5me/tbkX5P1Yzv17fLJreoQPvfpRHLEk8BF5KRQ54chbnp7nniN5d0Lb1C 74x50brvaCcZBX+BAewpZNxI6IYD8zg6LogTXL09YIO0ZqfHFQ5FkNf20sy6GcvPnTjB IDpw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=mCVFoo7u; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f193si7467258pgc.144.2019.06.09.05.30.57; Sun, 09 Jun 2019 05:31:13 -0700 (PDT) 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=@gmail.com header.s=20161025 header.b=mCVFoo7u; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728471AbfFIM3N (ORCPT + 99 others); Sun, 9 Jun 2019 08:29:13 -0400 Received: from mail-lj1-f193.google.com ([209.85.208.193]:37593 "EHLO mail-lj1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726874AbfFIM3M (ORCPT ); Sun, 9 Jun 2019 08:29:12 -0400 Received: by mail-lj1-f193.google.com with SMTP id 131so5488404ljf.4 for ; Sun, 09 Jun 2019 05:29:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=MXL4qzS5tDYfPtk0bERwMQ8xPqTAnXucMreBi2SqrNs=; b=mCVFoo7ulhKZFDXXA5kN2vuD7BliZW2iWtD8iSLmPJm8KpLV02zs2ncV98/tWXuqGm 7M0CPaYeUnWZLMHghcjDl7bEeD0p1c1YUW84Vn99W5QD5MY/eWHY8Bnd6ga7oUgs3yWB 31zs/BymNy8XV61jusfjmH4lZ6gat/66JzJzCZ3jfhRDIv+ASGIj/qwYNNVtuJf3nMcw h5NX7BoOxyjemzkNlZ6d7rWXtPJRWdbwJGecgDqOj0jsL4LRKwN8KpozzX0T/mwKHXAe 8ooHbKQqo659Ur68uoPngVZi18rJw9C+/4r1LaP1I3a9e6xAlxP0+BgVCGfAwIeN60lC aHUg== 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=MXL4qzS5tDYfPtk0bERwMQ8xPqTAnXucMreBi2SqrNs=; b=bwHkn5EFwVEsAPraPXaM6Sb9UlwDoLHK+gSXkx8xm46ALVMP/Li2JhfB0lBeif+TOc mTsnir0PxXlA8VhWh8PDFz6/xVwjcENY8mtUSVYOcYwlQnGN7cMcMhc2vHfJFtCe2nFN d5UUMWxxvPMYcTB+8uPWK9T4rcKCQOQaVU6jlID/1B1L42MzcpsnA66Sroiha0JiBngq 4PfddVNtxUF2X3H8Mk1tcKF41xYYk4mfgBLOx2n1fu7LkisLbU+xjYWXorYyQLhY8+xj PkL5txBfIZAwnWzs5jATxPuJb2lJ8+ODrSsmaZbuXAyKJgftNr3PqodnExaZHVm4N3EM +ZFw== X-Gm-Message-State: APjAAAXGD2hIcLgduAIctdxmgoCYnMJWdCDaRruhkSZ3D6SusPxn+OMj 5in2Y6NEhYO2IoKc/2WoG3g= X-Received: by 2002:a2e:86d1:: with SMTP id n17mr10475622ljj.58.1560083350819; Sun, 09 Jun 2019 05:29:10 -0700 (PDT) Received: from esperanza ([176.120.239.149]) by smtp.gmail.com with ESMTPSA id 137sm1337886ljj.46.2019.06.09.05.29.09 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sun, 09 Jun 2019 05:29:09 -0700 (PDT) Date: Sun, 9 Jun 2019 15:29:07 +0300 From: Vladimir Davydov To: Roman Gushchin Cc: Andrew Morton , linux-mm@kvack.org, linux-kernel@vger.kernel.org, kernel-team@fb.com, Johannes Weiner , Shakeel Butt , Waiman Long Subject: Re: [PATCH v6 05/10] mm: introduce __memcg_kmem_uncharge_memcg() Message-ID: <20190609122907.glceyxdaexmau74f@esperanza> References: <20190605024454.1393507-1-guro@fb.com> <20190605024454.1393507-6-guro@fb.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190605024454.1393507-6-guro@fb.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jun 04, 2019 at 07:44:49PM -0700, Roman Gushchin wrote: > Let's separate the page counter modification code out of > __memcg_kmem_uncharge() in a way similar to what > __memcg_kmem_charge() and __memcg_kmem_charge_memcg() work. > > This will allow to reuse this code later using a new > memcg_kmem_uncharge_memcg() wrapper, which calls > __memcg_kmem_uncharge_memcg() if memcg_kmem_enabled() > check is passed. > > Signed-off-by: Roman Gushchin > Reviewed-by: Shakeel Butt Acked-by: Vladimir Davydov