[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tip-553bf6bbfd8a540c70aee28eb50e24caff456a03@git.kernel.org>
Date: Thu, 14 Jul 2016 03:38:59 -0700
From: tip-bot for Rik van Riel <tipbot@...or.com>
To: linux-tip-commits@...r.kernel.org
Cc: fweisbec@...il.com, rkrcmar@...hat.com, efault@....de,
torvalds@...ux-foundation.org, peterz@...radead.org,
linux-kernel@...r.kernel.org, tglx@...utronix.de, riel@...hat.com,
pbonzini@...hat.com, mingo@...nel.org, wanpeng.li@...mail.com,
hpa@...or.com
Subject: [tip:timers/nohz] sched/cputime: Drop local_irq_save/restore from
irqtime_account_irq()
Commit-ID: 553bf6bbfd8a540c70aee28eb50e24caff456a03
Gitweb: http://git.kernel.org/tip/553bf6bbfd8a540c70aee28eb50e24caff456a03
Author: Rik van Riel <riel@...hat.com>
AuthorDate: Wed, 13 Jul 2016 16:50:05 +0200
Committer: Ingo Molnar <mingo@...nel.org>
CommitDate: Thu, 14 Jul 2016 10:42:35 +0200
sched/cputime: Drop local_irq_save/restore from irqtime_account_irq()
Paolo pointed out that irqs are already blocked when irqtime_account_irq()
is called. That means there is no reason to call local_irq_save/restore()
again.
Suggested-by: Paolo Bonzini <pbonzini@...hat.com>
Signed-off-by: Rik van Riel <riel@...hat.com>
Signed-off-by: Frederic Weisbecker <fweisbec@...il.com>
Reviewed-by: Paolo Bonzini <pbonzini@...hat.com>
Cc: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Mike Galbraith <efault@....de>
Cc: Peter Zijlstra <peterz@...radead.org>
Cc: Radim Krcmar <rkrcmar@...hat.com>
Cc: Thomas Gleixner <tglx@...utronix.de>
Cc: Wanpeng Li <wanpeng.li@...mail.com>
Link: http://lkml.kernel.org/r/1468421405-20056-6-git-send-email-fweisbec@gmail.com
Signed-off-by: Ingo Molnar <mingo@...nel.org>
---
kernel/sched/cputime.c | 4 ----
1 file changed, 4 deletions(-)
diff --git a/kernel/sched/cputime.c b/kernel/sched/cputime.c
index 16a873c..ea0f6f3 100644
--- a/kernel/sched/cputime.c
+++ b/kernel/sched/cputime.c
@@ -49,15 +49,12 @@ DEFINE_PER_CPU(seqcount_t, irq_time_seq);
*/
void irqtime_account_irq(struct task_struct *curr)
{
- unsigned long flags;
s64 delta;
int cpu;
if (!sched_clock_irqtime)
return;
- local_irq_save(flags);
-
cpu = smp_processor_id();
delta = sched_clock_cpu(cpu) - __this_cpu_read(irq_start_time);
__this_cpu_add(irq_start_time, delta);
@@ -75,7 +72,6 @@ void irqtime_account_irq(struct task_struct *curr)
__this_cpu_add(cpu_softirq_time, delta);
irq_time_write_end();
- local_irq_restore(flags);
}
EXPORT_SYMBOL_GPL(irqtime_account_irq);
Powered by blists - more mailing lists