No license is granted, implied or otherwise, under any patent or patent rights of VIA
Technologies. VIA Technologies makes no warranties, implied or otherwise, in regard to this
document and to the products described in this document. The information provided by this
document is believed to be accurate and reliable to the publication date of this document.
However, VIA Technologies assumes no responsibility for any errors in this document.
Furthermore, VIA Technologies assumes no responsibility for the use or misuse of the
information in this document and for any patent infringements that may arise from the use of
this document. The information and product specifications within this document are subject to
change at any time, without notice and without obligation to notify any person of such change.
VIA Technologies, Inc.Preliminary VT6516 Datasheet
TABLE OF CONTENTS
TABLE OF CONTENTS................................................................................................................................3
FIGURES AND TABLES ...............................................................................................................................4
REVERSION HISTORY ................................................................................................................................5
FEATURES ................................................................................................................................................6
Table 3-2 MII interface signals ..................................................................................31
Figure 3-2 MII timing diagram .................................................................................. 31
4
VIA Technologies, Inc.Preliminary VT6516 Datasheet
REVERSION HISTORY
ReversionDateReason for changeBy
V0.902/18/1999First release versionJeffreyChang
V0.916/2/1999Add D version silicon features
modification
V0.928/23/1999Add E version silicon features
modification
V0.939/9/1999Revision according to Weipin’s,
Kevin’s, and Ruth’ s comments
JeffreyChang
MurphyChen
MurphyChen
5
VIA Technologies, Inc.Preliminary VT6516 Datasheet
FEATURES
l Single chip 16/12 ports 10/100M Ethernet switch controller
- Highly integrated single chip shared memory switch engine
- With option for 16 RMII (Reduced Media Independent Interface) ports or 12 MII
(Media Independent Interface) ports
- Non-blocking layer 2 switch, 148,810 packets/sec on each 100Mbps Ethernet port
l Media Access Control (MAC)
- Dual 192-bytes FIFO’s of receive and transmit for each port
- CRC generator for outgoing packets from CPU port
- IEEE 802.3X compliant flow control for full duplex ports
- Backpressure for half duplex ports
l Two switching mechanisms
- Supports ‘store and forward’ switching without forwarding CRC-bad packets
- Supports ‘cut through’ switching subject to long packets of length over 290 bytes for
100Mbps ports or of length over 98 bytes for 10Mbps ports
l Packet buffering
- Glueless 64-bit interface to SDRAM as a packet buffer pool with size from 2M bytes
(SGRAM) to 512 M bytes
- 1536 bytes for each packet buffer
l External 32 bits SSRAM interface for forwarding table and memory link table
- Link list structure initialized by software
- 2K up to 32K unicast/multicast addresses table entries with VLAN information
- Supports static entries for upper-layer multicast protocols, e.g. IGMP
l Advanced address recognition
- Layer 2 MAC address recognition engine to enable wire-speed forwarding rate
- Self learning mechanism
- Supports multiple MAC address per-port from 2K up to 32K unicast/multicast
addresses
l Switch management support
- Supports port mirroring (Sniffer feature)
- Supports spanning tree algorithm
- Supports CPU direct access to SDRAM and SSRAM
- Supports five statistical counters in each port
l Supports I
l Support port-grouping VLAN
- Configurable server ports belonging to multiple VLAN groups
l Support port-based trunking
- Three types of trunk grouping: one trunk group with 2 or 4 ports, two trunk groups
each with 2 ports
- Load balance according to MAC address and port number
l CPU interface VIA 8/16 bits ISA-like interface
2
C EEPROM interface for customized configuration
6
VIA Technologies, Inc.Preliminary VT6516 Datasheet
- Chip initialization, auto-aging and spanning tree algorithm support by firmware
- Auto-sensing 10/100M media speed, duplex mode, and flow-control capability by
firmware
l 50MHz internal reference clock rate
l 50~100MHz SDRAM clock rate, typically 83MHz
l 50~100MHz SSRAM clock rate, typically 83MHz
l Single +3.3V supply, 0.3µm standard CMOS technology
l 476 ball BGA package
7
VIA Technologies, Inc.Preliminary VT6516 Datarsheet
BLOCK DIAGRAM
forwarding
control
input
control
RMAC
SRAM
control
buffer
control
output
control
queue
control
TMAC
CPU
interface
scheduler
SDRAM
control
Figure 1: Block Diagram
99/12/099
VIA Technologies, Inc.Preliminary VT6516 Datarsheet
HCLK is determined by the strapping pins in SYSLED[3:1], i.e. the jump
selection of J1[5-6, 3-4, 1-2]:
J1[OFF,OFF,OFF]=> 8MHz
J1[ OFF,OFF, ON]=> 16MHz
J1[OFF, ON, OFF]=> 25MHz
J1[OFF, ON, ON]=> 4MHz
J1[ ON,OFF,OFF] => 33MHz
I
SYSTEM RESET
O
SYSTEM Output Pins for LED:
SYSLED[8:0] are connected to pull-up IO PADs for strapping.
SYSLED[25:9] are connected to IO PADs without pull up/down.
All SYSLED[25:0] are
HOST Interface
-15-
VIA Technologies, Inc.Preliminary VT6516 Datarsheet
HCS
HCS
IOR
IOR
IOW
IOW
See Ball
Table
See Ball
Table
See Ball
Table
See Ball
Table
See Ball
Table
See Ball
Table
HA[2:0]I
HD[15:0]I/O
I
I
I
INTRQO
HOST IDE-Interface Address Bus:
3’b000: command the switch that the whole 16-bit data in the HOST data
bus HD[15:0] is valid for packet-data read/write.
3’b001: command the switch that only the 8-bit data in the HOST data bus
HD[15:0] is valid for internal registers read/write.
3’b010: command the switch to write the low byte in the HOST data bus
HD[15:0] into the low byte of the 16-bit switch address register
for internal registers reference.
3’b011: command the switch to write the low byte in the HOST data bus
HD[15:0] into the high byte of the 16-bit switch address register
for internal registers reference.
3’b1xx: bus-idle command. Keep this address bus to be 3’b111 as the
HOST has no access to VT-3061A.
HOST IDE-Interface Data Bus:
The whole 16-bit data bus is valid for packet data read/write. However,
only the 8-bit data bus is valid for internal registers read/write.
HOST Chip Select:
Active LOW.
must be asserted during the access of HOST IDE
interface.
IO READ:
High-to-Low Edge Trigger.
must be asserted from high to low to
begin the read cycle of HOST IDE interface.
IO READ:
High-to-Low Edge Trigger.
must be asserted from high to low to
begin the write cycle of HOST IDE interface.
Interrupt Request:
Connected to the HOST external interrupt pin. It is asserted as the
following four interrupt events happen:
(1) MII Management Registers read/write command done
(2) EEPROM read/write command done
(3) Receiving a packet destined to HOST
(4) Finishing transmission of a packet issued by HOST
The interrupt cause is recorded in register IRQSTS[3:0] in address 2000H.
To clear the individual interrupt, The corresponding register has to be
written:
(1) register CLR_PHY_INT in 1806H for PHY interrupt.
(2) register CLR_EE_INT in 1C04H for EEPROM interrupt.
(3) register CLR_RCV_INT in 6403H for packet-receiving interrupt.
l register CLR_SENT_INT in 6411H for packet-sent interrupt.
MII Interface
See Ball
Table
TCLK[11:0]I
Transmit Clock for Port 0-11:
TCLK is driven by the PHY device. TCLK is a continuous clock that
provides the timing reference for the transfer of the TXEN and TXD
signals to the PHY. A PHY operating at 100Mbps must provide a TCLK
frequency of 25MHz and a PHY operating at 10Mbps must provide a
TCLK frequency of 2.5MHz.
-16-
VIA Technologies, Inc.Preliminary VT6516 Datarsheet
See Ball
Table
See Ball
Table
See Ball
Table
See Ball
Table
See Ball
Table
See Ball
Table
See Ball
Table
Note: Some flat MII input pin when the VT6516 under the RMII application, please use 22 ohm resister
pull down, refer to Table XXXX
TXD<3:0>[11:0]O
TXEN[11:0]O
COL[11:0]I
CRS[11:0]I
RXD<3:0>[11
:0]
RCLK[11:0]I
RXDV[11:0]I
Transmit Data for Port 0-11:
TXD is a bundle of 4 data signals (TXD<3:0>) that shall transition to the
TCLK. For each TCLK period in which TXEN is asserted, TXD<3:0> are
accepted for transmission by the PHY. TXD<0> is the least significant bit.
While TXEN is de-asserted, TXD<3:0> shall have no effect upon the
PHY, and the value of TXD<3:0> is unspecified.
Transmit Enable for Port 0-11:
TXEN shall transition synchronous to the TCLK. TXEN indicates the
nibbles presenting on the MII for transmission. It shall be asserted
synchronously with the first nibble of the preamble and shall remain
asserted while all nibbles to be transmitted are presented to the MII.
Collision Detected for Port 0-11:
COL shall be asserted by the PHY asynchronously upon detection of a
collision on the medium, and shall remain asserted while the collision
condition persists.
Carrier Sense for Port 0-11:
CRS shall be asserted by the PHY asynchronously upon detection of a
non-idle medium or while TX_EN is asserted. CRS shall be de-asserted by
the PHY asynchronously upon detection of idle conditions on both
transmit and receive media. The PHY shall ensure that CRS remains
asserted throughout the duration of a collision condition.
I
Receive Data for Port 0-11:
RXD is a bundle of 4 data signals (RXD<3:0>) that shall transition to the
RCLK. For each RCLK period in which RXDV is asserted, RXD<3:0>
from the PHY are accepted by the switch’s MAC. RXD<0> is the least
significant bit. While RXDV is de-asserted, RXD<3:0> shall have no
effect upon the switch’s MAC, and the value of RXD<3:0> is unspecified.
Receive Clock for Port 0-11:
RCLK is sourced from the PHY. RCLK is a continuous clock that provides
the timing reference for the transfer of the RXDV and RXD signals from
the PHY. A PHY operating at 100Mbps must provide a RCLK frequency
of 25MHz and a PHY operating at 10Mbps must provide a RCLK
frequency of 2.5MHz.
Receive Data Valid for Port 0-11:
RXDV is driven by the PHY to indicate the nibbles presenting on the MII
for receiving. RXDV shall transition synchronous to the RCLK. It shall be
asserted synchronously with the first nibble of the preamble and shall
remain asserted while all nibbles to be received are presented to the MII.
-17-
VIA Technologies, Inc.Preliminary VT6516 Datarsheet
RMII interface
See Ball
Table
See Ball
Table
See Ball
Table
See Ball
Table
See Ball
Table
See Ball
Table
Power Supply & Ground
See Ball
Table
See Ball
Table
CRS_DV[15:0]ICarries sense and data valid from port 15 to port 0 :
RXD0[15:0]IReceive data zero from port 15 to port 0 :
RXD1[15:0]IReceive data one from port 15 to port 0 :
TXEN[15:0]OTransmit enable from port 15 to port 0 :
TXD0[15:0]OTransmit data zero from port 15 to port 0 :
TXD1[15:0]OTransmit data one from port 15 to port 0 :
VDD, VDDAPPositive 3.3V Supply: Supply power to Internal digital logic, Digital I/O
VSS, VSSAGNegative Supply: digital ground. Multiple bonding pads are required to
pads, and TD, TX pads. Double bonding may be required.
J1[ ON] (SYSLED[3:1]==1’b0)=> MII PHY
SRAM Type
J1 [11-12,9-10]SYSLED[6:5]SRAM Device Type Selection:
J1[OFF,OFF] (SYSLED[6:5]==2’b11)=> 64K x 32 SRAM
J1[OFF,ON] (SYSLED[6:5]==2’b10)=> 128K x 32 SRAM
J1[ON,OFF] (SYSLED[6:5]==2’b01)=> 32K x 32 SRAM
-18-
VIA Technologies, Inc.Preliminary VT6516 Datarsheet
SECTION I FUNCTIONAL DESCRIPTIONS
1. GENERAL DESCRIPTION
The VT6516 is a switch engine chip implementation of a 16 ports 10/100M Ethernet switch system for IEEE
802.3 and IEEE 802.3u network. Each of individual port can be either auto-sensing or manually selected to run
at 10Mbps or 100Mbps speed rate and under full or half duplex mode.
There are sixteen independent MACs within the VT6516 chip. The MAC controller controls the receiving,
transmitting, and deferring of each individual port, and the MAC controller also provides framing, FCS
checking, error handling, status indication and flow control function.
The VT6516 10/100M N-way switch port IC is wire-speed performance and low-cost packet switch; it can
forward up to 148,810 packets/sec on each Ethernet port. The VT6516 support 12 ports MII or 16 ports RMII
(reduce MII) interface for network interface,
The VT6516 used the simple 8/16 bits ISA-like interface to support initiation, expansion and management.
The system CPU can access various registers inside VT6516 through a simple ISA-like CPU interface. The CPU
can configure the switch by writing into the appropriate registers, or retrieve the status of the switch by reading
the corresponding registers. The CPU can also access the register of external transceiver (PHY) device through
the CPU interface.
The VT6516 supports new features including port based VLAN , 802.3X flow control, and the VT6516 also
support the sniffer function to monitor network traffic in special ports.
2. THE VIA ETHER SWITCH ARCHITECTURE
The VT6516 switch engine uses the shared memory architecture. In order to improve the packet latency,
VT6516 provides two methods for packet switching, one is cut-through, another is store-and-forwarding. A
typical packet flow for Ethernet switch is described as follows in 4.5.
2.1 Switch initialization procedures
1. Test all of the on board components except the switch chip or access VIA the switch chip, including UART,
LED, etc.
2. Switch SDRAM test --- switch chip SDRAM control hardware initialization, configuration, SDRAM size
determination (VIA embedded EEPROM in SDRAM module) and read write test.
3. Switch SRAM test --- switch chip SDRAM control hardware initialization and read write test. Note that the
SRAM size determination is VIA strapping.
4. Switch IO registers read write test.
5. Ethernet PHY registers read write test ---- the CPU read/write to PHY devices will go through PHY
control in switch chip. Although they are outside components, but we test them as part of the switch chip.
6. Determine link table size; reset free buffer list pointers of bank 0 and 1; initialize free memory block counter.
Note that permanent buffer management is controlled by allocating bit mask. They will be cleared
automatically in the hardware reset or software reset.
2.2 Packet Switching Flow
1. After the switch microprocessor activates a port during initialization, the input control of that port pre-
allocates one packet buffer from buffer pool. In the beginning, the buffer allocated will be from private buffer
pool, but subsequent buffers may come from either private or public buffer pools.
-19-
VIA Technologies, Inc.Preliminary VT6516 Datarsheet
2. When receive MAC (RMAC) receives a packet data from the network interface – either through MII or
reduced MII (RMII) – it packs the data into 16-bit word then passes it to input control. If RMAC detects any
error, it also notifies input control to stop forwarding process.
3. Input control extracts the destination MAC address from incoming data, passes it along to forwarding table
control for forwarding decision. In the mean while, it packs 16-bit words into 64-bit quad-words, and saves
it to an input FIFO before storing the packet data to SDRAM.
4. If the switch is configured to “store and forward” mode, input control queues the packet to the output queue
of the destination port after input control is informed by RMAC that this is a good packet and it stores all
packet data to SDRAM. If the switch is configured to “cut-through” mode, the input control queues the
packet to the output queue of the destination port after enough amount of packet is stored in SDRAM to
prevent output FIFO under-run.
5. After the whole packet is received and FCS is correct, input control pass the source MAC address of the
packet to forwarding table control for address learning.
6. Output control of the outbound port de-queue the packet from output queue, and fetch packet data from
SDRAM and save it into output FIFO. Then it notifies the transmit MAC (TMAC) of the new packet to
transmit.
7. TMAC grabs 16-bit at a time from output control, adds preamble and SFD to the beginning of the packet,
then send them out. Proper deferring is done if necessary to conform to 802.3 standard.
8. After the packet is successfully transmitted, TMAC notifies output control of the successful transmission.
Output control then returns the packet to buffer pool.
3. INTERFACE DESCRIPTIONS
BUFFER MEMORY (SDRAM) INTERFACE AND TABLE (SSRAM) INTERFACE
VT6516 provides a 64-bit SDRAM/SGRAM interface for packet buffering and a 32-bit synchronous SRAM
(SSRAM) interface for maintaining address table and various link lists. VT6516 uses SDRAM as packet buffers.
Each packet buffer is a 1536-byte contiguous memory block in SDRAM, and corresponds to a 12-byte link node
data structure in SSRAM. Except the first 128 link nodes, each link node can be part of an output queue, a free
buffer link list, or held in input or output control. The first 128 link nodes are divided into 16 groups, each
pre-assigned to a specific input control, and bit-mapped inside buffer control for faster allocate/free operation
and reduce SSRAM usage.
Initially, each input port control would request one packet buffer from its private buffer pool. Each time
when a packet buffer is consumed by an incoming packet, the input port control will request another packet
buffer to prepare for next packet. The common shared packet memory will be allocated only when there’s no
free permanent packet memory for that port. See Figure 3-4.
-20-
VIA Technologies, Inc.Preliminary VT6516 Datarsheet
128 entries
SRAM
12 bytes/entry
Permanent Buffer
Table
12 bytes/entry
Free List
Link Table
Address Table
Entriers
DRAM
1.5 K/Packet
...
1.5 K/Packet
128 blocks
-21-
VIA Technologies, Inc.Preliminary VT6516 Datarsheet
List 0
List 1
Link/
Frame
128/0
129/0
130/1
131/0
132/1
133/1
134/0
135/1
136/0
16MBits SDRAM
Memory Bank
2K
2K
2K
2K
2K
2K
2K
Bank 0
Bank 1
List 0
List 1
Links/
List
128/0
129/0
130/0
131/1
132/1
133/1
134/0
135/0
136/1
137/1
Memory Bank
4K
4K
4K
4K
64MBits SDRAM
Bank 0
Bank 1
Figure 3-3
Following as the listing and figure 3-6 is the algorithm of initialization procedures for 2 bank free list of