diff options
| author | Sebastian Macke | 2013-10-22 02:12:41 +0200 |
|---|---|---|
| committer | Jia Liu | 2013-11-20 14:46:45 +0100 |
| commit | d51552176a2ab5e80a211514aa1339fe2575ec2a (patch) | |
| tree | f272c169ec8acfdd998b69d7d4eb1ab9af58708d /target-openrisc/cpu.h | |
| parent | target-openrisc: Correct wrong epcr register in interrupt handler (diff) | |
| download | qemu-d51552176a2ab5e80a211514aa1339fe2575ec2a.tar.gz qemu-d51552176a2ab5e80a211514aa1339fe2575ec2a.tar.xz qemu-d51552176a2ab5e80a211514aa1339fe2575ec2a.zip | |
openrisc-timer: Reduce overhead, Separate clock update functions
The clock value is only evaluated when really necessary reducing
the overhead of the timer handling.
This also solves a problem in the way the Linux kernel
handles the timer and the expected accuracy.
The old version could lead to inaccurate timings.
Signed-off-by: Sebastian Macke <sebastian@macke.de>
Reviewed-by: Jia Liu <proljc@gmail.com>
Signed-off-by: Jia Liu <proljc@gmail.com>
Diffstat (limited to 'target-openrisc/cpu.h')
| -rw-r--r-- | target-openrisc/cpu.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/target-openrisc/cpu.h b/target-openrisc/cpu.h index 8fd0bc0bf0..0f9efdf6de 100644 --- a/target-openrisc/cpu.h +++ b/target-openrisc/cpu.h @@ -373,6 +373,7 @@ void cpu_openrisc_pic_init(OpenRISCCPU *cpu); /* hw/openrisc_timer.c */ void cpu_openrisc_clock_init(OpenRISCCPU *cpu); void cpu_openrisc_count_update(OpenRISCCPU *cpu); +void cpu_openrisc_timer_update(OpenRISCCPU *cpu); void cpu_openrisc_count_start(OpenRISCCPU *cpu); void cpu_openrisc_count_stop(OpenRISCCPU *cpu); |
