Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F156650378
D9712.id25831.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
972 B
Referenced Files
None
Subscribers
None
D9712.id25831.diff
View Options
Index: head/sys/dev/hyperv/netvsc/if_hn.c
===================================================================
--- head/sys/dev/hyperv/netvsc/if_hn.c
+++ head/sys/dev/hyperv/netvsc/if_hn.c
@@ -1784,9 +1784,6 @@
pi->rm_type = pi_type;
pi->rm_pktinfooffset = RNDIS_PKTINFO_OFFSET;
- /* Update RNDIS packet msg length */
- pkt->rm_len += pi_size;
-
return (pi->rm_data);
}
@@ -1928,7 +1925,7 @@
}
pkt->rm_type = REMOTE_NDIS_PACKET_MSG;
- pkt->rm_len = sizeof(*pkt) + m_head->m_pkthdr.len;
+ pkt->rm_len = m_head->m_pkthdr.len;
pkt->rm_dataoffset = 0;
pkt->rm_datalen = m_head->m_pkthdr.len;
pkt->rm_oobdataoffset = 0;
@@ -1999,6 +1996,8 @@
}
pkt_hlen = pkt->rm_pktinfooffset + pkt->rm_pktinfolen;
+ /* Fixup RNDIS packet message total length */
+ pkt->rm_len += pkt_hlen;
/* Convert RNDIS packet message offsets */
pkt->rm_dataoffset = hn_rndis_pktmsg_offset(pkt_hlen);
pkt->rm_pktinfooffset = hn_rndis_pktmsg_offset(pkt->rm_pktinfooffset);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, May 16, 9:54 AM (6 h, 12 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
33101051
Default Alt Text
D9712.id25831.diff (972 B)
Attached To
Mode
D9712: hyperv/hn: Simplify RNDIS packet total length calculation.
Attached
Detach File
Event Timeline
Log In to Comment