]> git.ipfire.org Git - thirdparty/systemd.git/blob - src/udev/net/link-config-gperf.gperf
network/link: Match - filter on kernel cmdline, host and virt
[thirdparty/systemd.git] / src / udev / net / link-config-gperf.gperf
1 %{
2 #include <stddef.h>
3 #include "conf-parser.h"
4 #include "net-util.h"
5 #include "link-config.h"
6 #include "ethtool-util.h"
7 %}
8 struct ConfigPerfItem;
9 %null_strings
10 %language=ANSI-C
11 %define slot-name section_and_lvalue
12 %define hash-function-name link_config_gperf_hash
13 %define lookup-function-name link_config_gperf_lookup
14 %readonly-tables
15 %omit-struct-type
16 %struct-type
17 %includes
18 %%
19 Match.MACAddress, config_parse_hwaddr, 0, offsetof(link_config, match_mac)
20 Match.Path, config_parse_string, 0, offsetof(link_config, match_path)
21 Match.Driver, config_parse_string, 0, offsetof(link_config, match_driver)
22 Match.Type, config_parse_string, 0, offsetof(link_config, match_type)
23 Match.Host, config_parse_net_condition, CONDITION_HOST, offsetof(link_config, match_host)
24 Match.Virtualization, config_parse_net_condition, CONDITION_VIRTUALIZATION, offsetof(link_config, match_virt)
25 Match.KernelCommandLine, config_parse_net_condition, CONDITION_KERNEL_COMMAND_LINE, offsetof(link_config, match_kernel)
26 Link.Description, config_parse_string, 0, offsetof(link_config, description)
27 Link.MACAddressPolicy, config_parse_mac_policy, 0, offsetof(link_config, mac_policy)
28 Link.MACAddress, config_parse_hwaddr, 0, offsetof(link_config, mac)
29 Link.NamePolicy, config_parse_name_policy, 0, offsetof(link_config, name_policy)
30 Link.Name, config_parse_ifname, 0, offsetof(link_config, name)
31 Link.Alias, config_parse_ifalias, 0, offsetof(link_config, alias)
32 Link.MTU, config_parse_unsigned, 0, offsetof(link_config, mtu)
33 Link.SpeedMBytes, config_parse_unsigned, 0, offsetof(link_config, speed)
34 Link.Duplex, config_parse_duplex, 0, offsetof(link_config, duplex)
35 Link.WakeOnLan, config_parse_wol, 0, offsetof(link_config, wol)