GR740-UM-DS, Nov 2017, Version 1.7
208
www.cobham.com/gaisler
GR740
that the receiver interrupt bit in the control register is also set). The interrupt will be generated regard-
less of whether the packet was received successfully or not.
The enable bit is set to indicate that the descriptor is valid which means it can be used by the to store a
packet. After it is set the descriptor should not be touched until the EN bit has been cleared by the
GRETH_GBIT.
The rest of the fields in the descriptor are explained later in this section.
14.4.2 Starting reception
Enabling a descriptor is not enough to start reception. A pointer to the memory area holding the
descriptors must first be set in the GRETH_GBIT. This is done in the receiver descriptor pointer reg-
ister. The address must be aligned to a 1 kB boundary. Bits 31 to 10 hold the base address of descrip-
tor area while bits 9 to 3 form a pointer to an individual descriptor. The first descriptor should be
located at the base address and when it has been used by the GRETH_GBIT the pointer field is incre-
mented by 8 to point at the next descriptor. The pointer will automatically wrap back to zero when the
Table 227.
Address offset 0x0 - GRETH_GBIT receive descriptor word 0
31
27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10
0
RESERVED
MC IF TR TD UR UD IR ID LE OE CE FT AE IE WR EN
LENGTH
31: 27
RESERVED
26
Multicast address (MC) - The destination address of the packet was a multicast address (not broad-
cast).
25
IP fragment (IF) - Fragmented IP packet detected.
24
TCP error (TR) - TCP checksum error detected.
23
TCP detected (TD) - TCP packet detected.
22
UDP error (UR) - UDP checksum error detected.
21
UDP detected (UD) - UDP packet detected.
20
IP error (IR) - IP checksum error detected.
19
IP detected (ID) - IP packet detected.
18
Length error (LE) - The length/type field of the packet did not match the actual number of received
bytes.
17
Overrun error (OE) - The frame was incorrectly received due to a FIFO overrun.
16
CRC error (CE) - A CRC error was detected in this frame.
15
Frame too long (FT) - A frame larger than the maximum size was received. The excessive part
was truncated.
14
Alignment error (AE) - An odd number of nibbles were received.
13
Interrupt Enable (IE) - Enable Interrupts. An interrupt will be generated when a packet has been
received to this descriptor provided that the receiver interrupt enable bit in the control register is set.
The interrupt is generated regardless if the packet was received successfully or if it terminated with
an error.
12
Wrap (WR) - Set to one to make the descriptor pointer wrap to zero after this descriptor has been
used. If this bit is not set the pointer will increment by 8. The pointer automatically wraps to zero
when the 1 kB boundary of the descriptor table is reached.
11
Enable (EN) - Set to one to enable the descriptor. Should always be set last of all the descriptor
fields.
10: 0
LENGTH - The number of bytes received to this descriptor.
Table 228.
Address offset 0x4 - GRETH_GBIT receive descriptor word 1
31
0
ADDRESS
31: 0
Address (ADDRESS) - Pointer to the buffer area from where the packet data will be loaded.