From a320181f55ab85deefd0070d04ab9dfa04b4b339 Mon Sep 17 00:00:00 2001 From: Leandro Lanzieri Date: Mon, 6 Jul 2020 14:21:58 +0200 Subject: [PATCH] drivers/kw2xrf: Enable TX End IRQ in netdev init The driver needs this event but gnrc_netif_ieee802154 only enables the interrupt when MODULE_NETSTATS_L2 is active. --- drivers/kw2xrf/kw2xrf_netdev.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/kw2xrf/kw2xrf_netdev.c b/drivers/kw2xrf/kw2xrf_netdev.c index a65aa65565..24bb36774b 100644 --- a/drivers/kw2xrf/kw2xrf_netdev.c +++ b/drivers/kw2xrf/kw2xrf_netdev.c @@ -82,6 +82,10 @@ static int _init(netdev_t *netdev) /* reset device to default values and put it into RX state */ kw2xrf_reset_phy(dev); + /* enable TX End IRQ: the driver uses the event and gnrc_netif_ieee802154 + * only enables this when MODULE_NETSTATS_L2 is active */ + kw2xrf_clear_dreg_bit(dev, MKW2XDM_PHY_CTRL2, MKW2XDM_PHY_CTRL2_TXMSK); + return 0; }