#include "gateway_common.h"
#include <linux/atomic.h>
#include <linux/byteorder/generic.h>
#include <linux/kernel.h>
#include <linux/math64.h>
#include <linux/netdevice.h>
#include <linux/stddef.h>
#include <linux/string.h>
#include <uapi/linux/batadv_packet.h>
#include <uapi/linux/batman_adv.h>
#include "gateway_client.h"
bool batadv_parse_throughput(struct net_device *net_dev, char *buff,
const char *description, u32 *throughput)
enum batadv_bandwidth_units bw_unit_type = BATADV_BW_UNIT_KBIT;
tmp_ptr = buff + strlen(buff) - 4;
if (strncasecmp(tmp_ptr, "mbit", 4) == 0)
bw_unit_type = BATADV_BW_UNIT_MBIT;
if (strncasecmp(tmp_ptr, "kbit", 4) == 0 ||
bw_unit_type == BATADV_BW_UNIT_MBIT)
ret = kstrtou64(buff, 10, <hroughput);
"Invalid throughput speed for %s: %s\n",
case BATADV_BW_UNIT_MBIT: