net: wifi: Unicast frames statistics

Unicast RX stats
It represents total number of unicast (any type data, action or
any other unicast frames) frames received at firmware level.
The actual frames passed to host will be different as firmware
may drop packets or some packets may be dropped because of
errors.

Unicast TX stats
Transmission side the unicast packets count states the packets
handed over to firmware. The stats taken at firmware level.
Actual packets transmission may vary depending upon various factors.

Signed-off-by: Ajay Parida <ajay.parida@nordicsemi.no>
This commit is contained in:
Ajay Parida 2024-04-24 15:51:28 +05:30 committed by Johan Hedberg
parent 65e787be58
commit 1542140e4e
2 changed files with 3 additions and 0 deletions

View file

@ -494,6 +494,7 @@ struct net_stats_wifi {
struct net_stats_pkts broadcast;
struct net_stats_pkts multicast;
struct net_stats_pkts errors;
struct net_stats_pkts unicast;
};
#if defined(CONFIG_NET_STATISTICS_USER_API)

View file

@ -856,6 +856,8 @@ static void print_wifi_stats(struct net_if *iface, struct net_stats_wifi *data,
PR("Mcast sent : %u\n", data->multicast.tx);
PR("Beacons received : %u\n", data->sta_mgmt.beacons_rx);
PR("Beacons missed : %u\n", data->sta_mgmt.beacons_miss);
PR("Unicast received : %u\n", data->unicast.rx);
PR("Unicast sent : %u\n", data->unicast.tx);
}
#endif /* CONFIG_NET_STATISTICS_WIFI && CONFIG_NET_STATISTICS_USER_API */