summaryrefslogtreecommitdiffstats
path: root/net/ipv6/af_inet6.c
diff options
context:
space:
mode:
authorVlad Yasevich <vyasevic@redhat.com>2012-11-15 08:49:11 +0000
committerDavid S. Miller <davem@davemloft.net>2012-11-15 17:36:17 -0500
commit22061d8014455b01eb018bd6c35a1b3040ccc230 (patch)
tree179242661e78e2621c02719cea9cf6e838f9b32a /net/ipv6/af_inet6.c
parent62532da9d5f47a7ced3b965aa73ffd5b1afbeb79 (diff)
downloadblackbird-op-linux-22061d8014455b01eb018bd6c35a1b3040ccc230.tar.gz
blackbird-op-linux-22061d8014455b01eb018bd6c35a1b3040ccc230.zip
net: Switch to using the new packet offload infrustructure
Convert to using the new GSO/GRO registration mechanism and new packet offload structure. Signed-off-by: Vlad Yasevich <vyasevic@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/af_inet6.c')
-rw-r--r--net/ipv6/af_inet6.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/net/ipv6/af_inet6.c b/net/ipv6/af_inet6.c
index a974247a9ae4..6e245177608c 100644
--- a/net/ipv6/af_inet6.c
+++ b/net/ipv6/af_inet6.c
@@ -938,6 +938,10 @@ out_unlock:
static struct packet_type ipv6_packet_type __read_mostly = {
.type = cpu_to_be16(ETH_P_IPV6),
.func = ipv6_rcv,
+};
+
+static struct packet_offload ipv6_packet_offload __read_mostly = {
+ .type = cpu_to_be16(ETH_P_IPV6),
.gso_send_check = ipv6_gso_send_check,
.gso_segment = ipv6_gso_segment,
.gro_receive = ipv6_gro_receive,
@@ -946,6 +950,7 @@ static struct packet_type ipv6_packet_type __read_mostly = {
static int __init ipv6_packet_init(void)
{
+ dev_add_offload(&ipv6_packet_offload);
dev_add_pack(&ipv6_packet_type);
return 0;
}
@@ -953,6 +958,7 @@ static int __init ipv6_packet_init(void)
static void ipv6_packet_cleanup(void)
{
dev_remove_pack(&ipv6_packet_type);
+ dev_remove_offload(&ipv6_packet_offload);
}
static int __net_init ipv6_init_mibs(struct net *net)
OpenPOWER on IntegriCloud