#define INDENT_STR_MAXLEN 32
static char g_indent_str[INDENT_STR_MAXLEN + 1] = "";
-static bool use_iec = false;
-
static void __attribute__((format(printf, 1, 2)))
pr_err(const char *fmt, ...)
{
bool verbose;
bool stats;
bool hex;
+ bool use_iec;
bool map_loaded;
struct {
bool present;
mnl_attr_get_u64(tb[DEVLINK_ATTR_RATE_TX_SHARE]);
if (rate)
- print_rate(use_iec, PRINT_ANY, "tx_share",
+ print_rate(dl->use_iec, PRINT_ANY, "tx_share",
" tx_share %s", rate);
}
if (tb[DEVLINK_ATTR_RATE_TX_MAX]) {
mnl_attr_get_u64(tb[DEVLINK_ATTR_RATE_TX_MAX]);
if (rate)
- print_rate(use_iec, PRINT_ANY, "tx_max",
+ print_rate(dl->use_iec, PRINT_ANY, "tx_max",
" tx_max %s", rate);
}
if (tb[DEVLINK_ATTR_RATE_PARENT_NODE_NAME]) {
}
break;
case 'i':
- use_iec = true;
+ dl->use_iec = true;
break;
case 'x':
dl->hex = true;