History log of /seL4-camkes-master/projects/util_libs/libplatsupport/src/mach/zynq/timer.c
Revision Date Author Comments
# e382ba4c 21-Jan-2020 Damon Lee <Damon.Lee@data61.csiro.au>

trivial: Style changed files


# e617801f 21-Jan-2020 Damon Lee <Damon.Lee@data61.csiro.au>

trivial: Update licenses

These files were changed significantly, so we update the license to
reflect this.


# 15eead5d 21-Jan-2020 Damon Lee <Damon.Lee@data61.csiro.au>

libplatsupport,zynq: Move HW timer ops to driver

Timer resource allocation and the management of interrupts should belong
in the driver level. This commit moves these operations from the ltimer
level down to the driver level for the ZYNQ platforms.


# 7922d6b3 02-Aug-2019 Chris Guikema <chris.guikema@dornerworks.com>

zynqmp: Allow 32-bit free-running clock

The current zynq machine code assumes a 16-bit counter, which is only
true for the zynq7000. The zynqmp has a 32-bit counter. The timestamp
timer would stop functioning on the zynqmp after it overflowed. This
commit handles the overflow properly on the zynqmp.


# 971441ac 06-Feb-2018 Kofi Doku Atuah <kofidoku.atuah@data61.csiro.au>

Platsupport: Zilinx-zc7 timer: Use a 32-bit read, and issue a barrier

Several issues in this snippet of code here:

* force_read_value() performs a word-sized read, but the int_sts register is 32-bits.
If this driver is ever re-used on a 64-bit version of the Zynq SoC (such as the zynqMP)
it will be touching 64 bits of register space instead of 32 bits.

This may have undesirable side effects. For this reason, we opt to just read the value
out of the struct raw rather than read it using force_read_value which invokes unpredictable
behaviour.

* Int_sts is already accessed through struct ttc_tmr_regs_t which is market as volatile.
This means that the compiler already cannot elide this read.

* If there is a need to ensure ordering of the read, such that the read of int_sts is executed
before any further work is done, this is accomplished through the memory barrier.


# 1a8f576b 06-Feb-2018 Kofi Doku Atuah <kofidoku.atuah@data61.csiro.au>

platsupport: Zilinx-zc7 timer: Truncate the read value from the int_sts reg


# b39d839d 06-Feb-2018 Kofi Doku Atuah <kofidoku.atuah@data61.csiro.au>

Zilinx-zc7: Fix build warning


# 46b8d612 07-Dec-2017 Anna Lyons <Anna.Lyons@data61.csiro.au>

Add force_read_value and fix zynq timer

The previous change did not build, as FORCE_READ doesn't return a value.
A new helper is required to avoid reading the value twice, as the first
read clears the status.


# b235092d 06-Dec-2017 Anna Lyons <Anna.Lyons@data61.csiro.au>

Add mechanisms for free-running timer to zynq

- Add ttc_freerun, which configures the ttc to be in freerunning up
counter mode with interrupt on overflow.
- return the status of the interrupt from ttc_handle_irq - this is
required as users of the driver need to know if an irq has occured, and
reading it clears the irq.
- expose ttc_ticks_to_ns, a function to convert from ttc ticks


# a0328038 06-Dec-2017 Anna Lyons <Anna.Lyons@data61.csiro.au>

Add documentation from the manual to zynq ttc


# 24bef7ef 21-Jul-2017 Nathan Studer <nathan.studer@dornerworks.com>

Add ZynqMP platform files


# 1e28b1a1 21-Jul-2017 Nathan Studer <nathan.studer@dornerworks.com>

Re-arrange Zynq7000 platform files to make a Zynq7000 machine