[Pdbg] [PATCH 4/5] libpdbg: Add an api to get device-tree node name
Amitay Isaacs
amitay at ozlabs.org
Thu Aug 16 15:57:55 AEST 2018
Signed-off-by: Amitay Isaacs <amitay at ozlabs.org>
---
libpdbg/libpdbg.c | 5 +++++
libpdbg/libpdbg.h | 1 +
2 files changed, 6 insertions(+)
diff --git a/libpdbg/libpdbg.c b/libpdbg/libpdbg.c
index b801e5a..522bec9 100644
--- a/libpdbg/libpdbg.c
+++ b/libpdbg/libpdbg.c
@@ -127,6 +127,11 @@ char *pdbg_target_name(struct pdbg_target *target)
return target->name;
}
+const char *pdbg_target_dn_name(struct pdbg_target *target)
+{
+ return target->dn_name;
+}
+
void pdbg_set_target_property(struct pdbg_target *target, const char *name, const void *val, size_t size)
{
struct dt_property *p;
diff --git a/libpdbg/libpdbg.h b/libpdbg/libpdbg.h
index a5a52b3..56dd03a 100644
--- a/libpdbg/libpdbg.h
+++ b/libpdbg/libpdbg.h
@@ -89,6 +89,7 @@ uint32_t pdbg_target_index(struct pdbg_target *target);
uint32_t pdbg_parent_index(struct pdbg_target *target, char *klass);
char *pdbg_target_class_name(struct pdbg_target *target);
char *pdbg_target_name(struct pdbg_target *target);
+const char *pdbg_target_dn_name(struct pdbg_target *target);
void *pdbg_target_priv(struct pdbg_target *target);
void pdbg_target_priv_set(struct pdbg_target *target, void *priv);
struct pdbg_target *pdbg_target_root(void);
--
2.17.1
More information about the Pdbg
mailing list