ENET_1588_EVENTx_INPUT in Linux

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

ENET_1588_EVENTx_INPUT in Linux

879 Views
christopherlaat
Contributor I

Hello,

I am interested in being able to use the ENET_1588_EVENTx_INPUT signals that are available in the iMX6 MAC blocks in Linux to timestamp external signals. We are currently running hardware-assisted PTP (via the ptp4l/phc2sys programs) under the reference Yocto build [4.9.11-1.0.0+gc27010d (bamboo@yb4) (gcc version 6.2.0 (GCC) ) #1 SMP PREEMPT Sun Sep 17 14:01:41 CDT 2017] on our NXP MCIMX6UL-BB Evaluation Board.

I realize that the reference board, as designed may not allow us physical access to the signals but I was more interested in "conceptually" how I would access the timestamps in Linux (or if there were even available or if the driver support the functionality) as well as a sample of the Device Tree Modifications that would be necessary to enable the features. If there is a method of accessing these signals, we would integrate those into our customer "carrier board".

If anyone has experience time stamping external signals via the ENET_1588_EVENTx_INPUT signals in Linux, any information that can be provided would be very much appreciated.

Thanks in advance,

Chris Laatsch

0 Kudos
2 Replies

658 Views
christopherlaat
Contributor I

Igor,

Thanks for the prompt response. I tool a look at both the (fec.h) and (fec_ptp.c) source, as specified in the i.MX_Linux_Reference_Manual and was able to the #define's for the TCCRx registers (I believe these are the "capture" registers for the IEEE-1588 H/W block). Judging by your statement (and the source code), it appears that the driver supports all of the functionality that we require.

My follow up question for you is, as it stands with the base BSP Linux version provided by NXP, are there any method(s) of reading the values that would be captured into the TCCRx registers from userspace (say through the Sysfs or /proc)? This would strictly be for testing/evaluation purposes only but would be an easier start then having to write any additional code right now. If you (or anyone else) has any idea or sample code that could be useful for evaluation purposes, that would be fantastic.

Thanks again for the help,

Chris

0 Kudos

658 Views
igorpadykov
NXP Employee
NXP Employee

Hi Chris

general description and procedures can be found on

IEEE 1588 feature on i.MX6Q Gigabit Ethernet MAC 

Table 22-1. ENET1 External Signals i.MX6UL Reference Manual

http://www.nxp.com/docs/en/reference-manual/IMX6ULRM.pdf

Chapter 44 ENET IEEE-1588 Driver attached Linux Manual, all NXP software is described on

i.MX Software|NXP 


Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos