Signed-off-by: Anders Selhammer <[email protected]>
---
pmc_common.c | 5 +++++
pmc_common.h | 2 ++
snmp4lptp.c | 5 +++++
snmp4lptp_mib.h | 1 +
4 files changed, 13 insertions(+)
diff --git a/pmc_common.c b/pmc_common.c
index 4a160f6..b5843b9 100644
--- a/pmc_common.c
+++ b/pmc_common.c
@@ -479,6 +479,11 @@ static int pmc_tlv_datalen(struct pmc *pmc, int id)
return len;
}
+UInteger8 pmc_get_domain_number(struct pmc *pmc)
+{
+ return pmc->domain_number;
+}
+
int pmc_get_transport_fd(struct pmc *pmc)
{
return pmc->fdarray.fd[FD_GENERAL];
diff --git a/pmc_common.h b/pmc_common.h
index b1fdcd6..8952151 100644
--- a/pmc_common.h
+++ b/pmc_common.h
@@ -40,6 +40,8 @@ struct pmc *pmc_create(struct config *cfg, enum
transport_type transport_type,
void pmc_destroy(struct pmc *pmc);
+UInteger8 pmc_get_domain_number(struct pmc *pmc);
+
int pmc_get_transport_fd(struct pmc *pmc);
int pmc_send_get_action(struct pmc *pmc, int id);
diff --git a/snmp4lptp.c b/snmp4lptp.c
index e06f212..c70aefa 100644
--- a/snmp4lptp.c
+++ b/snmp4lptp.c
@@ -65,6 +65,11 @@ struct ptp_message* snmp4lptp_run_pmc(char *cmd)
return NULL;
}
+uint8_t snmp4lptp_get_domain()
+{
+ return pmc_get_domain_number(pmc);
+}
+
static int open_pmc(struct config *cfg)
{
char uds_local[MAX_IFNAME_SIZE + 1];
diff --git a/snmp4lptp_mib.h b/snmp4lptp_mib.h
index f135006..af449ce 100644
--- a/snmp4lptp_mib.h
+++ b/snmp4lptp_mib.h
@@ -26,5 +26,6 @@
* function declarations
*/
struct ptp_message* snmp4lptp_run_pmc(char *cmd);
+uint8_t snmp4lptp_get_domain();
#endif /* HAVE_SNMP4LPTP_MIB_H */
--
1.8.3.1
_______________________________________________
Linuxptp-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linuxptp-devel