Turn TCP and UDP hardware RX checksumming back on. jlemon pointed out where

I'd gone wrong before: we have to set csum_data to 0xffff, not 0.
This commit is contained in:
Bill Paul 2001-06-15 19:02:55 +00:00
parent 1bacd83aea
commit c921560563
2 changed files with 3 additions and 6 deletions

View File

@ -1023,16 +1023,15 @@ static void lge_rxeof(sc, cnt)
m->m_pkthdr.csum_flags |= CSUM_IP_CHECKED;
if (!(rxsts & LGE_RXSTS_IPCSUMERR))
m->m_pkthdr.csum_flags |= CSUM_IP_VALID;
#ifdef notyet
if ((rxsts & LGE_RXSTS_ISTCP &&
!(rxsts & LGE_RXSTS_TCPCSUMERR)) ||
(rxsts & LGE_RXSTS_ISUDP &&
!(rxsts & LGE_RXSTS_UDPCSUMERR))) {
m->m_pkthdr.csum_flags |=
CSUM_DATA_VALID|CSUM_PSEUDO_HDR;
m->m_pkthdr.csum_data = 0;
m->m_pkthdr.csum_data = 0xffff;
}
#endif
ether_input(ifp, eh, m);
}

View File

@ -1293,16 +1293,14 @@ static void nge_rxeof(sc)
m->m_pkthdr.csum_flags |= CSUM_IP_CHECKED;
if (!(extsts & NGE_RXEXTSTS_IPCSUMERR))
m->m_pkthdr.csum_flags |= CSUM_IP_VALID;
#ifdef notdef
if ((extsts & NGE_RXEXTSTS_TCPPKT &&
!(extsts & NGE_RXEXTSTS_TCPCSUMERR)) ||
(extsts & NGE_RXEXTSTS_UDPPKT &&
!(extsts & NGE_RXEXTSTS_UDPCSUMERR))) {
m->m_pkthdr.csum_flags |=
CSUM_DATA_VALID|CSUM_PSEUDO_HDR;
m->m_pkthdr.csum_data = 0;
m->m_pkthdr.csum_data = 0xffff;
}
#endif
}
#if NVLAN > 0