diff options
author | Nazarov Sergey <s-nazarov@yandex.ru> | 2019-02-25 19:24:15 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-03-13 14:04:53 -0700 |
commit | 55ea53a854c0c580c4cd1fffe1984987e04eb045 (patch) | |
tree | 8f4d7df48f5c4a070ea3327fd3c677d600e05d2b /include | |
parent | 07745894ea6f8242ef4fe32aa836ee77222e7688 (diff) | |
download | linux-stable-55ea53a854c0c580c4cd1fffe1984987e04eb045.tar.gz linux-stable-55ea53a854c0c580c4cd1fffe1984987e04eb045.tar.bz2 linux-stable-55ea53a854c0c580c4cd1fffe1984987e04eb045.zip |
net: Add __icmp_send helper.
[ Upstream commit 9ef6b42ad6fd7929dd1b6092cb02014e382c6a91 ]
Add __icmp_send function having ip_options struct parameter
Signed-off-by: Sergey Nazarov <s-nazarov@yandex.ru>
Reviewed-by: Paul Moore <paul@paul-moore.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/net/icmp.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/include/net/icmp.h b/include/net/icmp.h index 3ef2743a8eec..8665bf24e3b7 100644 --- a/include/net/icmp.h +++ b/include/net/icmp.h @@ -22,6 +22,7 @@ #include <net/inet_sock.h> #include <net/snmp.h> +#include <net/ip.h> struct icmp_err { int errno; @@ -39,7 +40,13 @@ struct net_proto_family; struct sk_buff; struct net; -void icmp_send(struct sk_buff *skb_in, int type, int code, __be32 info); +void __icmp_send(struct sk_buff *skb_in, int type, int code, __be32 info, + const struct ip_options *opt); +static inline void icmp_send(struct sk_buff *skb_in, int type, int code, __be32 info) +{ + __icmp_send(skb_in, type, code, info, &IPCB(skb_in)->opt); +} + int icmp_rcv(struct sk_buff *skb); void icmp_err(struct sk_buff *skb, u32 info); int icmp_init(void); |