mirror of
https://git.proxmox.com/git/mirror_iproute2
synced 2025-10-05 22:35:10 +00:00

Use new functions from json_print to simplify code. Provide standard flag for colorizing output. The shortened -c flag is ambiguous it could mean color or compressvlan; it is now changed to mean color for consistency with other iproute2 commands. Signed-off-by: Stephen Hemminger <stephen@networkplumber.org> Signed-off-by: David Ahern <dsahern@gmail.com>
31 lines
961 B
C
31 lines
961 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
|
|
#define MDB_RTA(r) \
|
|
((struct rtattr *)(((char *)(r)) + RTA_ALIGN(sizeof(struct br_mdb_entry))))
|
|
|
|
#define MDB_RTR_RTA(r) \
|
|
((struct rtattr *)(((char *)(r)) + RTA_ALIGN(sizeof(__u32))))
|
|
|
|
extern void print_vlan_info(FILE *fp, struct rtattr *tb);
|
|
extern int print_linkinfo(const struct sockaddr_nl *who,
|
|
struct nlmsghdr *n,
|
|
void *arg);
|
|
extern int print_fdb(const struct sockaddr_nl *who,
|
|
struct nlmsghdr *n, void *arg);
|
|
extern int print_mdb(const struct sockaddr_nl *who,
|
|
struct nlmsghdr *n, void *arg);
|
|
|
|
extern int do_fdb(int argc, char **argv);
|
|
extern int do_mdb(int argc, char **argv);
|
|
extern int do_monitor(int argc, char **argv);
|
|
extern int do_vlan(int argc, char **argv);
|
|
extern int do_link(int argc, char **argv);
|
|
|
|
extern int preferred_family;
|
|
extern int show_stats;
|
|
extern int show_details;
|
|
extern int timestamp;
|
|
extern int compress_vlans;
|
|
extern int json;
|
|
extern struct rtnl_handle rth;
|