Add support for the announce receipt timeout management request.
Signed-off-by: Richard Cochran <richardcochran@gmail.com>master
parent
555c42e3d0
commit
d2f8bc5e38
7
pmc.c
7
pmc.c
|
@ -90,7 +90,7 @@ struct management_id idtab[] = {
|
||||||
{ "CLOCK_DESCRIPTION", CLOCK_DESCRIPTION, do_get_action },
|
{ "CLOCK_DESCRIPTION", CLOCK_DESCRIPTION, do_get_action },
|
||||||
{ "PORT_DATA_SET", PORT_DATA_SET, do_get_action },
|
{ "PORT_DATA_SET", PORT_DATA_SET, do_get_action },
|
||||||
{ "LOG_ANNOUNCE_INTERVAL", LOG_ANNOUNCE_INTERVAL, do_get_action },
|
{ "LOG_ANNOUNCE_INTERVAL", LOG_ANNOUNCE_INTERVAL, do_get_action },
|
||||||
{ "ANNOUNCE_RECEIPT_TIMEOUT", ANNOUNCE_RECEIPT_TIMEOUT, not_supported },
|
{ "ANNOUNCE_RECEIPT_TIMEOUT", ANNOUNCE_RECEIPT_TIMEOUT, do_get_action },
|
||||||
{ "LOG_SYNC_INTERVAL", LOG_SYNC_INTERVAL, not_supported },
|
{ "LOG_SYNC_INTERVAL", LOG_SYNC_INTERVAL, not_supported },
|
||||||
{ "VERSION_NUMBER", VERSION_NUMBER, not_supported },
|
{ "VERSION_NUMBER", VERSION_NUMBER, not_supported },
|
||||||
{ "ENABLE_PORT", ENABLE_PORT, not_supported },
|
{ "ENABLE_PORT", ENABLE_PORT, not_supported },
|
||||||
|
@ -400,6 +400,11 @@ static void pmc_show(struct ptp_message *msg, FILE *fp)
|
||||||
fprintf(fp, "LOG_ANNOUNCE_INTERVAL "
|
fprintf(fp, "LOG_ANNOUNCE_INTERVAL "
|
||||||
IFMT "logAnnounceInterval %hhd", mtd->val);
|
IFMT "logAnnounceInterval %hhd", mtd->val);
|
||||||
break;
|
break;
|
||||||
|
case ANNOUNCE_RECEIPT_TIMEOUT:
|
||||||
|
mtd = (struct management_tlv_datum *) mgt->data;
|
||||||
|
fprintf(fp, "ANNOUNCE_RECEIPT_TIMEOUT "
|
||||||
|
IFMT "announceReceiptTimeout %hhu", mtd->val);
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
out:
|
out:
|
||||||
fprintf(fp, "\n");
|
fprintf(fp, "\n");
|
||||||
|
|
6
port.c
6
port.c
|
@ -564,6 +564,12 @@ static int port_management_get_response(struct port *target,
|
||||||
datalen = sizeof(*mtd);
|
datalen = sizeof(*mtd);
|
||||||
respond = 1;
|
respond = 1;
|
||||||
break;
|
break;
|
||||||
|
case ANNOUNCE_RECEIPT_TIMEOUT:
|
||||||
|
mtd = (struct management_tlv_datum *) tlv->data;
|
||||||
|
mtd->val = target->announceReceiptTimeout;
|
||||||
|
datalen = sizeof(*mtd);
|
||||||
|
respond = 1;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
if (respond) {
|
if (respond) {
|
||||||
if (datalen % 2) {
|
if (datalen % 2) {
|
||||||
|
|
Loading…
Reference in New Issue