Re: [Linuxptp-users] can linuxptp run on a single system?

2022-11-23 Thread Miroslav Lichvar
On Wed, Nov 23, 2022 at 03:35:57PM +0800, Hamilton Alex wrote: > so I wonder whether linuxptp can run on a single system(one CPU)? You can have multiple ptp4l instances talking to each other on a single system, but you need to disable the loopback shortcut between them. The easiest way to do that

Re: [Linuxptp-users] Unable run ptp4l using Virtual Clock

2022-11-23 Thread Amar B S
Hi Miroslav, I checked your patch and tried it, but in my setup, it's failing well before the part of the code you have changed. The function "*rtnl_iface_has_vclock*" determines whether the given clock is VPHC which is failing and hence it exits during the Initialization phase itself. [root@supe

Re: [Linuxptp-users] can linuxptp run on a single system?

2022-11-23 Thread Hamilton Alex
Hi, Miroslav: Thank you for your reply! but i didn't understand, on a single system, port 0 as master and port 1 as slave, and there is cable connect port 0 and port 1 for pkt communication. why ptp protocol doesn't work this way? Thanks Alex Miroslav Lichvar 于2022年11月23日周三 16:00写道: > On Wed, N

Re: [Linuxptp-users] can linuxptp run on a single system?

2022-11-23 Thread Miroslav Lichvar
On Wed, Nov 23, 2022 at 08:41:36PM +0800, Hamilton Alex wrote: > Hi, Miroslav: > Thank you for your reply! > but i didn't understand, on a single system, port 0 as master and port 1 as > slave, and there is cable connect port 0 and port 1 for pkt communication. > why ptp protocol doesn't work this

Re: [Linuxptp-users] Unable run ptp4l using Virtual Clock

2022-11-23 Thread Amar B S
*} else if (p->phc_index >= 0 && * * p->phc_index != interface_phc_index(interface)) {* * if (rtnl_iface_has_vclock(interface_name(interface),* * p->phc_index)) {* *pr_info("%s: /dev/ptp%d is virtual clock",* *p->log_name, p->phc

Re: [Linuxptp-users] Unable run ptp4l using Virtual Clock

2022-11-23 Thread Miroslav Lichvar
On Wed, Nov 23, 2022 at 07:53:32PM +0530, Amar B S wrote: > This part of the code checks if VPHC is present using NetLink messages, it > seems like we are not getting the expected response, hence failing to > detect the VPHC. Can you please run ptp4l in strace and post the output? -- Miroslav Li

Re: [Linuxptp-users] can linuxptp run on a single system?

2022-11-23 Thread Hamilton Alex
no, i am not using hybrid_e2e option. just two port, port 0 as master and port 1 as slave (ordinary clock mode), and they are connected with cable. run ptp4l on port 0 and run another ptp4l on port 1, but port 0 didn't send delay response message. Thanks Alex Miroslav Lichvar 于2022年11月23日周三 22:

Re: [Linuxptp-users] Unable run ptp4l using Virtual Clock

2022-11-23 Thread Amar B S
Hi, I have attached the strace log. Thanks, Amar B S On Wed, Nov 23, 2022 at 8:00 PM Miroslav Lichvar wrote: > On Wed, Nov 23, 2022 at 07:53:32PM +0530, Amar B S wrote: > > This part of the code checks if VPHC is present using NetLink messages, > it > > seems like we are not getting the expect