Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F106156168
D29378.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D29378.diff
View Options
diff --git a/sys/netpfil/pf/pf.c b/sys/netpfil/pf/pf.c
--- a/sys/netpfil/pf/pf.c
+++ b/sys/netpfil/pf/pf.c
@@ -5571,11 +5571,17 @@
/* Copied from FreeBSD 10.0-CURRENT ip_output. */
m0->m_pkthdr.csum_flags |= CSUM_IP;
if (m0->m_pkthdr.csum_flags & CSUM_DELAY_DATA & ~ifp->if_hwassist) {
+ m0 = mb_unmapped_to_ext(m0);
+ if (m0 == NULL)
+ goto done;
in_delayed_cksum(m0);
m0->m_pkthdr.csum_flags &= ~CSUM_DELAY_DATA;
}
#if defined(SCTP) || defined(SCTP_SUPPORT)
if (m0->m_pkthdr.csum_flags & CSUM_SCTP & ~ifp->if_hwassist) {
+ m0 = mb_unmapped_to_ext(m0);
+ if (m0 == NULL)
+ goto done;
sctp_delayed_cksum(m0, (uint32_t)(ip->ip_hl << 2));
m0->m_pkthdr.csum_flags &= ~CSUM_SCTP;
}
@@ -5752,6 +5758,9 @@
if (m0->m_pkthdr.csum_flags & CSUM_DELAY_DATA_IPV6 &
~ifp->if_hwassist) {
uint32_t plen = m0->m_pkthdr.len - sizeof(*ip6);
+ m0 = mb_unmapped_to_ext(m0);
+ if (m0 == NULL)
+ goto done;
in6_delayed_cksum(m0, plen, sizeof(struct ip6_hdr));
m0->m_pkthdr.csum_flags &= ~CSUM_DELAY_DATA_IPV6;
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Dec 27, 7:50 AM (10 h, 43 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
15612326
Default Alt Text
D29378.diff (1 KB)
Attached To
Mode
D29378: pf: Handle unmapped mbufs when computing checksums
Attached
Detach File
Event Timeline
Log In to Comment