Re: [PATCH linux-wpan 3/3] ieee802154: 6lowpan: Drop PACKET_OTHERHOST skbs in 6lowpan

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Oct 02, 2014 at 09:56:46AM +0100, Simon Vincent wrote:
> There is no point processing pkts which are PACKET_OTHERHOST
> in 6lowpan as they are discarded as soon as they reach the
> ipv6 layer. Therefore we should drop them in the 6lowpan layer.
> 
> Signed-off-by: Simon Vincent <simon.vincent@xxxxxxxxxx>
> ---
>  net/ieee802154/6lowpan_rtnl.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/net/ieee802154/6lowpan_rtnl.c b/net/ieee802154/6lowpan_rtnl.c
> index e246edc..820922a 100644
> --- a/net/ieee802154/6lowpan_rtnl.c
> +++ b/net/ieee802154/6lowpan_rtnl.c
> @@ -515,6 +515,9 @@ static int lowpan_rcv(struct sk_buff *skb, struct net_device *dev,
>  	if (!netif_running(dev))
>  		goto drop_skb;
>  
> +	if (skb->pkt_type == PACKET_OTHERHOST)
> +		goto drop_skb;
> +
>  	if (dev->type != ARPHRD_IEEE802154)
>  		goto drop_skb;
>  

This one should also added in bluetooth, but I don't know where. Maybe
Jukka will take care of this.

- Alex
--
To unsubscribe from this list: send the line "unsubscribe linux-wpan" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux