summaryrefslogtreecommitdiffstats
path: root/cpukit/dtc/libfdt/fdt_wip.c
diff options
context:
space:
mode:
authorDavid Gibson <david@gibson.dropbear.id.au>2017-10-18 17:22:40 +1100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2018-07-19 07:01:11 +0200
commit42f1b3762acf72032696e0817f81f4cb069a446e (patch)
treed307028f839a77f5a4027592172154614e279e4f /cpukit/dtc/libfdt/fdt_wip.c
parentFix some errors in comments (diff)
downloadrtems-42f1b3762acf72032696e0817f81f4cb069a446e.tar.bz2
libfdt: Remove leading underscores from identifiers
In a lot of places libfdt uses a leading _ character to mark an identifier as "internal" (not part of the published libfdt API). This is a bad idea, because identifiers with a leading _ are generally reserved by the C library or system. It's particularly dangerous for libfdt, because it's designed to be able to be integrated into lots of different environments. In some cases the leading _ has no purpose, so we simply drop it. In most cases we move it to the end, as our new convention for marking internal identifiers. Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to '')
-rw-r--r--cpukit/dtc/libfdt/fdt_wip.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/cpukit/dtc/libfdt/fdt_wip.c b/cpukit/dtc/libfdt/fdt_wip.c
index 5e85919862..534c1cbbb2 100644
--- a/cpukit/dtc/libfdt/fdt_wip.c
+++ b/cpukit/dtc/libfdt/fdt_wip.c
@@ -93,7 +93,7 @@ int fdt_setprop_inplace(void *fdt, int nodeoffset, const char *name,
val, len);
}
-static void _fdt_nop_region(void *start, int len)
+static void fdt_nop_region_(void *start, int len)
{
fdt32_t *p;
@@ -110,12 +110,12 @@ int fdt_nop_property(void *fdt, int nodeoffset, const char *name)
if (!prop)
return len;
- _fdt_nop_region(prop, len + sizeof(*prop));
+ fdt_nop_region_(prop, len + sizeof(*prop));
return 0;
}
-int _fdt_node_end_offset(void *fdt, int offset)
+int fdt_node_end_offset_(void *fdt, int offset)
{
int depth = 0;
@@ -129,11 +129,11 @@ int fdt_nop_node(void *fdt, int nodeoffset)
{
int endoffset;
- endoffset = _fdt_node_end_offset(fdt, nodeoffset);
+ endoffset = fdt_node_end_offset_(fdt, nodeoffset);
if (endoffset < 0)
return endoffset;
- _fdt_nop_region(fdt_offset_ptr_w(fdt, nodeoffset, 0),
+ fdt_nop_region_(fdt_offset_ptr_w(fdt, nodeoffset, 0),
endoffset - nodeoffset);
return 0;
}