Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1570288
| From | Frederic Weisbecker <fweisbec@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH RESEND 30/36] ia64: Convert vtime to use nsec units directly |
| Date | 2017-01-31 04:40 +0100 |
| Message-ID | <t5xst-437-1@gated-at.bofh.it> (permalink) |
| References | <t5x97-3Wp-3@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
There is no need anymore for this cputime_t midlayer. Let's use nsec
units directly.
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Michael Ellerman <mpe@ellerman.id.au>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Tony Luck <tony.luck@intel.com>
Cc: Fenghua Yu <fenghua.yu@intel.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Rik van Riel <riel@redhat.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Stanislaw Gruszka <sgruszka@redhat.com>
Cc: Wanpeng Li <wanpeng.li@hotmail.com>
Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
---
arch/ia64/kernel/head.S | 4 ++--
arch/ia64/kernel/time.c | 14 +++++++-------
2 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/arch/ia64/kernel/head.S b/arch/ia64/kernel/head.S
index c9b5e94..3204fdd 100644
--- a/arch/ia64/kernel/head.S
+++ b/arch/ia64/kernel/head.S
@@ -1031,7 +1031,7 @@ GLOBAL_ENTRY(ia64_native_sched_clock)
END(ia64_native_sched_clock)
#ifdef CONFIG_VIRT_CPU_ACCOUNTING_NATIVE
-GLOBAL_ENTRY(cycle_to_cputime)
+GLOBAL_ENTRY(cycle_to_nsec)
alloc r16=ar.pfs,1,0,0,0
addl r8=THIS_CPU(ia64_cpu_info) + IA64_CPUINFO_NSEC_PER_CYC_OFFSET,r0
;;
@@ -1047,7 +1047,7 @@ GLOBAL_ENTRY(cycle_to_cputime)
;;
shrp r8=r9,r8,IA64_NSEC_PER_CYC_SHIFT
br.ret.sptk.many rp
-END(cycle_to_cputime)
+END(cycle_to_nsec)
#endif /* CONFIG_VIRT_CPU_ACCOUNTING_NATIVE */
#ifdef CONFIG_IA64_BRL_EMU
diff --git a/arch/ia64/kernel/time.c b/arch/ia64/kernel/time.c
index f15bca4..faa1168 100644
--- a/arch/ia64/kernel/time.c
+++ b/arch/ia64/kernel/time.c
@@ -60,7 +60,7 @@ static struct clocksource *itc_clocksource;
#include <linux/kernel_stat.h>
-extern cputime_t cycle_to_cputime(u64 cyc);
+extern u64 cycle_to_nsec(u64 cyc);
void vtime_flush(struct task_struct *tsk)
{
@@ -68,26 +68,26 @@ void vtime_flush(struct task_struct *tsk)
u64 delta;
if (ti->utime)
- account_user_time(tsk, cputime_to_nsecs(cycle_to_cputime(ti->utime)));
+ account_user_time(tsk, cycle_to_nsec(ti->utime));
if (ti->gtime)
- account_guest_time(tsk, cputime_to_nsecs(cycle_to_cputime(ti->gtime)));
+ account_guest_time(tsk, cycle_to_nsec(ti->gtime));
if (ti->idle_time)
- account_idle_time(cputime_to_nsecs(cycle_to_cputime(ti->idle_time)));
+ account_idle_time(cycle_to_nsec(ti->idle_time));
if (ti->stime) {
- delta = cputime_to_nsecs(cycle_to_cputime(ti->stime));
+ delta = cycle_to_nsec(ti->stime);
account_system_index_time(tsk, delta, CPUTIME_SYSTEM);
}
if (ti->hardirq_time) {
- delta = cputime_to_nsecs(cycle_to_cputime(ti->hardirq_time));
+ delta = cycle_to_nsec(ti->hardirq_time);
account_system_index_time(tsk, delta, CPUTIME_IRQ);
}
if (ti->softirq_time) {
- delta = cputime_to_nsecs(cycle_to_cputime(ti->softirq_time));
+ delta = cycle_to_nsec(ti->softirq_time));
account_system_index_time(tsk, delta, CPUTIME_SOFTIRQ);
}
--
2.7.4
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[GIT PULL] cputime: Convert core use of cputime_t to nsecs Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-30 05:50 +0100
Re: [GIT PULL] cputime: Convert core use of cputime_t to nsecs Stanislaw Gruszka <sgruszka@redhat.com> - 2017-01-30 15:40 +0100
Re: [GIT PULL] cputime: Convert core use of cputime_t to nsecs Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-30 16:10 +0100
Re: [GIT PULL] cputime: Convert core use of cputime_t to nsecs Stanislaw Gruszka <sgruszka@redhat.com> - 2017-01-30 17:00 +0100
[PATCH RESEND 01/36] jiffies: Reuse TICK_NSEC instead of NSEC_PER_JIFFY Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-31 04:20 +0100
[PATCH RESEND 04/36] cputime: Convert kcpustat to nsecs Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-31 04:30 +0100
[tip:sched/core] sched/cputime: Convert kcpustat to nsecs tip-bot for Frederic Weisbecker <tipbot@zytor.com> - 2017-02-01 11:00 +0100
[PATCH RESEND 24/36] cputime: Push time to account_idle_time() in nsecs Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-31 04:30 +0100
[tip:sched/core] sched/cputime: Push time to account_idle_time() in nsecs tip-bot for Frederic Weisbecker <tipbot@zytor.com> - 2017-02-01 11:10 +0100
[PATCH RESEND 25/36] cputime: Push time to account_system_time() in nsecs Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-31 04:30 +0100
[tip:sched/core] sched/cputime: Push time to account_system_time() in nsecs tip-bot for Frederic Weisbecker <tipbot@zytor.com> - 2017-02-01 11:10 +0100
[PATCH RESEND 16/36] signal: Convert obsolete cputime type to nsecs Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-31 04:30 +0100
[tip:sched/core] signal: Convert obsolete cputime type to nsecs tip-bot for Frederic Weisbecker <tipbot@zytor.com> - 2017-02-01 11:10 +0100
[PATCH RESEND 27/36] vtime: Return nsecs instead of cputime_t to account Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-31 04:30 +0100
[tip:sched/core] sched/cputime, vtime: Return nsecs instead of cputime_t to account tip-bot for Frederic Weisbecker <tipbot@zytor.com> - 2017-02-01 11:10 +0100
[PATCH RESEND 09/36] alpha: Convert obsolete cputime_t to nsecs Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-31 04:30 +0100
[tip:sched/core] alpha: Convert obsolete cputime_t to nsecs tip-bot for Frederic Weisbecker <tipbot@zytor.com> - 2017-02-01 11:00 +0100
[PATCH RESEND 12/36] binfmt: Convert obsolete cputime type to nsecs Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-31 04:30 +0100
[tip:sched/core] fs/binfmt: Convert obsolete cputime type to nsecs tip-bot for Frederic Weisbecker <tipbot@zytor.com> - 2017-02-01 11:00 +0100
[PATCH RESEND 30/36] ia64: Convert vtime to use nsec units directly Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-31 04:40 +0100
[tip:sched/core] ia64: Convert vtime to use nsec units directly tip-bot for Frederic Weisbecker <tipbot@zytor.com> - 2017-02-01 11:10 +0100
[PATCH RESEND 05/36] macintosh/rack-meter: Remove cputime_t internal use Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-31 04:40 +0100
[tip:sched/core] macintosh/rack-meter: Convert cputime64_t use to u64 tip-bot for Frederic Weisbecker <tipbot@zytor.com> - 2017-02-01 12:00 +0100
[PATCH RESEND 07/36] cputime: Special API to return old-typed cputime Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-31 04:40 +0100
[tip:sched/core] sched/cputime: Introduce special task_cputime_t() API to return old-typed cputime tip-bot for Frederic Weisbecker <tipbot@zytor.com> - 2017-02-01 11:00 +0100
[PATCH RESEND 02/36] time: Introduce jiffies64_to_nsecs() Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-31 04:50 +0100
[tip:sched/core] time: Introduce jiffies64_to_nsecs() tip-bot for Frederic Weisbecker <tipbot@zytor.com> - 2017-02-01 11:00 +0100
[PATCH RESEND 26/36] cputime: Complete nsec conversion of tick based accounting Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-31 04:50 +0100
[tip:sched/core] sched/cputime: Complete nsec conversion of tick based accounting tip-bot for Frederic Weisbecker <tipbot@zytor.com> - 2017-02-01 11:10 +0100
[PATCH RESEND 17/36] cputime: Increment kcpustat directly on irqtime account Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-31 04:50 +0100
[tip:sched/core] sched/cputime: Increment kcpustat directly on irqtime account tip-bot for Frederic Weisbecker <tipbot@zytor.com> - 2017-02-01 11:10 +0100
[PATCH RESEND 10/36] x86: Convert obsolete cputime type to nsecs Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-31 05:20 +0100
[tip:sched/core] x86: Convert obsolete cputime type to nsecs tip-bot for Frederic Weisbecker <tipbot@zytor.com> - 2017-02-01 11:00 +0100
[PATCH RESEND 33/36] powerpc: Remove unused cputime definitions Frederic Weisbecker <fweisbec@gmail.com> - 2017-01-31 05:30 +0100
[tip:sched/core] powerpc, sched/cputime: Remove unused cputime definitions tip-bot for Frederic Weisbecker <tipbot@zytor.com> - 2017-02-01 11:10 +0100
[tip:sched/core] jiffies: Reuse TICK_NSEC instead of NSEC_PER_JIFFY tip-bot for Frederic Weisbecker <tipbot@zytor.com> - 2017-02-01 11:00 +0100
Re: [GIT PULL] cputime: Convert core use of cputime_t to nsecs Frederic Weisbecker <fweisbec@gmail.com> - 2017-02-06 14:50 +0100
Re: [GIT PULL] cputime: Convert core use of cputime_t to nsecs Ingo Molnar <mingo@kernel.org> - 2017-02-07 09:10 +0100
Re: [GIT PULL] cputime: Convert core use of cputime_t to nsecs Frederic Weisbecker <fweisbec@gmail.com> - 2017-02-07 15:10 +0100
Re: [GIT PULL] cputime: Convert core use of cputime_t to nsecs Ingo Molnar <mingo@kernel.org> - 2017-02-07 20:00 +0100
csiph-web