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.

TLK110 phy problem using Arago Linux 3.2.0. I can't ping correctly.

Other Parts Discussed in Thread: TLK110, AM3359

HI,

for our purpose i'm using a custom board with Sitara AM3359, and TLK110.

I'm working for porting Linux to this board, and now i'm able to boot it correctly (U-Boot). But i can't get work my ethernet, that it is connected to MAC throw MII like "Industrial Auto Motor Control EVM": so i choose to use the same configuration in pinmux and in my setup function...

 am33xx_cpsw_init(AM33XX_CPSW_MODE_MII, "0:1e", "0:00");

So using ifconfig for use manual IP set up, and trying to ping my PC (also manually set), i see 100% packet lost... but on PC side i receive some packets from board (i know this because using ifconfig on PC during ping from board i see growing my packet received stats).... but running ifconfig on board instead i see all packets sent and received in loopback...

My idea (and i'm quite sure about this) is that i can't receive any packets, so the board can transmit but it can't receive anything.

What i miss? How can i test in linux if the packets are received, in which buffer (for make sure that is probably a configuration problem)?

Best Regards, Massimo Burgarella.

  • Massimo,

    Let's see if we can dissect the problem to determine if this needs to be addressed in the TLK110 or the AM3359.  That will help guide this to the right people to help solve the problem.

    It sounds like the TLK110 will link with a partner, correct?

    Are you able to read the TLK110 registers via the serial management interfac (MDC/MDIO)? 

    When packets are received from the partner by the TLK110, are you able to probe the signals to the MAC to confirm that the RX MII signals are toggling?

    Patrick

  • Hi Patrick,

    thank you for your fast reply.

    1) What do you mean by "partner"? My PC? if so, yes it links successful (with 100 Full duplex in AUTONEG or even manually).

    2) Yes, i'm able to read the TLK110 registers correctly.

    3) When i send packets from PC to the board (using "ping" in my PC), the signals MII RX_D0 D1... are toggling, but aren't toggling the signals TX_D. Whereas if i ping my PC from the board i can see toggling TX and RX (maybe that PC replies with ack).

    Any Ideas? Could be that i have to set something in linux for make cpdma works correctly?

    Best Regards, Massimo Burgarella.

  • Hi,

    i have some important news:


    looking in the registers CPDMA , i noticed that the registers CPDMA_TXINTMASKSET , CPDMA_TXINTMASKCLEAR , CPDMA_RXINTMASKSET , CPDMA_RXINTMASKCLEAR , they all have value 1 immediately after the function "cpdma_ctlr_start (...) " 

    I particularly noted that after this statement:
      
    dma_reg_write ( ctlr , chan -> int_set , chan -> mask) ;

    (found inside "cpdma_chan_start(ctlr->channels[i])", that you need to write 1 respectively CPDMA_TXINTMASKSET first, and then after another call, in CPDMA_RXINTMASKSET) shows the value 1 also in CPDMA_TXINTMASKCLEAR and CPDMA_RXINTMASKCLEAR .

    Then I tried to write " 0" manually in CPDMA_TXINTMASKCLEAR , and CPDMA_RXINTMASKCLEAR immediately after the instruction, but the result is that nothing changes ... 1 is written in all registers.

    Whereas if I write " 0xffffffff " only in CPDMA_TXINTMASKCLEAR and CPDMA_RXINTMASKCLEAR, immediately all the registers together become 0, also CPDMA_RXINTMASKSET and CPDMA_TXINTMASKSET:

    It would seem that I can not write this configuration:
    CPDMA_RXINTMASKSET and CPDMA_TXINTMASKSET --- > 1
    CPDMA_TXINTMASKCLEAR and CPDMA_TXINTMASKCLEAR --- > 0

    It 's possible that I can not receive packets for that reason? If so, why can not I write the way I want ?

    Best Regards .

  • Hi,

    i found the solution to the problem... It was a problem of Kernel configuration (or driver incompatibility?)

    If i use this configuration ->

    make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- am335x_evm_defconfig
    and then i change Kernel mode to  -> PREEMPTIVE (low latency desktop)


    and i compile, then my Ethernet doesn't work.

    What caused it? Incompatibility of driver CPSW with the KERNEL PREEMPTION MODE?

    I hope that this issue can help someone.

    Best Regards,

    Massimo Burgarella