summaryrefslogtreecommitdiffstats
path: root/net/ipv6/icmp.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2019-02-08 08:20:32 -0500
committerTakashi Iwai <tiwai@suse.de>2019-02-08 08:20:32 -0500
commitd02cac152c97dffcb0cdd91e09b54fd6e2cca63d (patch)
tree68e4c6bd842703009f3edbf8f0e0e9326e4b2fad /net/ipv6/icmp.c
parent36e4617c01153757cde9e5fcd375a75a8f8425c3 (diff)
parenta50e32694fbcdbf55875095258b9398e2eabd71f (diff)
Merge tag 'asoc-v5.1' of https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-next
ASoC: Updates for v5.1 Lots and lots of new drivers so far, a highlight being the MediaTek BTCVSD which is a driver for a Bluetooth radio chip - the first such driver we've had upstream. Hopefully we will soon also see a baseband with an upstream driver! - Support for only powering up channels that are actively being used. - Quite a few improvements to simplify the generic card drivers, especially the merge of the SCU cards into the main generic drivers. - Lots of fixes for probing on Intel systems, trying to rationalize things to look more standard from a framework point of view. - New drivers for Asahi Kasei Microdevices AK4497, Cirrus Logic CS4341, Google ChromeOS embedded controllers, Ingenic JZ4725B, MediaTek BTCVSD, MT8183 and MT6358, NXP MICFIL, Rockchip RK3328, Spreadtrum DMA controllers, Qualcomm WCD9335, Xilinx S/PDIF and PCM formatters.
Diffstat (limited to 'net/ipv6/icmp.c')
-rw-r--r--net/ipv6/icmp.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/net/ipv6/icmp.c b/net/ipv6/icmp.c
index 5d7aa2c2770c..bbcdfd299692 100644
--- a/net/ipv6/icmp.c
+++ b/net/ipv6/icmp.c
@@ -423,10 +423,10 @@ static int icmp6_iif(const struct sk_buff *skb)
423static void icmp6_send(struct sk_buff *skb, u8 type, u8 code, __u32 info, 423static void icmp6_send(struct sk_buff *skb, u8 type, u8 code, __u32 info,
424 const struct in6_addr *force_saddr) 424 const struct in6_addr *force_saddr)
425{ 425{
426 struct net *net = dev_net(skb->dev);
427 struct inet6_dev *idev = NULL; 426 struct inet6_dev *idev = NULL;
428 struct ipv6hdr *hdr = ipv6_hdr(skb); 427 struct ipv6hdr *hdr = ipv6_hdr(skb);
429 struct sock *sk; 428 struct sock *sk;
429 struct net *net;
430 struct ipv6_pinfo *np; 430 struct ipv6_pinfo *np;
431 const struct in6_addr *saddr = NULL; 431 const struct in6_addr *saddr = NULL;
432 struct dst_entry *dst; 432 struct dst_entry *dst;
@@ -437,12 +437,16 @@ static void icmp6_send(struct sk_buff *skb, u8 type, u8 code, __u32 info,
437 int iif = 0; 437 int iif = 0;
438 int addr_type = 0; 438 int addr_type = 0;
439 int len; 439 int len;
440 u32 mark = IP6_REPLY_MARK(net, skb->mark); 440 u32 mark;
441 441
442 if ((u8 *)hdr < skb->head || 442 if ((u8 *)hdr < skb->head ||
443 (skb_network_header(skb) + sizeof(*hdr)) > skb_tail_pointer(skb)) 443 (skb_network_header(skb) + sizeof(*hdr)) > skb_tail_pointer(skb))
444 return; 444 return;
445 445
446 if (!skb->dev)
447 return;
448 net = dev_net(skb->dev);
449 mark = IP6_REPLY_MARK(net, skb->mark);
446 /* 450 /*
447 * Make sure we respect the rules 451 * Make sure we respect the rules
448 * i.e. RFC 1885 2.4(e) 452 * i.e. RFC 1885 2.4(e)