History log of /arch/mips/kernel/time.c
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
73bc256d47a23272ce1dd50b4de64a0ff23d01f1 23-Jul-2011 Paul Gortmaker <paul.gortmaker@windriver.com> mips: migrate core kernel file from module.h --> export.h

These files are not modules, but were including module.h only for
EXPORT_SYMBOL and/or THIS_MODULE. Now that we have the lightweight
export.h, use it in these kinds of cases.

Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
/arch/mips/kernel/time.c
25985edcedea6396277003854657b5f3cb31a628 31-Mar-2011 Lucas De Marchi <lucas.demarchi@profusion.mobi> Fix common misspellings

Fixes generated by 'codespell' and manually reviewed.

Signed-off-by: Lucas De Marchi <lucas.demarchi@profusion.mobi>
/arch/mips/kernel/time.c
e3a4fab0c0c30e21e104712f4e9cb39f175d0f21 11-Nov-2009 Thomas Gleixner <tglx@linutronix.de> mips: Use generic mult/shift factor calculation for clocks

Replace the MIPS functions of mult/shift factor calculation for clock
events and clock sources with inline functions which call the generic
functions. The minimum guaranteed conversion range is set to 4 seconds
which corresponds to the current MIPS implementation.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Mikael Pettersson <mikpe@it.uu.se>
Acked-by: Ralf Baechle <ralf@linux-mips.org>
Acked-by: Linus Walleij <linus.walleij@stericsson.com>
Cc: John Stultz <johnstul@us.ibm.com>
LKML-Reference: <20091111134229.807255074@linutronix.de>
/arch/mips/kernel/time.c
46684734dd6a55af09c3fe799af7d74cb938684c 02-Apr-2008 Dmitri Vorobiev <dmitri.vorobiev@gmail.com> [MIPS] unexport null_perf_irq() and make it static

This patch unexports the null_perf_irq() symbol, and simultaneously
makes this function static.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
c5b0680aa1d7a751b7dd8ebf6854e5baf0a2e54b 02-Apr-2008 Dmitri Vorobiev <dmitri.vorobiev@gmail.com> [MIPS] unexport rtc_mips_set_time()

No users for the rtc_mips_set_time() routine exist outside of the
core kernel code. Therefore, EXPORT_SYMBOL(rtc_mips_set_time) is
useless, and this patch removes it.

Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
447cdf2628b59aa513a42785450b348dced26d8a 12-Mar-2008 Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp> [MIPS] Fix the installation condition of MIPS clocksource

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
c9662341f8a09cffd7234a89cc066c342fe343bf 09-Dec-2007 Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp> [MIPS] time: remove unused mips_timer_state()

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
ce202cbb9e0b623671e8ecb3d53afdd42b8e458f 04-Jan-2008 Thomas Bogendoerfer <tsbogend@alpha.franken.de> [MIPS] Assume R4000/R4400 newer than 3.0 don't have the mfc0 count bug

This seems as reasonable assumption and gets some SNI machines to work
which currently must rely on the cp0 counter as clocksource.

Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
4037500ebcfd172a15aed40caa847c52e9906712 14-Dec-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] time: Delete weak definition of plat_time_init() due to gcc bug.

Frank Rowand <frank.rowand@am.sony.com> reports:

> In linux-2.6.24-rc4 the Toshiba RBTX4927 hangs on boot.
>
> The cause is that plat_time_init() from arch/mips/tx4927/common/
> tx4927_setup.c does not override the __weak plat_time_init() from
> arch/mips/kernel/time.c. This is due to a compiler bug in gcc 4.1.1. The
> bug is reported to not exist in earlier versions of gcc, and to be fixed in
> 4.1.2. The problem is that the __weak plat_time_init() is empty and thus
> gets optimized out of existence (thus the linker is never given the option
> to replace the __weak function).

[ He meant the call to plat_time_init() from time_init() gets optimized away ]

> For more info on the gcc bug see
>
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27781
>
> The attached patch is one workaround. Another possible workaround

[ His patch adds -fno-unit-at-a-time for time.c ]

> would be to change the __weak plat_time_init() to be a non-empty
> function.

The __weak definition of plat_time_init was only ever meant to be a
migration helper to keep platforms that don't have a plat_time_init
compiling. A few greps says that all platforms now supply their own
plat_time_init() so the weak definition is no longer needed. So I
instead delete it.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
940f6b48a130e0a33cb8bd397dd0e277166470ad 24-Nov-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] Only build r4k clocksource for systems that work ok with it.

In particular as-is it's not suited for multicore and mutiprocessors
systems where there is on guarantee that the counter are synchronized
or running from the same clock at all. This broke Sibyte and probably
others since the "[MIPS] Handle R4000/R4400 mfc0 from count register."
commit.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
5aa85c9fc49a6ce44dc10a42e2011bbde9dc445a 21-Nov-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] Handle R4000/R4400 mfc0 from count register.

The R4000 and R4400 have an errata where if the cp0 count register is read
in the exact moment when it matches the compare register no interrupt will
be generated.

This bug may be triggered if the cp0 count register is being used as
clocksource and the compare interrupt as clockevent. So a simple
workaround is to avoid using the compare for both facilities on the
affected CPUs.

This is different from the workaround suggested in the old errata documents;
at some opportunity probably the official version should be implemented
and tested. Another thing to find out is which processor versions
exactly are affected. I only have errata documents upto R4400 V3.0
available so for the moment the code treats all R4000 and R4400 as broken.

This is potencially a problem for some machines that have no other decent
clocksource available; this workaround will cause them to fall back to
another clocksource, worst case the "jiffies" source.
/arch/mips/kernel/time.c
d9eec1a5d6ae54b0f7562ffe07008a33ac39e8fe 30-Oct-2007 Atsushi Nemoto <anemo@mba.ocn.ne.jp> [MIPS] time: Code cleanups

* Do not include unnecessary headers.
* Do not mention time.README.
* Do not mention mips_timer_ack.
* Make clocksource_mips static. It is now dedicated to c0_timer.
* Initialize clocksource_mips.read statically.
* Remove null_hpt_read.
* Remove an argument of plat_timer_setup. It is just a placeholder.

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
1d0a909cfc41f17175023b939b28322e427746b4 30-Oct-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] time: Remove now unused local_timer_interrupt.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
656db5061dc5758dc52cdbf26de5cd25aca82d7a 26-Oct-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] time: Cause platform definitions of plat_timer_setup to cause error.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
508a775a3c9c6c3f952338f6722ea8bc92899962 19-Oct-2007 Atsushi Nemoto <anemo@mba.ocn.ne.jp> [MIPS] time: Fix calculation in clockevent_set_clock()

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
93c846f9047f392fc2335668a5234edfbddb7cdc 19-Oct-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] time: Helpers to compute clocksource/event shift and mult values.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
9c9ad7917bf22350c59e6568d6d570f9be102d00 19-Oct-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] time: Delete dead code.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
42f77542f4a1c104bb6fbba2e18e04e84415a96b 18-Oct-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] time: Move R4000 clockevent device code to separate configurable file

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
2cfa7660dbf94a61b9d43edaa84be454f9dc25fc 18-Oct-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] time: Delete dead cycles_per_jiffy, mips_timer_ack and null_timer_ack

cycles_per_jiffy was only ever getting assigned and the function pointer
not being called anymore and mips_timer_ack had gotten similarly stale. I
leave the remaining assignments unfixed as a lighthouse pointing platform
maintainers to what needs a rewrite. These changes make null_timer_ack()
unreferenced, so delete that too.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
b0d4056dd6f16eca63114d0c252b214449a13cca 17-Oct-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] Probe for usability of cp0 compare interrupt.

Some processors offer the option of using the interrupt on which
normally the count / compare interrupt would be signaled as a normal
interupt pin. Previously this required some ugly hackery for each
system which is much easier done by a quick and simple probe.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
8bb00d83d8fc2de5c0614f5d55780107e0c375fe 16-Oct-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] Increase cp0 compare clockevent min_delta_ns from 0x30 to 0x300.

Extremly low values are of dubious usefulness anyway but in this case
they actually were killing Qemu which simply wasn't able to complete
mips_next_event() within 0x30 100MHz cycles even on fast hosts.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
49a89efbbbcc178a39555c43bd59a7593c429664 12-Oct-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] Fix "no space between function name and open parenthesis" warnings.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
ea5804015c0ce67741eb4b156a071fb4f415345f 12-Oct-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] Dyntick support for SMTC:

The kernel currently only supports broadcasting of the timer interrupt
from a single timer, not multicasting into two multicast groups of
processors. So the implemented mechanism for SMTC works by broadcasting
the cp0 compare interrupt on VPE 0 and ignoring it on any additional VPEs.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
7bcf7717b6a047c272410d0cd00213185fe6b99d 12-Oct-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] Implement clockevents for R4000-style cp0 count/compare interrupt

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
91a2fcc88634663e9e13dcdfad0e4a860e64aeee 12-Oct-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] Consolidate all variants of MIPS cp0 timer interrupt handlers.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
90b02340dcc6ce00bf22c48f4865915f5989e5e4 12-Oct-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] Switch from to_tm to rtc_time_to_tm

This replaces the MIPS-specific to_tm function with the generic
rtc_time_to_tm function. The big difference between the two functions is
that rtc_time_to_tm uses epoch 70 while to_tm uses 1970, so the result of
rtc_time_to_tm needs to be fixed up.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
4b550488f894c899aa54dc935c8fee47bca2b7df 12-Oct-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] Deforest the function pointer jungle in the time code.

Hard to follow who is pointing what to where and why so it's simply getting
in the way of the time code renovation.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
f5ff0a280201c9cbfb6e9eb4bafdb465c2269ed3 13-Aug-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] Use generic NTP code for all MIPS platforms

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
b1043cc7d9d7a7dec8d807570c067e0c90b94b57 13-Sep-2007 Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp> [MIPS] Add #include <linux/profile.h> to arch/mips/kernel/time.c

It refer to CPU_PROFILING.

arch/mips/kernel/time.c: In function 'local_timer_interrupt':
arch/mips/kernel/time.c:142: error: implicit declaration of function 'profile_tick'
arch/mips/kernel/time.c:142: error: 'CPU_PROFILING' undeclared (first use in this function)
arch/mips/kernel/time.c:142: error: (Each undeclared identifier is reported only once
arch/mips/kernel/time.c:142: error: for each function it appears in.)

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
3b1d4ed5353af04d6aa20be2701727b9cdb2ac61 20-Jun-2007 Ralf Baechle <ralf@linux-mips.org> [MIPS] Don't drag a platform specific header into generic arch code.

For some platforms it's definitions may conflict. So that's the one-liner.
The rest is 10 square kilometers of collateral damage fixup this include
used to paper over.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
ffe9ee4709cf513fb80e9b7e04d214dd8b76a10d 24-May-2007 Chris Dearman <chris@mips.com> [MIPS] Separate performance counter interrupts

Support for performance counter overflow interrupt that is on a separate
interrupt from the timer.

Signed-off-by: Chris Dearman <chris@mips.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
55d0b4e3f6526daf1cc7449028bf5d4c304a6a69 04-May-2007 Franck Bui-Huu <fbuihuu@gmail.com> [MIPS] clocksource: use CLOCKSOURCE_MASK() macro

Signed-off-by: Franck Bui-Huu <fbuihuu@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
877fe38029366c19def24359627db8cc24d9fef6 16-Feb-2007 Thomas Gleixner <tglx@linutronix.de> [PATCH] clocksource: fixup is_continous changes on MIPS

Fixup the is_contionous replacement by a flag field.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: john stultz <johnstul@us.ibm.com>
Cc: Roman Zippel <zippel@linux-m68k.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
/arch/mips/kernel/time.c
b035b6de24932ffd4a2b1c6619a2f5711da6920f 10-Feb-2007 Alexey Dobriyan <adobriyan@openvz.org> [PATCH] Consolidate default sched_clock()

Use attribute(weak).

Signed-off-by: Alexey Dobriyan <adobriyan@openvz.org>
Acked-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
/arch/mips/kernel/time.c
2dbda7dceca81adfe57c8884be5c66e70822d89a 28-Dec-2006 Vitaly Wool <vitalywool@gmail.com> [MIPS] PNX8550: Fix system timer support

the patch inlined below restores proper time accounting for PNX8550-based
boards. It also gets rid of #ifdef in the generic code which becomes
unnecessary then.

It's functionally identical to the previous patch with the same name but
it has minor comments from Atsushi and Sergei taken into account.

Signed-off-by: Vitaly Wool <vwool@ru.mvista.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
005985609ff72df3257fde6b29aa9d71342c2a6b 11-Nov-2006 Atsushi Nemoto <anemo@mba.ocn.ne.jp> [MIPS] mips HPT cleanup: make clocksource_mips public

Make clocksource_mips public and get rid of mips_hpt_read,
mips_hpt_mask.

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
c87b6ebaea034c0e0ce86127870cf1511a307b64 27-Oct-2006 Atsushi Nemoto <anemo@mba.ocn.ne.jp> [MIPS] mips hpt cleanup: get rid of mips_hpt_init

Currently nobody outside time.c require mips_hpt_init(). Remove it
and call c0_hpt_timer_init() directly if R4k counter was used for
timer interrupt.

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
16b7b2ac0148e839da86af8747b6fa4aad43a9b7 23-Oct-2006 Atsushi Nemoto <anemo@mba.ocn.ne.jp> [MIPS] Fixup migration to GENERIC_TIME

Since we already moved to GENERIC_TIME, we should implement alternatives
of old do_gettimeoffset routines to get sub-jiffies resolution from
gettimeofday(). This patch includes:

* MIPS clocksource support (based on works by Manish Lachwani).
* remove unused gettimeoffset routines and related codes.
* remove unised 64bit do_div64_32().
* simplify mips_hpt_init. (no argument needed, __init tag)
* simplify c0_hpt_timer_init. (no need to write to c0_count)
* remove some hpt_init routines.
* mips_hpt_mask variable to specify bitmask of hpt value.
* convert jmr3927_do_gettimeoffset to jmr3927_hpt_read.
* convert ip27_do_gettimeoffset to ip27_hpt_read.
* convert bcm1480_do_gettimeoffset to bcm1480_hpt_read.
* simplify sb1250 hpt functions. (no need to subtract and shift)

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
937a801576f954bd030d7c4a5a94571710d87c0b 07-Oct-2006 Ralf Baechle <ralf@linux-mips.org> [MIPS] Complete fixes after removal of pt_regs argument to int handlers.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
7d12e780e003f93433d49ce78cfedf4b4c52adc5 05-Oct-2006 David Howells <dhowells@redhat.com> IRQ: Maintain regs pointer globally rather than passing to IRQ handlers

Maintain a per-CPU global "struct pt_regs *" variable which can be used instead
of passing regs around manually through all ~1800 interrupt handlers in the
Linux kernel.

The regs pointer is used in few places, but it potentially costs both stack
space and code to pass it around. On the FRV arch, removing the regs parameter
from all the genirq function results in a 20% speed up of the IRQ exit path
(ie: from leaving timer_interrupt() to leaving do_IRQ()).

Where appropriate, an arch may override the generic storage facility and do
something different with the variable. On FRV, for instance, the address is
maintained in GR28 at all times inside the kernel as part of general exception
handling.

Having looked over the code, it appears that the parameter may be handed down
through up to twenty or so layers of functions. Consider a USB character
device attached to a USB hub, attached to a USB controller that posts its
interrupts through a cascaded auxiliary interrupt controller. A character
device driver may want to pass regs to the sysrq handler through the input
layer which adds another few layers of parameter passing.

I've build this code with allyesconfig for x86_64 and i386. I've runtested the
main part of the code on FRV and i386, though I can't test most of the drivers.
I've also done partial conversion for powerpc and MIPS - these at least compile
with minimal configurations.

This will affect all archs. Mostly the changes should be relatively easy.
Take do_IRQ(), store the regs pointer at the beginning, saving the old one:

struct pt_regs *old_regs = set_irq_regs(regs);

And put the old one back at the end:

set_irq_regs(old_regs);

Don't pass regs through to generic_handle_irq() or __do_IRQ().

In timer_interrupt(), this sort of change will be necessary:

- update_process_times(user_mode(regs));
- profile_tick(CPU_PROFILING, regs);
+ update_process_times(user_mode(get_irq_regs()));
+ profile_tick(CPU_PROFILING);

I'd like to move update_process_times()'s use of get_irq_regs() into itself,
except that i386, alone of the archs, uses something other than user_mode().

Some notes on the interrupt handling in the drivers:

(*) input_dev() is now gone entirely. The regs pointer is no longer stored in
the input_dev struct.

(*) finish_unlinks() in drivers/usb/host/ohci-q.c needs checking. It does
something different depending on whether it's been supplied with a regs
pointer or not.

(*) Various IRQ handler function pointers have been moved to type
irq_handler_t.

Signed-Off-By: David Howells <dhowells@redhat.com>
(cherry picked from 1b16e7ac850969f38b375e511e3fa2f474a33867 commit)
/arch/mips/kernel/time.c
8db0201026fbb45c383176f539dc8af2a6871ab8 02-Oct-2006 Ralf Baechle <ralf@linux-mips.org> [MIPS] Fix wreckage after removal of tickadj; convert to GENERIC_TIME.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
8ef386092d7c2891bd7acefb2a87f878f7e9a0d6 01-Oct-2006 Atsushi Nemoto <anemo@mba.ocn.ne.jp> [PATCH] kill wall_jiffies

With 2.6.18-rc4-mm2, now wall_jiffies will always be the same as jiffies.
So we can kill wall_jiffies completely.

This is just a cleanup and logically should not change any real behavior
except for one thing: RTC updating code in (old) ppc and xtensa use a
condition "jiffies - wall_jiffies == 1". This condition is never met so I
suppose it is just a bug. I just remove that condition only instead of
kill the whole "if" block.

[heiko.carstens@de.ibm.com: s390 build fix and cleanup]
Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Cc: Andi Kleen <ak@muc.de>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Richard Henderson <rth@twiddle.net>
Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
Cc: Russell King <rmk@arm.linux.org.uk>
Cc: Ian Molton <spyro@f2s.com>
Cc: Mikael Starvik <starvik@axis.com>
Cc: David Howells <dhowells@redhat.com>
Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
Cc: Hirokazu Takata <takata.hirokazu@renesas.com>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Kyle McMartin <kyle@mcmartin.ca>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Paul Mundt <lethal@linux-sh.org>
Cc: Kazumoto Kojima <kkojima@rr.iij4u.or.jp>
Cc: Richard Curnow <rc@rc0.org.uk>
Cc: William Lee Irwin III <wli@holomorphy.com>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Jeff Dike <jdike@addtoit.com>
Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
Cc: Miles Bader <uclinux-v850@lsi.nec.co.jp>
Cc: Chris Zankel <chris@zankel.net>
Cc: "Luck, Tony" <tony.luck@intel.com>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Roman Zippel <zippel@linux-m68k.org>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
/arch/mips/kernel/time.c
3171a0305d62e6627a24bff35af4f997e4988a80 29-Sep-2006 Atsushi Nemoto <anemo@mba.ocn.ne.jp> [PATCH] simplify update_times (avoid jiffies/jiffies_64 aliasing problem)

Pass ticks to do_timer() and update_times(), and adjust x86_64 and s390
timer interrupt handler with this change.

Currently update_times() calculates ticks by "jiffies - wall_jiffies", but
callers of do_timer() should know how many ticks to update. Passing ticks
get rid of this redundant calculation. Also there are another redundancy
pointed out by Martin Schwidefsky.

This cleanup make a barrier added by
5aee405c662ca644980c184774277fc6d0769a84 needless. So this patch removes
it.

As a bonus, this cleanup make wall_jiffies can be removed easily, since now
wall_jiffies is always synced with jiffies. (This patch does not really
remove wall_jiffies. It would be another cleanup patch)

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: john stultz <johnstul@us.ibm.com>
Cc: Andi Kleen <ak@muc.de>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Richard Henderson <rth@twiddle.net>
Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
Acked-by: Russell King <rmk@arm.linux.org.uk>
Cc: Ian Molton <spyro@f2s.com>
Cc: Mikael Starvik <starvik@axis.com>
Acked-by: David Howells <dhowells@redhat.com>
Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
Cc: Hirokazu Takata <takata.hirokazu@renesas.com>
Acked-by: Ralf Baechle <ralf@linux-mips.org>
Cc: Kyle McMartin <kyle@mcmartin.ca>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Paul Mundt <lethal@linux-sh.org>
Cc: Kazumoto Kojima <kkojima@rr.iij4u.or.jp>
Cc: Richard Curnow <rc@rc0.org.uk>
Cc: William Lee Irwin III <wli@holomorphy.com>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Jeff Dike <jdike@addtoit.com>
Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
Cc: Miles Bader <uclinux-v850@lsi.nec.co.jp>
Cc: Chris Zankel <chris@zankel.net>
Acked-by: "Luck, Tony" <tony.luck@intel.com>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Roman Zippel <zippel@linux-m68k.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
/arch/mips/kernel/time.c
54d0a216f40e060ba4265bb851cc36b3ca55d1a8 09-Jul-2006 Ralf Baechle <ralf@linux-mips.org> [MIPS] Replace board_timer_setup function pointer by plat_timer_setup.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>

---
/arch/mips/kernel/time.c
f40298fddcc3c8115c6135c9733f5a0de52dcea9 02-Jul-2006 Thomas Gleixner <tglx@linutronix.de> [PATCH] irq-flags: MIPS: Use the new IRQF_ constants

Use the new IRQF_ constants and remove the SA_INTERRUPT define

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
/arch/mips/kernel/time.c
6ab3d5624e172c553004ecc862bfeac16d9d68b7 30-Jun-2006 Jörn Engel <joern@wohnheim.fh-wedel.de> Remove obsolete #include <linux/config.h>

Signed-off-by: Jörn Engel <joern@wohnheim.fh-wedel.de>
Signed-off-by: Adrian Bunk <bunk@stusta.de>
/arch/mips/kernel/time.c
41c594ab65fc89573af296d192aa5235d09717ab 05-Apr-2006 Ralf Baechle <ralf@linux-mips.org> [MIPS] MT: Improved multithreading support.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
d23ee8fe6e2176a9d4dbfdd18edfa1b5bc3c79a5 27-Mar-2006 Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp> [PATCH] mips: fixed collision of rtc function name

Fix the collision of rtc function name.

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Cc: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
/arch/mips/kernel/time.c
d6bd0e6b32ea72be91e5789b1e838c244f8a05d9 15-Mar-2006 Ralf Baechle <ralf@linux-mips.org> [MIPS] Protect more of timer_interrupt() by xtime_lock.

From Dave Johnson <djohnson+linuxmips@sw.starentnetworks.com>:

* do_timer() expects the arch-specific handler to take the lock as it
modifies jiffies[_64] and xtime.
* writing timerhi/lo in timer_interrupt() will mess up
fixed_rate_gettimeoffset() which reads timerhi/lo.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
800d11420dfdad3a50630ff424d7782660ad558c 01-Mar-2006 Atsushi Nemoto <anemo@mba.ocn.ne.jp> [MIPS] Use USECS_PER_SEC / HZ instead of tick_usec in do_gettimeofday.

The 'tick_usec' is USER_HZ period in usec. do_gettimeofday() should
use kernel HZ value.

Here is a patch for MIPS. It seems m32r, m68k and sparc have same
problem though their HZ and USER_HZ are same for now.

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
ba339c03e2e8ede8ccd37ed6c4e564e3b1545495 09-Dec-2005 Ralf Baechle <ralf@linux-mips.org> MIPS: Oprofile: Fixup the loose ends in the plumbing.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
b4672d37293cb045ec4d57e8b76a62810c96da71 08-Dec-2005 Ralf Baechle <ralf@linux-mips.org> MIPS: Introduce machinery for testing for MIPSxxR1/2.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
e7958bb90d57f0da073cbd031a1808de51d1de15 08-Dec-2005 Ralf Baechle <ralf@linux-mips.org> MIPS: Rename MIPS_CPU_ISA_M{32,64} -> MIPS_CPU_ISA_M{32,64}R1.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
ecea8d19c9f0ebd62ddaa07fc919ff4e4b820d99 31-Oct-2005 Thomas Gleixner <tglx@linutronix.de> [PATCH] jiffies_64 cleanup

Define jiffies_64 in kernel/timer.c rather than having 24 duplicated
defines in each architecture.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
/arch/mips/kernel/time.c
bdf21b18b4abf983db38f04ef7fec88f47389867 14-Jul-2005 Pete Popov <ppopov@embeddedalley.com> Philips PNX8550 support: MIPS32-like core with 2 Trimedias on it.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
ec74e361f1e71a2498e48b62abdc4bd8d2423354 13-Jul-2005 Ralf Baechle <ralf@linux-mips.org> Mark a few variables __read_mostly.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
/arch/mips/kernel/time.c
b149ee2233edf08fb59b11e879a2c5941929bcb8 07-Sep-2005 john stultz <johnstul@us.ibm.com> [PATCH] NTP: ntp-helper functions

This patch cleans up a commonly repeated set of changes to the NTP state
variables by adding two helper inline functions:

ntp_clear(): Clears the ntp state variables

ntp_synced(): Returns 1 if the system is synced with a time server.

This was compile tested for alpha, arm, i386, x86-64, ppc64, s390, sparc,
sparc64.

Signed-off-by: John Stultz <johnstul@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
/arch/mips/kernel/time.c
1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 17-Apr-2005 Linus Torvalds <torvalds@ppc970.osdl.org> Linux-2.6.12-rc2

Initial git repository build. I'm not bothering with the full history,
even though we have it. We can create a separate "historical" git
archive of that later if we want to, and in the meantime it's about
3.2GB when imported into git - space that would just make the early
git days unnecessarily complicated, when we don't have a lot of good
infrastructure for it.

Let it rip!
/arch/mips/kernel/time.c