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: 
Explorer
Explorer
4,354 Views
Registered: ‎11-12-2007

LL_TEMAC PHY debugging

Jump to solution

Hi guys,

I would like to debug our phy support:

I am using the 88E1111 on a custom board which is very similar to the ml403. I am using the MII interface and have the problem, that the phy is not working properly. I can receive packets, but transmitting is not possible. The MII_TX_CLK from the phy is not working, so I am guessing the phy gets not initialized properly. I would like to have more debug prints from the temac and defined DEBUG in xdebug.h resulting in a lot of compiler errors in xlltemac_main.c :

 

In file included from drivers/net/xilinx_lltemac/xlltemac_hw.h:61,
                 from drivers/net/xilinx_lltemac/xlltemac.h:276,
                 from drivers/net/xilinx_lltemac/xlltemac_main.c:38:
drivers/xilinx_common/xdebug.h:10:2: warning: #warning DEBUG is enabled
drivers/net/xilinx_lltemac/xlltemac_main.c:688:7: warning: "CONFIG_XILINX_LLTEMAC_MARVELL_88E1111_GMII" is not defined
drivers/net/xilinx_lltemac/xlltemac_main.c: In function 'reset':
drivers/net/xilinx_lltemac/xlltemac_main.c:832: error: expected expression before 'if'
drivers/net/xilinx_lltemac/xlltemac_main.c:832: error: expected expression before 'if'
drivers/net/xilinx_lltemac/xlltemac_main.c:832: warning: left-hand operand of comma expression has no effect
drivers/net/xilinx_lltemac/xlltemac_main.c:832: warning: left-hand operand of comma expression has no effect
drivers/net/xilinx_lltemac/xlltemac_main.c:869: error: expected expression before 'if'
drivers/net/xilinx_lltemac/xlltemac_main.c:869: warning: left-hand operand of comma expression has no effect
drivers/net/xilinx_lltemac/xlltemac_main.c:869: error: expected expression before 'if'
drivers/net/xilinx_lltemac/xlltemac_main.c:869: warning: value computed is not used
drivers/net/xilinx_lltemac/xlltemac_main.c:869: warning: left-hand operand of comma expression has no effect
drivers/net/xilinx_lltemac/xlltemac_main.c:869: error: expected expression before 'if'
drivers/net/xilinx_lltemac/xlltemac_main.c:869: error: expected expression before 'if'
drivers/net/xilinx_lltemac/xlltemac_main.c:869: warning: left-hand operand of comma expression has no effect
drivers/net/xilinx_lltemac/xlltemac_main.c:869: warning: left-hand operand of comma expression has no effect
drivers/net/xilinx_lltemac/xlltemac_main.c:873: error: expected expression before 'if'
drivers/net/xilinx_lltemac/xlltemac_main.c:873: error: expected expression before 'if'
drivers/net/xilinx_lltemac/xlltemac_main.c: In function 'xenet_temac_interrupt':
drivers/net/xilinx_lltemac/xlltemac_main.c:993: error: expected expression before 'if'

 

 

At kernel startup all looks good:

 

Device Tree Probing 'ethernet'
xilinx_lltemac 71000000.ethernet: MAC address is now  0: a:35:e6:2a: 0
xilinx_lltemac 71000000.ethernet: XLlTemac: using DMA mode.
XLlTemac: Dma base address: phy: 0xc0900100, virt: 0xe1828100
XLlTemac: buffer descriptor size: 32768 (0x8000)
XLlTemac: Allocating DMA descriptors with kmalloc
XLlTemac: (buffer_descriptor_init) phy: 0x1f8d0000, virt: 0xdf8d0000, size: 0x8000
XTemac: PHY detected at address 7.
xilinx_lltemac 71000000.ethernet: eth0: Xilinx TEMAC at 0x71000000 mapped to 0xE1824000, irq=21

ifconfig:
root:~> ifconfig eth0 up
eth0: XLlTemac: Options: 0x3fa
eth0: XLlTemac: allocating interrupt 22 for dma mode tx.
eth0: XLlTemac: allocating interrupt 23 for dma mode rx.
eth0: XLlTemac: We renegotiated the speed to: 100
eth0: XLlTemac: speed set to 100Mb/s
eth0: XLlTemac: Send Threshold = 24, Receive Threshold = 4
eth0: XLlTemac: Send Wait bound = 254, Receive Wait bound = 254
root:~> eth0: XLlTemac: We renegotiated the speed to: 100
eth0: XLlTemac: speed set to 100Mb/s
eth0: XLlTemac: PHY Link carrier restored.

 

 

Also I would like to insert the PHY support for the Marvell 88E6061, so I would like to have more debug information about the phy initialization.

 

0 Kudos
1 Solution

Accepted Solutions
Explorer
Explorer
5,184 Views
Registered: ‎11-12-2007

Re: LL_TEMAC PHY debugging

Jump to solution

Hi,

I did not manage to enable the debug prints within the lltemac driver, but I was able to enable the debug symbols (virtex4 default kernel configuration from git does not have kernel hacking on, like the virtex5 default config)

 

Also I came over the OCM issue:

 http://forums.xilinx.com/t5/EDK-and-Platform-Studio/linux-booting-problem/m-p/24109?query.id=367949#M6235

 

Is it really not possible to have the OCM attached to the PPC when using the MMU and Linux? I'd like to have some peripherals on the OCM, because the latency is much shorter than using the PLB for that.

0 Kudos
2 Replies
Explorer
Explorer
5,185 Views
Registered: ‎11-12-2007

Re: LL_TEMAC PHY debugging

Jump to solution

Hi,

I did not manage to enable the debug prints within the lltemac driver, but I was able to enable the debug symbols (virtex4 default kernel configuration from git does not have kernel hacking on, like the virtex5 default config)

 

Also I came over the OCM issue:

 http://forums.xilinx.com/t5/EDK-and-Platform-Studio/linux-booting-problem/m-p/24109?query.id=367949#M6235

 

Is it really not possible to have the OCM attached to the PPC when using the MMU and Linux? I'd like to have some peripherals on the OCM, because the latency is much shorter than using the PLB for that.

0 Kudos
Highlighted
Xilinx Employee
Xilinx Employee
4,325 Views
Registered: ‎11-28-2007

Re: LL_TEMAC PHY debugging

Jump to solution

 

Hi Timo,

this is how I had enabled the debug prints of the lltemac:

 

Make a local copy of the drivers (lltemac)

Edit the local xdebug.h like

#define DEBUG

#undef NDEBUG

(do not edit the xdebug.h of the llfifo drivers, it will result in compile errors)

 

Peter

0 Kudos