Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
14 years ago

TSE MAC catatonic

I've got a real head-scratcher of a problem with the Altera TSE MAC core. Here's the outline:

* Altera/Terasic DE2-115 board, Cyclone IV-E FPGA

* Full Quartus subscription, but no TSE license (using OpenCore+ for TSE)

* TSE instantiated in SOPC builder, two mSGDMAs instantiated for RX/TX DMA.

* TSE is configured in 10/100 small mode, MII.

* PHY is an 88E1111 strapped to MII mode (the DE2-115 has 2 of these and each one has an MII/RGMII strap jumper).

* System is running full-blown vanilla Linux. Wrote a custom driver from scratch for the TSE/DMAs (replacing altera_tse.c and atse.c, which are absolutely terrible).

So here's the problem: The TSE is initialized and the link is brought up. PHY MDIO stuff works 100% perfectly and it is able to autonegotiate the correct mode.

Packets are coming in on the PHY'x RX interface, I can see them on SignalTap, and the packets look good as well (0x55 55 ... 5D header plus correct packet contents). However, the TSE MAC appears to completely ignore them, no data ever appears on the Avalon-ST receive source. All MAC-sourced Avalon-ST signals on the receive side just idle low. The MAC is in promiscuous mode for now, so all receive filtering should be disabled.

When the OS attempts to send packets, the TX DMA kicks in and does its thing, a very correct-looking packet goes out to the TSE's Avalon-ST transmit sink... and it completely ignores that too. No data appears on the MII TX signals, they are constantly low. The Avalon-ST valid/sop/eop signals all appear to be operating correctly as well.

I am using Quartus 9.1sp2 on Linux, but I tried regenerating/resynthesizing the entire system with Quartus 11.0 as well since there is quite the errata list for the TSE. The entire system's behavior was identical. I have also tried using the TSE in 10/100/1000 mode with RGMII and the behavior was identical (actually, I was trying this first until the RGMII DDR timing constraint nightmare set in).

So, the question is: Under what circumstances would the TSE MAC not allow packet RX/TX data to pass? As far as I can tell the MAC has been reset and initialized properly, readback of the Command_Config register gives 0x01000053 (RX_ENA and TX_ENA set among others). What could possibly be wrong?!

11 Replies