summaryrefslogtreecommitdiff
path: root/sys/dev
diff options
context:
space:
mode:
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/pci/if_tht.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/sys/dev/pci/if_tht.c b/sys/dev/pci/if_tht.c
index ae84701df2e..a4c3d551b21 100644
--- a/sys/dev/pci/if_tht.c
+++ b/sys/dev/pci/if_tht.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_tht.c,v 1.93 2007/05/04 22:39:55 dlg Exp $ */
+/* $OpenBSD: if_tht.c,v 1.94 2007/05/04 22:54:42 dlg Exp $ */
/*
* Copyright (c) 2007 David Gwynne <dlg@openbsd.org>
@@ -1282,6 +1282,13 @@ tht_rxd(struct tht_softc *sc)
m->m_pkthdr.rcvif = ifp;
m->m_pkthdr.len = m->m_len = letoh16(rxd.len);
+ if (!ISSET(flags, THT_RXD_FLAGS_IPCS))
+ m->m_pkthdr.csum_flags |= M_IPV4_CSUM_IN_OK;
+ if (!ISSET(flags, THT_RXD_FLAGS_TCPCS))
+ m->m_pkthdr.csum_flags |= M_TCP_CSUM_IN_OK;
+ if (!ISSET(flags, THT_RXD_FLAGS_UDPCS))
+ m->m_pkthdr.csum_flags |= M_UDP_CSUM_IN_OK;
+
/* XXX process type 3 rx descriptors */
#if NBPFILTER > 0