aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/sbi_utils/fdt/fdt_helper.h4
-rw-r--r--lib/utils/fdt/fdt_helper.c8
-rw-r--r--platform/fpga/openpiton/platform.c2
3 files changed, 7 insertions, 7 deletions
diff --git a/include/sbi_utils/fdt/fdt_helper.h b/include/sbi_utils/fdt/fdt_helper.h
index 1fbc215..57c4720 100644
--- a/include/sbi_utils/fdt/fdt_helper.h
+++ b/include/sbi_utils/fdt/fdt_helper.h
@@ -32,7 +32,7 @@ int fdt_parse_uart8250(void *fdt, struct platform_uart_data *uart,
int fdt_parse_plic(void *fdt, struct platform_plic_data *plic,
const char *compatible);
-int fdt_parse_clint(void *fdt, unsigned long *clint_addr,
- const char *compatible);
+int fdt_parse_compat_addr(void *fdt, unsigned long *addr,
+ const char *compatible);
#endif /* __FDT_HELPER_H__ */
diff --git a/lib/utils/fdt/fdt_helper.c b/lib/utils/fdt/fdt_helper.c
index 4757f19..573cc71 100644
--- a/lib/utils/fdt/fdt_helper.c
+++ b/lib/utils/fdt/fdt_helper.c
@@ -142,8 +142,8 @@ int fdt_parse_plic(void *fdt, struct platform_plic_data *plic,
return 0;
}
-int fdt_parse_clint(void *fdt, unsigned long *clint_addr,
- const char *compatible)
+int fdt_parse_compat_addr(void *fdt, unsigned long *addr,
+ const char *compatible)
{
int nodeoffset, rc;
@@ -151,8 +151,8 @@ int fdt_parse_clint(void *fdt, unsigned long *clint_addr,
if (nodeoffset < 0)
return nodeoffset;
- rc = fdt_get_node_addr_size(fdt, nodeoffset, clint_addr, NULL);
- if (rc < 0 || !clint_addr)
+ rc = fdt_get_node_addr_size(fdt, nodeoffset, addr, NULL);
+ if (rc < 0 || !addr)
return SBI_ENODEV;
return 0;
diff --git a/platform/fpga/openpiton/platform.c b/platform/fpga/openpiton/platform.c
index 019dcc5..c549a95 100644
--- a/platform/fpga/openpiton/platform.c
+++ b/platform/fpga/openpiton/platform.c
@@ -66,7 +66,7 @@ static int openpiton_early_init(bool cold_boot)
if (!rc)
plic = plic_data;
- rc = fdt_parse_clint(fdt, &clint_data, "riscv,clint0");
+ rc = fdt_parse_compat_addr(fdt, &clint_data, "riscv,clint0");
if (!rc)
clint_addr = clint_data;