From: tip-bot for Lin Ming <ming.m.lin@intel.com>
To: linux-tip-commits@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, hpa@zytor.com, mingo@redhat.com,
a.p.zijlstra@chello.nl, ming.m.lin@intel.com, tglx@linutronix.de,
mingo@elte.hu
Subject: [tip:sched/core] sched: Cleanup duplicate local variable in [enqueue|dequeue]_task_fair
Date: Fri, 22 Jul 2011 12:55:35 GMT [thread overview]
Message-ID: <tip-0f3171438fc917b9f6b8b60dbb7a3fff9a0f68fd@git.kernel.org> (raw)
In-Reply-To: <1311297271.3938.1352.camel@minggr.sh.intel.com>
Commit-ID: 0f3171438fc917b9f6b8b60dbb7a3fff9a0f68fd
Gitweb: http://git.kernel.org/tip/0f3171438fc917b9f6b8b60dbb7a3fff9a0f68fd
Author: Lin Ming <ming.m.lin@intel.com>
AuthorDate: Fri, 22 Jul 2011 09:14:31 +0800
Committer: Ingo Molnar <mingo@elte.hu>
CommitDate: Fri, 22 Jul 2011 12:47:22 +0200
sched: Cleanup duplicate local variable in [enqueue|dequeue]_task_fair
No need to define a new "cfs_rq" variable in the "for" block.
Just use the one at the top of the function.
Signed-off-by: Lin Ming <ming.m.lin@intel.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/r/1311297271.3938.1352.camel@minggr.sh.intel.com
Signed-off-by: Ingo Molnar <mingo@elte.hu>
---
kernel/sched_fair.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/kernel/sched_fair.c b/kernel/sched_fair.c
index a2ecbaa..bc8ee99 100644
--- a/kernel/sched_fair.c
+++ b/kernel/sched_fair.c
@@ -1317,7 +1317,7 @@ enqueue_task_fair(struct rq *rq, struct task_struct *p, int flags)
}
for_each_sched_entity(se) {
- struct cfs_rq *cfs_rq = cfs_rq_of(se);
+ cfs_rq = cfs_rq_of(se);
update_cfs_load(cfs_rq, 0);
update_cfs_shares(cfs_rq);
@@ -1360,7 +1360,7 @@ static void dequeue_task_fair(struct rq *rq, struct task_struct *p, int flags)
}
for_each_sched_entity(se) {
- struct cfs_rq *cfs_rq = cfs_rq_of(se);
+ cfs_rq = cfs_rq_of(se);
update_cfs_load(cfs_rq, 0);
update_cfs_shares(cfs_rq);
prev parent reply other threads:[~2011-07-22 12:55 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-07-22 1:14 sched: Cleanup duplicate local variable in {enqueue_dequeue}_task_fair Lin Ming
2011-07-22 12:55 ` tip-bot for Lin Ming [this message]
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=tip-0f3171438fc917b9f6b8b60dbb7a3fff9a0f68fd@git.kernel.org \
--to=ming.m.lin@intel.com \
--cc=a.p.zijlstra@chello.nl \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=mingo@redhat.com \
--cc=tglx@linutronix.de \
/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
all inboxes | Powered by JetHome®