This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[FAQ] TDA4VM: How to disable serdes from Linux to enable serdes configuration from Ethfw and Enet lld

Part Number: TDA4VM
Other Parts Discussed in Thread: DRA821, DRA829, , TDA4VH

I am facing issues in configuring serdes from Ethfw/Enet lld aaplications for serial communication protocols. How can I disable serdes from Linux so that I am not reconfiguring it?

  • Hi,

    Serdes driver in both linux and RTOS have a check to confirm if the serdes is already configured or not. And if configured, the serdes configuration is skipped. But when working on mcu cores along with HLOS it is required for us to configure the serdes from RTOS (for ethfw/enet lld) for testing and debugging purposes. To ensure seamless configuration of serdes, we should ideally disable the serdes configuration from linux and u-boot.

    Follow these steps to disable serdes from u-boot

    1. Open the file at "[PSDK-Linux-Install-Dir]/board-support/u-boot-[Commit-Hash]/configs/<config_name>"
      1. The <config name> will depend on the type of board you are using. The defaults are mentioned here -
        1. "j7200_evm_a72_defconfig" for DRA821
        2. "j721e_evm_a72_defconfig" for TDA4VM/DRA829
        3. "j784s4_evm_a72_defconfig" for TDA4VH
    2. Comment out the "CONFIG_PHY_CADENCE_SIERRA", "CONFIG_PHY_CADENCE_TORRENT" and "CONFIG_PHY_J721E_WIZ", whichever are present.
    3. To build the modified boot loaders,
      1. Go to [PSDK-Linux-Install-Dir]
      2. run "make u-boot"
    4. Copy the "u-boot.img" binary from "[PSDK-Linux-Install-Dir]/board-support/u-boot_build/a72/" to boot partition of the boot media.
    5. Note that after this, you won't be able to use the IPs requiring serdes (like PCIe and USB) from u-boot.

    Follow these steps to disable serdes from linux kernel

    1. In the top level device-tree, you should add "status = "disabled";" in the corresponding wiz node.
      1. For eg, to disable serdes0 from linux:
        1. &serdes_wiz0 {
          	status = "disabled";
          }
      2. Default top level device-tree for different devices are as follows:
        1. "[PSDK-Linux-Install-Dir]/board-support/linux-[Commit-Hash]/arch/arm64/boot/dts/ti/k3-j7200-commom-proc-board.dts" for DRA821
        2. "[PSDK-Linux-Install-Dir]/board-support/linux-[Commit-Hash]/arch/arm64/boot/dts/ti/k3-j721e-commom-proc-board.dts" for TDA4VM/DAR829"
        3. "[PSDK-Linux-Install-Dir]/board-support/linux-[Commit-Hash]/arch/arm64/boot/dts/ti/k3-j784s4-evm.dts" for TDA4VH
      3. Note - Make sure to disable all the nodes using the serdes links defined in the serdes node.
    2. To build the dtb,
      1. Go to [PSDK-Linux-Install-Dir]
      2. run "make linux-dtbs"
    3. Copy the built dtb from "[PSDK-Linux-Install-Dir]/board-support/linux-[Commit-Hash]/arch/arm64/boot/dts/ti/<dtb-name>" to "[Boot-media-rootfs-partition]/boot/"
      1. The <dtb-name> will depend on the type of board you are using. The defaults are mentioned here -
        1. "k3-j7200-commom-proc-board.dtb" for DRA821
        2. "k3-j721e-commom-proc-board.dtb" for TDA4VM/DRA829
        3. "k3-j784s4-evm.dtb" for TDA4VH
    4. Boot the board.

    Regards,
    Tanmay