Hi,
I am using Vayu EVM xc577x Rev G booted with GLSDK 6.04 .
I enabled CPTS driver in the kernel and I get Hardware timestamp from the driver.I am running linux PTP code.
and when I run the code I find there is no synchronisation happening i.e I find the offset drifting badly
./ptp4l -P -4 -m -i eth0 -H -p /dev/ptp0
ptp4l[871.288]: selected /dev/ptp0 as PTP clock
ptp4l[871.288]: port 1: get_ts_info not supported
ptp4l[871.311]: port 1: INITIALIZING to LISTENING on INITIALIZE
ptp4l[871.311]: port 0: INITIALIZING to LISTENING on INITIALIZE
ptp4l[875.482]: port 1: new foreign master 001560.fffe.52d0c9-1
ptp4l[877.478]: port 1: LISTENING to MASTER on ANNOUNCE_RECEIPT_TIMEOUT_EXPIRES
ptp4l[877.479]: selected best master clock 7c669d.fffe.f1b614
ptp4l[877.479]: assuming the grand master role
ptp4l[879.484]: selected best master clock 001560.fffe.52d0c9
ptp4l[879.484]: foreign master not using PTP timescale
ptp4l[879.484]: port 1: MASTER to UNCALIBRATED on RS_SLAVE
ptp4l[880.484]: master offset 32110229602 s0 freq +1000000 path delay 37941
ptp4l[881.485]: master offset 32173202699 s1 freq +1000000 path delay 37902
ptp4l[882.313]: clockcheck: clock jumped backward or running slower than expected!
ptp4l[882.485]: master offset 62970420 s0 freq +1000000 path delay 37859
ptp4l[883.486]: master offset 125943262 s2 freq +1000000 path delay 37710
ptp4l[883.486]: port 1: UNCALIBRATED to SLAVE on MASTER_CLOCK_SELECTED
ptp4l[884.487]: master offset 188917998 s2 freq +1000000 path delay 37672
ptp4l[885.487]: master offset 251887569 s2 freq +1000000 path delay 37566
ptp4l[886.488]: master offset 314859373 s2 freq +1000000 path delay 37566
ptp4l[887.488]: master offset 377831772 s2 freq +1000000 path delay 37483
ptp4l[888.489]: master offset 440804305 s2 freq +1000000 path delay 37278
ptp4l[889.490]: master offset 503776325 s2 freq +1000000 path delay 37483
ptp4l[890.490]: master offset 566749993 s2 freq +1000000 path delay 37592
ptp4l[891.491]: master offset 629720768 s2 freq +1000000 path delay 37509
ptp4l[892.492]: master offset 692692830 s2 freq +1000000 path delay 37242
ptp4l[893.492]: master offset 755667746 s2 freq +1000000 path delay 37351
ptp4l[894.493]: master offset 818637052 s2 freq +1000000 path delay 37034
ptp4l[895.494]: master offset 881608272 s2 freq +1000000 path delay 37351
ptp4l[896.494]: master offset 944580370 s2 freq +1000000 path delay 37351
I have a following Questions.
I get the boot message as:
Missing dual_emac_res_vlan in DT.
[ 3.065673] Using 2 as Reserved VLAN for 1 slave
[ 3.070587] Detected MACID = 7c:66:9d:f1:b6:14
[ 3.076629] Failed to clk_get cpsw_cpts_rft_clk
[ 3.081695] cpsw: Detected MACID = 7c:66:9d:f1:b6:15
[ 3.088806] drivers/rtc/hctosys.c: unable to open rtc device (rtc0)
[ 3.095886] ALSA device list:
[ 3.098999] #0: dra7evm
[ 3.101837] #1: OMAP5HDMI
this comes from the cpts init
#define CPTS_REF_CLOCK_NAME "cpsw_cpts_rft_clk"
static void cpts_clk_init(struct cpts *cpts)
{
cpts->refclk = clk_get(NULL, CPTS_REF_CLOCK_NAME);
if (IS_ERR(cpts->refclk)) {
pr_err("Failed to clk_get %s\n", CPTS_REF_CLOCK_NAME);
cpts->refclk = NULL;
return;
}
clk_prepare_enable(cpts->refclk);
}
if this fails How I am getting timestamp?
Which clock i am trying to access with my /dev/ptp0 device ?
Please Help me!!
Regards,
Mythili.