Signed-off-by: Richard Cochran <richardcoch...@gmail.com>
---
 config.c | 9 ++-------
 ds.h     | 1 -
 port.c   | 3 ++-
 ptp4l.c  | 1 -
 4 files changed, 4 insertions(+), 10 deletions(-)

diff --git a/config.c b/config.c
index c17ab73..2c97002 100644
--- a/config.c
+++ b/config.c
@@ -113,6 +113,7 @@ struct config_item config_tab[] = {
        GLOB_ITEM_DBL("pi_proportional_scale", 0.0, 0.0, DBL_MAX),
        GLOB_ITEM_DBL("step_threshold", 0.0, 0.0, DBL_MAX),
        PORT_ITEM_INT("syncReceiptTimeout", 0, 0, UINT8_MAX),
+       PORT_ITEM_INT("transportSpecific", 0, 0, 0x0F),
        GLOB_ITEM_INT("tx_timestamp_timeout", 1, 1, INT_MAX),
        PORT_ITEM_INT("udp_ttl", 1, 1, 255),
        GLOB_ITEM_INT("use_syslog", 1, 0, 1),
@@ -269,13 +270,7 @@ static enum parser_result parse_pod_setting(const char 
*option,
 
        enum parser_result r;
 
-       if (!strcmp(option, "transportSpecific")) {
-               r = get_ranged_uint(value, &uval, 0, 0x0F);
-               if (r != PARSED_OK)
-                       return r;
-               pod->transportSpecific = uval << 4;
-
-       } else if (!strcmp(option, "path_trace_enabled")) {
+       if (!strcmp(option, "path_trace_enabled")) {
                r = get_ranged_int(value, &val, 0, 1);
                if (r != PARSED_OK)
                        return r;
diff --git a/ds.h b/ds.h
index 5f4d035..f9a5d7b 100644
--- a/ds.h
+++ b/ds.h
@@ -125,7 +125,6 @@ struct portDS {
 #define FRI_ASAP (-128)
 
 struct port_defaults {
-       UInteger8 transportSpecific;
        int announce_span;
        int path_trace_enabled;
        int follow_up_info;
diff --git a/port.c b/port.c
index 9d4fe7c..c1e6151 100644
--- a/port.c
+++ b/port.c
@@ -1449,7 +1449,8 @@ static int port_initialize(struct port *p)
        p->logAnnounceInterval     = config_get_int(cfg, p->name, 
"logAnnounceInterval");
        p->announceReceiptTimeout  = config_get_int(cfg, p->name, 
"announceReceiptTimeout");
        p->syncReceiptTimeout      = config_get_int(cfg, p->name, 
"syncReceiptTimeout");
-       p->transportSpecific       = p->pod.transportSpecific;
+       p->transportSpecific       = config_get_int(cfg, p->name, 
"transportSpecific");
+       p->transportSpecific     <<= 4;
        p->logSyncInterval         = config_get_int(cfg, p->name, 
"logSyncInterval");
        p->logMinPdelayReqInterval = config_get_int(cfg, p->name, 
"logMinPdelayReqInterval");
        p->neighborPropDelayThresh = p->pod.neighborPropDelayThresh;
diff --git a/ptp4l.c b/ptp4l.c
index 2ceb484..0734549 100644
--- a/ptp4l.c
+++ b/ptp4l.c
@@ -80,7 +80,6 @@ static struct config cfg_settings = {
        },
 
        .pod = {
-               .transportSpecific = 0,
                .announce_span = 1,
                .path_trace_enabled = 0,
                .follow_up_info = 0,
-- 
2.1.4


------------------------------------------------------------------------------
_______________________________________________
Linuxptp-devel mailing list
Linuxptp-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxptp-devel

Reply via email to