Skip to content
Snippets Groups Projects
Commit 61b025cd authored by Giuseppe Pagano's avatar Giuseppe Pagano
Browse files

Use dunny Quectel EG25 stats to avoid kernel crash.

parent 21bde3ce
No related branches found
No related tags found
No related merge requests found
......@@ -979,6 +979,12 @@ EXPORT_SYMBOL_GPL(usbnet_set_settings);
struct rtnl_link_stats64 *
usbnet_get_stats64(struct net_device *net, struct rtnl_link_stats64 *stats)
{
#ifdef DUMMY_STATS_TO_AVOID_CRASH
stats->rx_packets = 0;
stats->rx_bytes = 0;
stats->tx_packets = 0;
stats->tx_bytes = 0;
#else
struct usbnet *dev = netdev_priv(net);
unsigned int start;
int cpu;
......@@ -1005,7 +1011,7 @@ usbnet_get_stats64(struct net_device *net, struct rtnl_link_stats64 *stats)
stats->tx_packets += tx_packets;
stats->tx_bytes += tx_bytes;
}
#endif /* DUMMY_STATS_TO_AVOID_CRASH */
return stats;
}
EXPORT_SYMBOL_GPL(usbnet_get_stats64);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment