linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: larmbr <nasa4836@gmail.com>
To: linux-mm@kvack.org
Cc: mgorman@suse.de, riel@redhat.com, mhocko@suse.cz,
	akpm@linux-foundation.org, linux-kernel@vger.kernel.org
Subject: [PATCH] mm/vmscan: make global_reclaim() inline
Date: Thu, 22 Aug 2013 13:39:56 +0800	[thread overview]
Message-ID: <20130822053956.GA10795@larmbr-lcx> (raw)

Though Gcc is likely to inline them, we should better
explictly do it manually, and also, this serve to document 
this fact.

Signed-off-by: Zhan Jianyu <nasa4836@gmail.com>
---
mm/vmscan.c |    4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/mm/vmscan.c b/mm/vmscan.c
index 1de652d..1946d7d 100644
--- a/mm/vmscan.c
+++ b/mm/vmscan.c
@@ -135,12 +135,12 @@ static LIST_HEAD(shrinker_list);
 static DECLARE_RWSEM(shrinker_rwsem);
 
 #ifdef CONFIG_MEMCG
-static bool global_reclaim(struct scan_control *sc)
+static inline bool global_reclaim(struct scan_control *sc)
 {
 	return !sc->target_mem_cgroup;
 }
 #else
-static bool global_reclaim(struct scan_control *sc)
+static inline bool global_reclaim(struct scan_control *sc)
 {
 	return true;
 }

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

             reply	other threads:[~2013-08-22  5:40 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-22  5:39 larmbr [this message]
2013-09-03 23:02 ` [PATCH] mm/vmscan: make global_reclaim() inline Johannes Weiner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20130822053956.GA10795@larmbr-lcx \
    --to=nasa4836@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mgorman@suse.de \
    --cc=mhocko@suse.cz \
    --cc=riel@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).