VirtualBox

Changeset 28202 in vbox


Ignore:
Timestamp:
Apr 12, 2010 12:52:20 PM (15 years ago)
Author:
vboxsync
Message:

VBoxNetFlt-linux.c: skb_partial_csum_set is 2.6.26+ :-/

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostDrivers/VBoxNetFlt/linux/VBoxNetFlt-linux.c

    r28161 r28202  
    533533        pShInfo->gso_segs = PDMNetGsoCalcSegmentCount(&pSG->GsoCtx, pSG->cbTotal);
    534534
    535         /** @todo figure out the checksum bit... We're checksumming way too much here
    536          *        I hope.  */
    537535        if (fDstWire)
    538536        {
    539             /** @todo check skb_partial_csum_set status code.  */
     537            Assert(skb_headlen(pPkt) >= pSG->GsoCtx.cbHdrs);
     538            pPkt->ip_summed  = CHECKSUM_PARTIAL;
     539            pPkt->csum_start = skb_headroom(pPkt) + pSG->GsoCtx.offHdr2;
    540540            if (fGsoType & (SKB_GSO_TCPV4 | SKB_GSO_TCPV6))
    541                 skb_partial_csum_set(pPkt, pSG->GsoCtx.offHdr2, RT_OFFSETOF(RTNETTCP, th_sum));
     541                pPkt->csum_offset = RT_OFFSETOF(RTNETTCP, th_sum);
    542542            else
    543                 skb_partial_csum_set(pPkt, pSG->GsoCtx.offHdr2, RT_OFFSETOF(RTNETUDP, uh_sum));
     543                pPkt->csum_offset = RT_OFFSETOF(RTNETUDP, uh_sum);
    544544        }
    545545        else
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette