Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 29 Mar 2021 09:16:05 GMT
From:      Wei Hu <whu@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: 2a321939b02b - stable/12 - Hyper-V: hn: Initialize the internal field of per packet info on tx path
Message-ID:  <202103290916.12T9G54c053402@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch stable/12 has been updated by whu:

URL: https://cgit.FreeBSD.org/src/commit/?id=2a321939b02bbf6123ba029f1967778c10538fe6

commit 2a321939b02bbf6123ba029f1967778c10538fe6
Author:     Wei Hu <whu@FreeBSD.org>
AuthorDate: 2021-03-15 10:20:52 +0000
Commit:     Wei Hu <whu@FreeBSD.org>
CommitDate: 2021-03-29 09:12:56 +0000

    Hyper-V: hn: Initialize the internal field of per packet info on tx path
    
    The RSC support feature introduced a bit field "rm_internal" in
    struct rndis_pktinfo with total size unchanged.
    
    The guest does not use this field in the tx path. However we need to
    initialize it to zero in case older hosts which are not aware of this
    field.
    
    Fixes:          a491581f ("Hyper-V: hn: Enable vSwitch RSC support")
    MFC after:      2 weeks
    Sponsored by:   Microsoft
    
    (cherry picked from commit 805dbff6c36a6cd84491aa53a02315fa025734cc)
---
 sys/dev/hyperv/netvsc/if_hn.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sys/dev/hyperv/netvsc/if_hn.c b/sys/dev/hyperv/netvsc/if_hn.c
index 1e90e8ef14fb..54d2e41c36c8 100644
--- a/sys/dev/hyperv/netvsc/if_hn.c
+++ b/sys/dev/hyperv/netvsc/if_hn.c
@@ -2928,6 +2928,7 @@ hn_rndis_pktinfo_append(struct rndis_packet_msg *pkt, size_t pktsize,
 
 	pi->rm_size = pi_size;
 	pi->rm_type = pi_type;
+	pi->rm_internal = 0;
 	pi->rm_pktinfooffset = RNDIS_PKTINFO_OFFSET;
 
 	return (pi->rm_data);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202103290916.12T9G54c053402>