Home › Forums › snickerdoodle Baseboards › • piSmasher › PHY reset from PL

Tagged: 

Viewing 2 reply threads
  • Author
    Posts
    • robindust
      Participant
      Post count: 3

      Hello,

      I’m trying to use the AXI Ethernet Subsystem from Xilinx to route the piSmasher Ethernet ports through the PL. How do I connect the phy_reset signal to the PHYs of the piSmasher. I know from the device trees that for the PS GEM the PHY reset is connected to MIO 19 and 17 but I can’t gather from the schematics how to reset the PHY from the MAC in PL. Could someone please give me a hint?

      Thank you in advance!

    • Ryan Cousins
      Keymaster
      Post count: 343

      Hi Robin,

      If the reset line is connected to an MIO, you’d have to issue an AXI transaction to a register in the PS GPIO peripheral from the PL via one of the slave AXI ports to accomplish what you’re describing. That’s entirely possible, but not trivial.

      Is there a reason for adding this particular functionality? It seems unlikely the reset control would require the high performance afforded by driving it from the PL…it would be much easier to do it in software.

      Something simple like: Some software in Linux polling a register in PL for the reset command, then perform the reset and ACK it.

      Otherwise, to do it directly from PL, you really are bypassing the Linux driver…which could get you in all kinds of trouble. It *can* be done, but we probably wouldn’t recommend it, as that GPIO pin is probably defined in a register common to other GPIO pins controlled from Linux, so you can imagine there are two writers in that case—some random PL logic and the Linux driver—that might write the same register. Not good.

      For reference, the reason the resets are on MIO is to allow power/reset control over these external chips even when the PL is not programmed.

      -Ryan

    • robindust
      Participant
      Post count: 3

      Hi Ryan,

      thank you very much for your response. I guess your answer shows that I didn’t yet fully understand how the phy reset works. How I understand it the reset lines of the Marvell phys are wired to MIO Pins 19 & 17 and I can’t change that, correct?

      I had the idea to drive the reset signal from the PL because the axi ethernet IP core provides the possibility to generate an appropriate reset signal. I am using FreeRTOS + lwIP and from what I can see there is no driver for resetting the PHY through MIO. I also understand that Linux provides such a driver which is configured through the device tree, however I have no idea how I would do something similar in FreeRTOS.

Viewing 2 reply threads
  • You must be logged in to reply to this topic.