On Wed, Aug 24, 2022 at 04:32:22PM +0530, SyncMonk Technologies wrote:
> adding APTS to participate in BMCA
>
> Passing the announce message for external source to ptp4l using virtual
> port to avoid selection of master from PTP source.
>
> Signed-off-by: Greg Armstrong <[email protected]>
> Signed-off-by: Leon Goldin <[email protected]>
> Signed-off-by: Vipin Sharma <[email protected]>
> Signed-off-by: Devasish Dey <[email protected]>
> @@ -94,6 +105,11 @@ struct ts2phc_pps_source
> *ts2phc_phc_pps_source_create(struct config *cfg,
> }
> s->pps_source.destroy = ts2phc_phc_pps_source_destroy;
> s->pps_source.getppstime = ts2phc_phc_pps_source_getppstime;
> + s->vport = ts2phc_vport_create(cfg);
> + if (!s->vport) {
> + free(s);
> + return NULL;
> + }
Why would we want to call this function and allocate the vport structure inside
it if the
config file does not request this? Seems wasteful to me.
Regards
Maciek
_______________________________________________
Linuxptp-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linuxptp-devel