diff options
author | Paul Durrant <Paul.Durrant@citrix.com> | 2013-10-16 12:50:29 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-10-17 15:35:16 -0400 |
commit | 2eba61d55e5104d0bf08ba4a9cc609613f52b4c9 (patch) | |
tree | 0eb2237b5c36d8ff1bc40d8867150463f7e9b2e9 /drivers/net/xen-netback/xenbus.c | |
parent | 146c8a77d27bcbd7722120f70f51e3b287205d0a (diff) |
xen-netback: add support for IPv6 checksum offload from guest
For performance of VM to VM traffic on a single host it is better to avoid
calculation of TCP/UDP checksum in the sending frontend. To allow this this
patch adds the code necessary to set up partial checksum for IPv6 packets
and xenstore flag feature-ipv6-csum-offload to advertise that fact to
frontends.
Signed-off-by: Paul Durrant <paul.durrant@citrix.com>
Cc: Wei Liu <wei.liu2@citrix.com>
Cc: David Vrabel <david.vrabel@citrix.com>
Cc: Ian Campbell <ian.campbell@citrix.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/xen-netback/xenbus.c')
-rw-r--r-- | drivers/net/xen-netback/xenbus.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/net/xen-netback/xenbus.c b/drivers/net/xen-netback/xenbus.c index ad27b15242cd..108e7523017a 100644 --- a/drivers/net/xen-netback/xenbus.c +++ b/drivers/net/xen-netback/xenbus.c | |||
@@ -105,6 +105,15 @@ static int netback_probe(struct xenbus_device *dev, | |||
105 | goto abort_transaction; | 105 | goto abort_transaction; |
106 | } | 106 | } |
107 | 107 | ||
108 | /* We support partial checksum setup for IPv6 packets */ | ||
109 | err = xenbus_printf(xbt, dev->nodename, | ||
110 | "feature-ipv6-csum-offload", | ||
111 | "%d", 1); | ||
112 | if (err) { | ||
113 | message = "writing feature-ipv6-csum-offload"; | ||
114 | goto abort_transaction; | ||
115 | } | ||
116 | |||
108 | /* We support rx-copy path. */ | 117 | /* We support rx-copy path. */ |
109 | err = xenbus_printf(xbt, dev->nodename, | 118 | err = xenbus_printf(xbt, dev->nodename, |
110 | "feature-rx-copy", "%d", 1); | 119 | "feature-rx-copy", "%d", 1); |