mirror of
https://github.com/Fishwaldo/u-boot.git
synced 2025-03-21 22:51:37 +00:00
dm: timer: Fix several nits
This changes 'Timer' to 'timer' at several places. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Acked-by: Thomas Chou <thomas@wytron.com.tw> Reviewed-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
parent
4a421a67b6
commit
435ae76edd
3 changed files with 14 additions and 13 deletions
|
@ -1,23 +1,23 @@
|
||||||
menu "Timer Support"
|
menu "Timer Support"
|
||||||
|
|
||||||
config TIMER
|
config TIMER
|
||||||
bool "Enable Driver Model for Timer drivers"
|
bool "Enable driver model for timer drivers"
|
||||||
depends on DM
|
depends on DM
|
||||||
help
|
help
|
||||||
Enable driver model for Timer access. It uses the same API as
|
Enable driver model for timer access. It uses the same API as
|
||||||
lib/time.c. But now implemented by the uclass. The first timer
|
lib/time.c, but now implemented by the uclass. The first timer
|
||||||
will be used. The timer is usually a 32 bits free-running up
|
will be used. The timer is usually a 32 bits free-running up
|
||||||
counter. There may be no real tick, and no timer interrupt.
|
counter. There may be no real tick, and no timer interrupt.
|
||||||
|
|
||||||
config ALTERA_TIMER
|
config ALTERA_TIMER
|
||||||
bool "Altera Timer support"
|
bool "Altera timer support"
|
||||||
depends on TIMER
|
depends on TIMER
|
||||||
help
|
help
|
||||||
Select this to enable an timer for Altera devices. Please find
|
Select this to enable a timer for Altera devices. Please find
|
||||||
details on the "Embedded Peripherals IP User Guide" of Altera.
|
details on the "Embedded Peripherals IP User Guide" of Altera.
|
||||||
|
|
||||||
config SANDBOX_TIMER
|
config SANDBOX_TIMER
|
||||||
bool "Sandbox Timer support"
|
bool "Sandbox timer support"
|
||||||
depends on SANDBOX && TIMER
|
depends on SANDBOX && TIMER
|
||||||
help
|
help
|
||||||
Select this to enable an emulated timer for sandbox. It gets
|
Select this to enable an emulated timer for sandbox. It gets
|
||||||
|
|
|
@ -10,10 +10,10 @@
|
||||||
#include <timer.h>
|
#include <timer.h>
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Implement a Timer uclass to work with lib/time.c. The timer is usually
|
* Implement a timer uclass to work with lib/time.c. The timer is usually
|
||||||
* a 32 bits free-running up counter. The get_rate() method is used to get
|
* a 32 bits free-running up counter. The get_rate() method is used to get
|
||||||
* the input clock frequency of the timer. The get_count() method is used
|
* the input clock frequency of the timer. The get_count() method is used
|
||||||
* get the current 32 bits count value. If the hardware is counting down,
|
* to get the current 32 bits count value. If the hardware is counting down,
|
||||||
* the value should be inversed inside the method. There may be no real
|
* the value should be inversed inside the method. There may be no real
|
||||||
* tick, and no timer interrupt.
|
* tick, and no timer interrupt.
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -10,30 +10,31 @@
|
||||||
/*
|
/*
|
||||||
* Get the current timer count
|
* Get the current timer count
|
||||||
*
|
*
|
||||||
* @dev: The Timer device
|
* @dev: The timer device
|
||||||
* @count: pointer that returns the current timer count
|
* @count: pointer that returns the current timer count
|
||||||
* @return: 0 if OK, -ve on error
|
* @return: 0 if OK, -ve on error
|
||||||
*/
|
*/
|
||||||
int timer_get_count(struct udevice *dev, unsigned long *count);
|
int timer_get_count(struct udevice *dev, unsigned long *count);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Get the timer input clock frequency
|
* Get the timer input clock frequency
|
||||||
*
|
*
|
||||||
* @dev: The Timer device
|
* @dev: The timer device
|
||||||
* @return: the timer input clock frequency
|
* @return: the timer input clock frequency
|
||||||
*/
|
*/
|
||||||
unsigned long timer_get_rate(struct udevice *dev);
|
unsigned long timer_get_rate(struct udevice *dev);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* struct timer_ops - Driver model Timer operations
|
* struct timer_ops - Driver model timer operations
|
||||||
*
|
*
|
||||||
* The uclass interface is implemented by all Timer devices which use
|
* The uclass interface is implemented by all timer devices which use
|
||||||
* driver model.
|
* driver model.
|
||||||
*/
|
*/
|
||||||
struct timer_ops {
|
struct timer_ops {
|
||||||
/*
|
/*
|
||||||
* Get the current timer count
|
* Get the current timer count
|
||||||
*
|
*
|
||||||
* @dev: The Timer device
|
* @dev: The timer device
|
||||||
* @count: pointer that returns the current timer count
|
* @count: pointer that returns the current timer count
|
||||||
* @return: 0 if OK, -ve on error
|
* @return: 0 if OK, -ve on error
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Add table
Reference in a new issue