blob: d00aa31074475946b80fbce55aa4bdc66a0f6a22 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
/*
* SPDX-License-Identifier: BSD-2-Clause
*
* Copyright (c) 2020 Western Digital Corporation or its affiliates.
*
* Authors:
* Anup Patel <anup.patel@wdc.com>
*/
#include <sbi/sbi_error.h>
#include <sbi/sbi_scratch.h>
#include <sbi_utils/fdt/fdt_helper.h>
#include <sbi_utils/timer/fdt_timer.h>
/* List of FDT timer drivers generated at compile time */
extern const struct fdt_driver *const fdt_timer_drivers[];
int fdt_timer_init(void)
{
/*
* Systems with Sstc might not provide any node in the FDT,
* so do not return a failure if no device is found.
*/
return fdt_driver_init_all(fdt_get_address(), fdt_timer_drivers);
}
|