Received: by 2002:ac0:950c:0:0:0:0:0 with SMTP id f12csp2248109imc; Tue, 12 Mar 2019 09:51:03 -0700 (PDT) X-Google-Smtp-Source: APXvYqxAFcv3HyLJXvAv6IjFU8EYfVnj4muab0HNGlmCx34ZJWZtiIunlETkd1zp9eGR+KyqMgZi X-Received: by 2002:a17:902:8697:: with SMTP id g23mr41455900plo.30.1552409463745; Tue, 12 Mar 2019 09:51:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1552409463; cv=none; d=google.com; s=arc-20160816; b=GXu4wrH9PqkmYqESaJbtQKNuukYSsyeh4tqWJcVdv3u4czRdWXYLTB2XKEU5ax/2Xj ztf5EY2/rpCabZp1mIasJYSlwVy8yNuC7mGn2PJdyXIez5B99TXvxmsFZDf8mUjVuIEc 227KUc5It/qyEbcVtI5h1PLqTMvR0Hy+wzJ8MhuRnncJBkMsvZAT9LWaWEW3pOX+mBha dYMLmuRXT55JZ1u5KbECQiRfhH9zgWqnVLsf/oPSx82mbWzRfkYofsinBZZiaBPjphYD eZ855t/ihUeHQuVbTtM/ByIv9kmcWG9tY1z9WT7o2gjDqTgfYSlVEs3FnZnIxWCgih+d 4new== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=Vn5wNO/WHCHX81GlqPviWQYIH5Lzg6cde82VdIWJCjc=; b=CZhPkRCXqgrlV+88mBxUZealYqZz2uaVPNdW+Yai7H79b9/sSEIOPNoHhCjQHEeJtp x4+QKgTODTG1hfJ4u5VvwWdB7U7oxjSvlFfiWVXmBLvArAVPNW9Rw7H9at+KfltcqyvM AihrnxzxpZ3C7Ju4jiG0Stcb5wuMBOTTP/9+6jlxdE/No12FDuNitcf3qcOle8tTDw5P 1N7a28j2RcPemNdy0sueE/hSQ3mHI34K1tuqAOfJxQvbogYnNyfAIi+D89AbSmOyjuki nbGZn6lT7sjkXXNIprhrnVrd+zbKFVwFSHB3dpolqrgPYEsMLZgqBrTCsXjWWh43Pu2w d6CA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=deYxp5Ec; 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 h9si2428268pfj.70.2019.03.12.09.50.48; Tue, 12 Mar 2019 09:51:03 -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=deYxp5Ec; 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 S1726783AbfCLQsm (ORCPT + 99 others); Tue, 12 Mar 2019 12:48:42 -0400 Received: from mail-io1-f65.google.com ([209.85.166.65]:35392 "EHLO mail-io1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726141AbfCLQsm (ORCPT ); Tue, 12 Mar 2019 12:48:42 -0400 Received: by mail-io1-f65.google.com with SMTP id x4so2704307ion.2 for ; Tue, 12 Mar 2019 09:48:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Vn5wNO/WHCHX81GlqPviWQYIH5Lzg6cde82VdIWJCjc=; b=deYxp5EciTonLP20GiipCn6zYpT6i3uEQqvqeLMYjvljhs47mCzzshPuTtD8RSDDVS Pe7MV5S+CwfbZM+r6pMsbsS0WOifN0FMUMGTwUc94CCm6FcnEtggJXVUycXIYHws+449 0lVcQujc+6IwJAHtFZFxD59LGeagXWdVpo5bB/271Z1FWOXeG/9wiW1ZnwSetXGcDY0T xT+mfiJ0vREY5611ZF1EzHYIzkHlifo9JphZnFKlUar6xkC6EyYpqd3vVUtvUXM8L9wz 8r+TZEsQxteBO/6pd2qFsxlhzPmfzAs/P6XOA+eK6KegArqBWnO7Gr/OnwZnQx3aPQpn VVBg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Vn5wNO/WHCHX81GlqPviWQYIH5Lzg6cde82VdIWJCjc=; b=p3A6rgRXQeTjCuoJGmu3JS+4h2nEtTN/henvLgUXkKMXAJZYjJQygxM/S2W8hMsMU6 PW7DGbLjZ37AhP17q0mY1qbI+ydFJIjIml5oUzfpumaWEkTdObaXdlQ+kz4IVMMU9bKF ORBF5MT4Qeza1oYEoyl4BuT6ce7PpC6J97o6Acl4zE/dIfUa9SZzOCOlU9hssvRVfNpY P8HINXHrKKEQo7b0DoY7BIVDqzmjRDwuQwDklMmB0H3qAjJXXaJ+hlEHz6Ofm01MHwSs fw1MNwNdLyCmgoveCP2cruOy9wZPQiwhGJT9QBTXGyt53KYV3s+UfAJpHBknvh6Vco+w Azuw== X-Gm-Message-State: APjAAAWFg3JWi3tPAoSNLU7g5Mq3ngd4Cq5isa4R5Ud6StR/0iZN9joc B9MQKts9bEG1UjddNQPf39NhEwF4XMGG2lGN69o= X-Received: by 2002:a6b:e50d:: with SMTP id y13mr326423ioc.142.1552409321489; Tue, 12 Mar 2019 09:48:41 -0700 (PDT) MIME-Version: 1.0 References: <1551501538-4092-1-git-send-email-laoar.shao@gmail.com> <1551501538-4092-2-git-send-email-laoar.shao@gmail.com> <20190312161803.GC5721@dhcp22.suse.cz> <20190312164422.GD5721@dhcp22.suse.cz> In-Reply-To: <20190312164422.GD5721@dhcp22.suse.cz> From: Yafang Shao Date: Wed, 13 Mar 2019 00:48:05 +0800 Message-ID: Subject: Re: [PATCH] mm: compaction: some tracepoints should be defined only when CONFIG_COMPACTION is set To: Michal Hocko Cc: Vlastimil Babka , Souptick Joarder , Andrew Morton , Linux MM , LKML , shaoyafang@didiglobal.com Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Mar 13, 2019 at 12:44 AM Michal Hocko wrote: > > On Wed 13-03-19 00:29:57, Yafang Shao wrote: > > On Wed, Mar 13, 2019 at 12:18 AM Michal Hocko wrote: > > > > > > On Sat 02-03-19 12:38:58, Yafang Shao wrote: > > > > Only mm_compaction_isolate_{free, migrate}pages may be used when > > > > CONFIG_COMPACTION is not set. > > > > All others are used only when CONFIG_COMPACTION is set. > > > > > > Why is this an improvement? > > > > > > > After this change, if CONFIG_COMPACTION is not set, the tracepoints > > that only work when CONFIG_COMPACTION is set will not be exposed to > > the usespace. > > Without this change, they will always be expose in debugfs no matter > > CONFIG_COMPACTION is set or not. > > And this is exactly something that the changelog should mention. I > wasn't aware that we do export tracepoints even when they are not used > by any code path. This whole macro based programming is just a black > magic. > -- Sure, I will modify the changelog and send v2. Thanks Yafang