network/netdev: introduce .iftype to netdev vtable

And disable .generate_mac flag for non-ether interfaces.
This commit is contained in:
Yu Watanabe
2021-11-27 06:38:26 +09:00
parent a67e0507c3
commit 9f0cf80dd0
23 changed files with 78 additions and 12 deletions
+3
View File
@@ -159,6 +159,9 @@ typedef struct NetDevVTable {
/* verify that compulsory configuration options were specified */
int (*config_verify)(NetDev *netdev, const char *filename);
/* expected iftype, e.g. ARPHRD_ETHER. */
uint16_t iftype;
/* Generate MAC address when MACAddress= is not specified. */
bool generate_mac;
} NetDevVTable;