On 02/18/2016 09:34 PM, Vincenzo Maffione wrote: >>> static void netmap_set_offload(NetClientState *nc, int csum, int tso4, int >>> tso6, >>> >> @@ -376,7 +394,7 @@ static void netmap_set_offload(NetClientState *nc, >>> >> int csum, int tso4, int tso6, >>> >> * enables the offloadings. >>> >> */ >>> >> if (!s->vnet_hdr_len) { >>> >> - netmap_set_vnet_hdr_len(nc, sizeof(struct virtio_net_hdr)); >>> >> + netmap_do_set_vnet_hdr_len(s, sizeof(struct virtio_net_hdr), >>> >> true); >>> >> } >>> >> } >>> >> >>> >> @@ -388,7 +406,7 @@ static NetClientInfo net_netmap_info = { >>> >> .receive_iov = netmap_receive_iov, >>> >> .poll = netmap_poll, >>> >> .cleanup = netmap_cleanup, >>> >> - .has_ufo = netmap_has_ufo, >>> >> + .has_ufo = netmap_has_vnet_hdr, >> > >> > This look suspicious, I'm not sure this is correct for netmap. May need >> > a comment to explain. Usually vnet hdr does not imply ufo. >> > >>> >> .has_vnet_hdr = netmap_has_vnet_hdr, >>> >> .has_vnet_hdr_len = netmap_has_vnet_hdr_len, >>> >> .using_vnet_hdr = netmap_using_vnet_hdr, >> > > Yes, I know it sounds weird in general, but a netmap port using > virtio-net headers always provides TCPv4, TCPv6, UDP and ECN > offloadings (done in software inside netmap). > > This patch already provides a little comment about UFO support on the > netmap_has_vnet_hdr() function.
Just saw that. > Do you want me to move it here, or is > the comment not understandable enough? > > Thanks for your review, > Vincenzo Nope, it's ok. Thanks