Commit 966be9e7 authored by Alexander Aring's avatar Alexander Aring Committed by Marcel Holtmann

6lowpan: ndisc: add missing 802.15.4 only check

This patch adds a missing check to handle short address parsing for
802.15.4 6LoWPAN only.
Signed-off-by: default avatarAlexander Aring <aar@pengutronix.de>
Reviewed-by: default avatarStefan Schmidt <stefan@osg.samsung.com>
Signed-off-by: default avatarMarcel Holtmann <marcel@holtmann.org>
parent 929946a4
...@@ -47,6 +47,9 @@ static int lowpan_ndisc_parse_options(const struct net_device *dev, ...@@ -47,6 +47,9 @@ static int lowpan_ndisc_parse_options(const struct net_device *dev,
struct nd_opt_hdr *nd_opt, struct nd_opt_hdr *nd_opt,
struct ndisc_options *ndopts) struct ndisc_options *ndopts)
{ {
if (!lowpan_is_ll(dev, LOWPAN_LLTYPE_IEEE802154))
return 0;
switch (nd_opt->nd_opt_type) { switch (nd_opt->nd_opt_type) {
case ND_OPT_SOURCE_LL_ADDR: case ND_OPT_SOURCE_LL_ADDR:
case ND_OPT_TARGET_LL_ADDR: case ND_OPT_TARGET_LL_ADDR:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment