summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Kettenis <kettenis@cvs.openbsd.org>2017-05-07 11:25:59 +0000
committerMark Kettenis <kettenis@cvs.openbsd.org>2017-05-07 11:25:59 +0000
commit89b3be7db2b51c7d0924de1c1a472def682cf6cd (patch)
treed1a9a7523717d99fc742597bc61663e3e6a82e74
parent2efd727879baca857b60c0dcb220b71137cfa718 (diff)
Sync FDT code with arm64.
-rw-r--r--sys/arch/armv7/stand/efiboot/fdt.c8
-rw-r--r--sys/arch/armv7/stand/efiboot/fdt.h6
2 files changed, 7 insertions, 7 deletions
diff --git a/sys/arch/armv7/stand/efiboot/fdt.c b/sys/arch/armv7/stand/efiboot/fdt.c
index 8d95817a075..7c1ba49f249 100644
--- a/sys/arch/armv7/stand/efiboot/fdt.c
+++ b/sys/arch/armv7/stand/efiboot/fdt.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: fdt.c,v 1.4 2016/05/19 19:32:07 kettenis Exp $ */
+/* $OpenBSD: fdt.c,v 1.5 2017/05/07 11:25:58 kettenis Exp $ */
/*
* Copyright (c) 2009 Dariusz Swiderski <sfires@sfires.net>
@@ -219,7 +219,7 @@ fdt_node_property(void *node, char *name, char **out)
}
int
-fdt_node_set_property(void *node, char *name, char *data, int len)
+fdt_node_set_property(void *node, char *name, void *data, int len)
{
uint32_t *ptr, *next;
uint32_t nameid;
@@ -245,7 +245,7 @@ fdt_node_set_property(void *node, char *name, char *data, int len)
curlen = betoh32(*(ptr + 1));
delta = roundup(len, sizeof(uint32_t)) -
roundup(curlen, sizeof(uint32_t));
- memmove((char *)next + delta, next,
+ memmove((char *)next + delta, next,
tree.end - (char *)next);
tree.struct_size += delta;
if (tree.strings > tree.tree)
@@ -263,7 +263,7 @@ fdt_node_set_property(void *node, char *name, char *data, int len)
}
int
-fdt_node_add_property(void *node, char *name, char *data, int len)
+fdt_node_add_property(void *node, char *name, void *data, int len)
{
char *dummy;
diff --git a/sys/arch/armv7/stand/efiboot/fdt.h b/sys/arch/armv7/stand/efiboot/fdt.h
index eb030d2bd60..747cf7c29ed 100644
--- a/sys/arch/armv7/stand/efiboot/fdt.h
+++ b/sys/arch/armv7/stand/efiboot/fdt.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: fdt.h,v 1.2 2016/05/17 22:41:20 kettenis Exp $ */
+/* $OpenBSD: fdt.h,v 1.3 2017/05/07 11:25:58 kettenis Exp $ */
/*
* Copyright (c) 2009 Dariusz Swiderski <sfires@sfires.net>
@@ -57,8 +57,8 @@ void *fdt_child_node(void *);
char *fdt_node_name(void *);
void *fdt_find_node(char *);
int fdt_node_property(void *, char *, char **);
-int fdt_node_set_property(void *, char *, char *, int);
-int fdt_node_add_property(void *, char *, char *, int);
+int fdt_node_set_property(void *, char *, void *, int);
+int fdt_node_add_property(void *, char *, void *, int);
void *fdt_parent_node(void *);
int fdt_node_is_compatible(void *, const char *);
#ifdef DEBUG