diff options
author | Vlad Yasevich <vyasevic@redhat.com> | 2012-11-15 03:49:11 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-11-15 17:36:17 -0500 |
commit | 22061d8014455b01eb018bd6c35a1b3040ccc230 (patch) | |
tree | 179242661e78e2621c02719cea9cf6e838f9b32a /net/ipv4/af_inet.c | |
parent | 62532da9d5f47a7ced3b965aa73ffd5b1afbeb79 (diff) |
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/ipv4/af_inet.c')
-rw-r--r-- | net/ipv4/af_inet.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/net/ipv4/af_inet.c b/net/ipv4/af_inet.c index 766c59658563..4c99c5fdba3f 100644 --- a/net/ipv4/af_inet.c +++ b/net/ipv4/af_inet.c | |||
@@ -1662,6 +1662,10 @@ static int ipv4_proc_init(void); | |||
1662 | static struct packet_type ip_packet_type __read_mostly = { | 1662 | static struct packet_type ip_packet_type __read_mostly = { |
1663 | .type = cpu_to_be16(ETH_P_IP), | 1663 | .type = cpu_to_be16(ETH_P_IP), |
1664 | .func = ip_rcv, | 1664 | .func = ip_rcv, |
1665 | }; | ||
1666 | |||
1667 | static struct packet_offload ip_packet_offload __read_mostly = { | ||
1668 | .type = cpu_to_be16(ETH_P_IP), | ||
1665 | .gso_send_check = inet_gso_send_check, | 1669 | .gso_send_check = inet_gso_send_check, |
1666 | .gso_segment = inet_gso_segment, | 1670 | .gso_segment = inet_gso_segment, |
1667 | .gro_receive = inet_gro_receive, | 1671 | .gro_receive = inet_gro_receive, |
@@ -1781,6 +1785,7 @@ static int __init inet_init(void) | |||
1781 | 1785 | ||
1782 | ipfrag_init(); | 1786 | ipfrag_init(); |
1783 | 1787 | ||
1788 | dev_add_offload(&ip_packet_offload); | ||
1784 | dev_add_pack(&ip_packet_type); | 1789 | dev_add_pack(&ip_packet_type); |
1785 | 1790 | ||
1786 | rc = 0; | 1791 | rc = 0; |