mirror of
https://github.com/riscv-software-src/opensbi.git
synced 2025-08-25 07:41:42 +01:00
lib: utils/timer: Use fdt_driver for initialization
The timer driver subsystem does not need any extra data, so it can use `struct fdt_driver` directly. The generic fdt_timer_init() performs a best-effort initialization of all matching DT nodes. Signed-off-by: Samuel Holland <samuel.holland@sifive.com> Reviewed-by: Anup Patel <anup@brainfault.org>
This commit is contained in:

committed by
Anup Patel

parent
a524f0a507
commit
a387a8dff0
@@ -11,14 +11,10 @@
|
||||
#define __FDT_TIMER_H__
|
||||
|
||||
#include <sbi/sbi_types.h>
|
||||
#include <sbi_utils/fdt/fdt_driver.h>
|
||||
|
||||
#ifdef CONFIG_FDT_TIMER
|
||||
|
||||
struct fdt_timer {
|
||||
const struct fdt_match *match_table;
|
||||
int (*cold_init)(const void *fdt, int nodeoff, const struct fdt_match *match);
|
||||
};
|
||||
|
||||
int fdt_timer_init(void);
|
||||
|
||||
#else
|
||||
|
Reference in New Issue
Block a user