Intel 82558 Switch User Manual


 
150 10/100 Mbps Ethernet Controller Family Open Source Software Developer Manual
Wake-up Functionality
A.7.2 CRC Word calculation of a Flexible Filter
A.7.3 Port Dump Wake Up Packet
The 82559 Port commands are summarized in Table 67, which also includes the new Dump Wake-
up Packet command:
Following the Dump Wake-up command, the 82559 writes the stored data of the wake-up packet to
the host memory, starting at the address specified in the pointer field. The dump data structure is
shown below.
COEFFICIENTS = 0x04C11DB7;
Signature = 0;
for(n=i=0; n<128 & n<FrameLength; ++n)
{
if(Byte n of the Frame is in the
Flexible Filter)
{
ShiftBy = (i modulo 3) * 8;
if(Signature AND 0x80000000)
{
Signature = (Signature << 1)
XOR
(FrameByte << ShiftBy)
XOR
COEFFICIENTS;
}
else
{
Signature = (Signature << 1) XOR
(FrameByte << ShiftBy);
}
++i;
}
}
output bits 0-23 of Signature
// CRC Polynomial Coefficients
// Initialize the CRC Signature
// Search the frame, using only bytes
that are part of the flexible filter
pattern mask.
// Shift factor to move the frame byte to
bit position 0, 8 or 16 of the 32-bit
Dword.
// Bit position at 24 of the Dword is not
used, because the signature is only 24
bits.
// If the most significant bit is 1, XOR
in the coefficients, previous signature
and frame byte shifted over to the
proper position.
// Otherwise, just XOR the previous
signature and frame byte shifted over to
the proper position.
// Include the Dword slot for the next
frame byte that is in the pattern mask.
Table 67. 82559 Port Commands
Function
Pointer Field
31 4
Opcode Field
3 0
Software Reset Don't care 0000
Self Test Self test results pointer (16-byte alignment) 0001
Selective Reset Don't care 0010
Dump Dump area pointer (16-byte alignment) 0011
Dump Wake-up Dump area pointer (16-byte alignment) 0111