UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Adventurer
Adventurer
369 Views
Registered: ‎06-24-2011

zynq MPSOC Ethernet DHCP not working

Jump to solution

Hello,

We made 2 boards with different Ethernet PHY chips.

PCB1: XCZU17EG + Marvell 88E1518

PCB2: XCZU7CG + TI DP83867CRRGZ

When I built the u-boot and linux kernel, with petalinux default settings PCB1 is working OK: I see macb driver, DHCP working, everything is perfect.

Then I repeat the same steps for PCB2. I only get the static IP mode working: ping and tftp ok. Macb driver is fine after I modify the system-user.dtsi but still DHCP not function.

In PCB2, static IP mode works telling me that the hardware, board level connectivity are good.

So I use WireShark to check what exactly the zynq MPSOC pop out. A good working packet shows in good.png attached. I found that in the PCB2 the packets are padding all 0s or chopped shorter, see bad_1.png and bad_2.png.

I would guess this is a linux driver issue. How to debug this?

Please advice, thank you.

 

 

 

 

good.png
bad_1.png
bad_2.png
0 Kudos
1 Solution

Accepted Solutions
Adventurer
Adventurer
133 Views
Registered: ‎06-24-2011

Re: zynq MPSOC Ethernet DHCP not working

Jump to solution

Solve the problem !

The PS side reference clock shuold be 33.3333MHz, ours is 33MHz. After replace to 33.3333MHz OSC, DHCP is working. Ethernet is working.

Learned experience:

If a feature is partially function or running shaky, check the OSC frequency. When order parts, MUST tell vendor the exact value. For example, 33 MHz must say 33.000MHz, 33.3333MHz must say 33.3333MHzm not 33.3MHz.

I guess latest technology is more sensitive to the frequency than the old ones.....

 

0 Kudos
6 Replies
Adventurer
Adventurer
305 Views
Registered: ‎06-24-2011

Re: zynq MPSOC Ethernet DHCP not working

Jump to solution

Hi 

I would like to add more info.

Under U-boot, I use "dhcp" command to force FPGA pops out DHCP request packet. And I do see a few correct DHCP Request packets are sent, but most of them are bad packets.

Under Kernel, I use "udhcpc" command to force FPGA pops out DHCP request packet. I have the same result as above. 

Attached my boot log along with the WireShark packet capture.

 

Under U-boot use "mii" command I can talk to PHY normally and get its status OK. Don't see anything wrong.  Sure, because I can ping and tftp in static IP mode.

Is this a PHY chip/PCB harware issue or a petalinux issue?

Please advice, thank you.

 

 

0 Kudos
Adventurer
Adventurer
286 Views
Registered: ‎06-24-2011

Re: zynq MPSOC Ethernet DHCP not working

Jump to solution

Sorry about wrong info the previous post.

Actually there are none good DHCP packets from my PCB at all. I connect a cabel between my windows PC and my PCB with WireShark capturing on my PC. The DHCP request (with red error) actually comes from my PC, not my board.

So, there is never good DHCP Discover packet comes out from my PCB.

 

0 Kudos
Adventurer
Adventurer
252 Views
Registered: ‎06-24-2011

Re: zynq MPSOC Ethernet DHCP not working

Jump to solution

After few days working, here is the narrow down comments:

Static IP mode working detail:

PC <-> PCB. Ping each other is good. The WireShark captured the ping packets is less than 100 bytes.

PC -> PCB download 32MB file by tftp OK. So RX is good.

PC <- PCB upload 1KB file by tftp failed.

PC <- PCB upload few bytes data by tftp OK.

=> So there is something wrong about transmitting long packets.

DHCP mode:

Under U-boot, send "DHCP" command, PCB should send out DHCP packets. However DHCP packet is 347 bytes long, it is chopped to less than 150 byte packets.

=> So the DHCP is not working is because at TX side there is "zero-padding" and "corrupt packets" issue.

It looks like a TX timing issue. 

We scanned all 16 TX clock delay values in PHY RGMII Delay Control Register but no luck, long packets are still cut to short packets.

Now we will try to see if we can change some settings in Vivado, like attached picture.

Any othere suggestion please?

 

vivado.png
0 Kudos
Participant kallensf
Participant
236 Views
Registered: ‎07-31-2017

Re: zynq MPSOC Ethernet DHCP not working

Jump to solution

The TI DP83867 can be a bit picky based on resistor straps.  Maybe check voltages?

0 Kudos
Adventurer
Adventurer
171 Views
Registered: ‎06-24-2011

Re: zynq MPSOC Ethernet DHCP not working

Jump to solution

Hi Kallensf,

Thanks for the reply. 

We use the control register to control the clock skew instead of using resistors strap  configuration method because we are trying to avoid that "picky" situation like you said. We don't use any strap resistor at all.

Not sure how TI handles this. Does the strap configuration overwrite the register settings? 

The power rail on our PCB is fixed and not adjustable. Will see if we can play with it.

 

0 Kudos
Adventurer
Adventurer
134 Views
Registered: ‎06-24-2011

Re: zynq MPSOC Ethernet DHCP not working

Jump to solution

Solve the problem !

The PS side reference clock shuold be 33.3333MHz, ours is 33MHz. After replace to 33.3333MHz OSC, DHCP is working. Ethernet is working.

Learned experience:

If a feature is partially function or running shaky, check the OSC frequency. When order parts, MUST tell vendor the exact value. For example, 33 MHz must say 33.000MHz, 33.3333MHz must say 33.3333MHzm not 33.3MHz.

I guess latest technology is more sensitive to the frequency than the old ones.....

 

0 Kudos