mac802154: rx: add rx stats incrementation
authorAlexander Aring <alex.aring@gmail.com>
Wed, 29 Oct 2014 20:34:40 +0000 (21:34 +0100)
committerMarcel Holtmann <marcel@holtmann.org>
Wed, 29 Oct 2014 22:07:46 +0000 (23:07 +0100)
This patch adds rx stats incrementation when the monitor interface
recevied a frame.

Signed-off-by: Alexander Aring <alex.aring@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
net/mac802154/rx.c

index 7669cdb..6ba2769 100644 (file)
@@ -241,6 +241,9 @@ ieee802154_monitors_rx(struct ieee802154_local *local, struct sk_buff *skb)
                skb2->dev = sdata->dev;
 
                ieee802154_deliver_skb(skb2);
+
+               sdata->dev->stats.rx_packets++;
+               sdata->dev->stats.rx_bytes += skb->len;
        }
 }