return 0;
}
+void print_devname(enum output_type type, int ifindex)
+{
+ const char *ifname = ll_index_to_name(ifindex);
+
+ if (!is_json_context())
+ printf("dev ");
+
+ print_color_string(type, COLOR_IFNAME,
+ "dev", "%s ", ifname);
+}
+
void print_size(char *buf, int len, __u32 sz)
{
double tmp = sz;
memcpy(&re, RTA_DATA(tbs[TCA_STATS_RATE_EST]),
MIN(RTA_PAYLOAD(tbs[TCA_STATS_RATE_EST]), sizeof(re)));
- fprintf(fp, "\n%srate %s %upps ",
- prefix, sprint_rate(re.bps, b1), re.pps);
print_string(PRINT_FP, NULL, "\n%s", prefix);
print_uint(PRINT_JSON, "rate", NULL, re.bps);
print_string(PRINT_FP, NULL, "rate %s",