This information is useful to the various clock types.

Signed-off-by: Richard Cochran <richardcoch...@gmail.com>
---
 config.c | 2 ++
 config.h | 1 +
 2 files changed, 3 insertions(+)

diff --git a/config.c b/config.c
index 7bb3b05..80fa255 100644
--- a/config.c
+++ b/config.c
@@ -607,6 +607,8 @@ struct interface *config_create_interface(char *name, 
struct config *cfg)
        strncpy(iface->name, name, MAX_IFNAME_SIZE);
        sk_get_ts_info(iface->name, &iface->ts_info);
        STAILQ_INSERT_TAIL(&cfg->interfaces, iface, list);
+       cfg->n_interfaces++;
+
        return iface;
 }
 
diff --git a/config.h b/config.h
index ad057e9..b02bde6 100644
--- a/config.h
+++ b/config.h
@@ -41,6 +41,7 @@ struct interface {
 struct config {
        /* configured interfaces */
        STAILQ_HEAD(interfaces_head, interface) interfaces;
+       int n_interfaces;
 
        /* hash of all non-legacy items */
        struct hash *htab;
-- 
2.1.4


------------------------------------------------------------------------------
Find and fix application performance issues faster with Applications Manager
Applications Manager provides deep performance insights into multiple tiers of
your business applications. It resolves application problems quickly and
reduces your MTTR. Get your free trial! http://pubads.g.doubleclick.net/
gampad/clk?id=1444514301&iu=/ca-pub-7940484522588532
_______________________________________________
Linuxptp-devel mailing list
Linuxptp-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxptp-devel

Reply via email to