typedef enum nw_port_type {
NW_PORT_UNKNOWN = 0,
NW_PORT_DUMMY,
+ NW_PORT_VLAN,
} nw_port_type_t;
+// VLAN
+#define NW_VLAN_ID_INVALID 0
+#define NW_VLAN_ID_MIN 1
+#define NW_VLAN_ID_MAX 4096
+
typedef struct nw_port nw_port;
#include "address.h"
int __nw_port_update_stats(nw_daemon* daemon, nw_port* port, void* data);
int nw_port_update_stats(nw_port* port);
+// VLAN
+int nw_port_get_vlan_id(nw_port* port);
+int nw_port_set_vlan_id(nw_port* port, int id);
+
+nw_port* nw_port_get_vlan_parent(nw_port* port);
+int nw_port_set_vlan_parent(nw_port* port, nw_port* parent);
+
#endif /* NETWORKD_PORT_H */