From 7c0accb4f11b99f6d79971fe35356cf8eaad4a26 Mon Sep 17 00:00:00 2001 From: Geovane Fedrecheski Date: Fri, 25 Aug 2023 16:20:27 +0200 Subject: [PATCH] netdev/ieee802154_submac: support setting promiscuous mode option --- drivers/netdev_ieee802154_submac/netdev_ieee802154_submac.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/netdev_ieee802154_submac/netdev_ieee802154_submac.c b/drivers/netdev_ieee802154_submac/netdev_ieee802154_submac.c index 1e6bf71d78..2e675f1080 100644 --- a/drivers/netdev_ieee802154_submac/netdev_ieee802154_submac.c +++ b/drivers/netdev_ieee802154_submac/netdev_ieee802154_submac.c @@ -115,6 +115,10 @@ static int _set(netdev_t *netdev, netopt_t opt, const void *value, return res; case NETOPT_STATE: return _set_submac_state(submac, *((netopt_state_t*) value)); + case NETOPT_PROMISCUOUSMODE: + return ieee802154_radio_set_frame_filter_mode(&submac->dev, + *((bool *)value) ? IEEE802154_FILTER_PROMISC + : IEEE802154_FILTER_ACCEPT); default: break; }