configure the serdes of ls1012a to base1000-KX mode.

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

configure the serdes of ls1012a to base1000-KX mode.

1,145 次查看
295320972
Contributor II

Hi team,
    The processor we are using is ls1012a, and the code used is open source flexbuild_lsdk1812_update_010719. I read the document "Document Number: LS1012ARM Rev. 2, 02/2019" and learned that the serdes of this processor can be configured in either SGMII or base1000-KX mode. The default configuration of open source software is SGMII mode. Now I want to configure serdes to base1000-KX mode. The 28.7.1.3 1000Base-KX chapter of LS1012ARM document has detailed configuration steps. But I don't know how to read and write the following registers(The following steps are taken from the configuration of the base1000-KX mode in the LS1012ARM documentation.):

       4. Initialize 1000Base-KX (Clause 45) AN Advertisement Register 1:
               TX_NONCE=unique value per device
       5. Read 1000Base-KX (Clause 45) AN Status Register to clear any previous status
       6. Initialize 1000Base-KX (Clause 45) AN Control Register to 0x1200:
                  AN_ENAB=1
                  RST_AN=1

My question is as follows:

1.Can I use the pfe_phy_read and pfe_phy_write functions in uboot in open source code to do this?The path of these two functions in uboot is drivers\net\pfe_eth\pfe_mdio.c

2.If I can use these two functions to do this, what parameters do I need to pass to these two functions (I have tried several, but did not succeed)?

3.If I can't use these two functions to do the above, what do I need to do?

Thanks!

      

标签 (1)
0 项奖励
5 回复数

987 次查看
ufedor
NXP Employee
NXP Employee

Please explain why you need a solution as U-Boot commands sequence.

For linux the solution is to modify DTS - please refer to the following Community question:

https://community.nxp.com/thread/501212 

0 项奖励

987 次查看
295320972
Contributor II

Hi ufedor,
     My application is very similar to this one.Serdes is a MAC to MAC interface without an external PHY.
What you mean is that I only need to remove "fsl,gemac-phy-id" and use "fixed-link" property to replace it in DTS?
In linux, is serdes configured to 1000Base-KX mode in this case?

Thanks,

Li

0 项奖励

987 次查看
ufedor
NXP Employee
NXP Employee

Yes.

0 项奖励

987 次查看
295320972
Contributor II

Hi ufedor,

      

  Thank you for your support, this issue has been resolved.I not only need to configure the network in DTS to work as fixed-link, but also need to set phy-mode to 1000Base-X.I read the kernel source carefully. In this configuration, the registers described in Section 28.6 (Document Number: LS1012ARM Rev. 2, 02/2019) will use the default values.According to this logical reasoning, is the register configuration by default configured to 1000Base-KX mode?
Thanks,
    
  Li
0 项奖励

987 次查看
ufedor
NXP Employee
NXP Employee

You wrote:

> to set phy-mode to 1000Base-X

What exactly you have done?

Which LSDK version was used?

0 项奖励