/work/build/src/udev/link-config-gperf.c
Line | Count | Source (jump to first uncovered line) |
1 | | /* ANSI-C code produced by gperf version 3.1 */ |
2 | | /* Command-line: /usr/bin/gperf --output-file src/udev/link-config-gperf.c ../../src/systemd/src/udev/net/link-config-gperf.gperf */ |
3 | | /* Computed positions: -k'6,12,17-18,20,$' */ |
4 | | |
5 | | #if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \ |
6 | | && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \ |
7 | | && (')' == 41) && ('*' == 42) && ('+' == 43) && (',' == 44) \ |
8 | | && ('-' == 45) && ('.' == 46) && ('/' == 47) && ('0' == 48) \ |
9 | | && ('1' == 49) && ('2' == 50) && ('3' == 51) && ('4' == 52) \ |
10 | | && ('5' == 53) && ('6' == 54) && ('7' == 55) && ('8' == 56) \ |
11 | | && ('9' == 57) && (':' == 58) && (';' == 59) && ('<' == 60) \ |
12 | | && ('=' == 61) && ('>' == 62) && ('?' == 63) && ('A' == 65) \ |
13 | | && ('B' == 66) && ('C' == 67) && ('D' == 68) && ('E' == 69) \ |
14 | | && ('F' == 70) && ('G' == 71) && ('H' == 72) && ('I' == 73) \ |
15 | | && ('J' == 74) && ('K' == 75) && ('L' == 76) && ('M' == 77) \ |
16 | | && ('N' == 78) && ('O' == 79) && ('P' == 80) && ('Q' == 81) \ |
17 | | && ('R' == 82) && ('S' == 83) && ('T' == 84) && ('U' == 85) \ |
18 | | && ('V' == 86) && ('W' == 87) && ('X' == 88) && ('Y' == 89) \ |
19 | | && ('Z' == 90) && ('[' == 91) && ('\\' == 92) && (']' == 93) \ |
20 | | && ('^' == 94) && ('_' == 95) && ('a' == 97) && ('b' == 98) \ |
21 | | && ('c' == 99) && ('d' == 100) && ('e' == 101) && ('f' == 102) \ |
22 | | && ('g' == 103) && ('h' == 104) && ('i' == 105) && ('j' == 106) \ |
23 | | && ('k' == 107) && ('l' == 108) && ('m' == 109) && ('n' == 110) \ |
24 | | && ('o' == 111) && ('p' == 112) && ('q' == 113) && ('r' == 114) \ |
25 | | && ('s' == 115) && ('t' == 116) && ('u' == 117) && ('v' == 118) \ |
26 | | && ('w' == 119) && ('x' == 120) && ('y' == 121) && ('z' == 122) \ |
27 | | && ('{' == 123) && ('|' == 124) && ('}' == 125) && ('~' == 126)) |
28 | | /* The character set is not based on ISO-646. */ |
29 | | #error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gperf@gnu.org>." |
30 | | #endif |
31 | | |
32 | | #line 2 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
33 | | |
34 | | _Pragma("GCC diagnostic ignored \"-Wimplicit-fallthrough\"") |
35 | | #if __GNUC__ >= 15 |
36 | | _Pragma("GCC diagnostic ignored \"-Wzero-as-null-pointer-constant\"") |
37 | | #endif |
38 | | #include <stddef.h> |
39 | | #include "condition.h" |
40 | | #include "conf-parser.h" |
41 | | #include "ethtool-util.h" |
42 | | #include "link-config.h" |
43 | | #include "net-condition.h" |
44 | | #include "netif-sriov.h" |
45 | | #include "socket-util.h" |
46 | | #include <string.h> |
47 | | |
48 | | #define TOTAL_KEYWORDS 118 |
49 | 148k | #define MIN_WORD_LENGTH 8 |
50 | 297k | #define MAX_WORD_LENGTH 41 |
51 | | #define MIN_HASH_VALUE 9 |
52 | 147k | #define MAX_HASH_VALUE 202 |
53 | | /* maximum key range = 194, duplicates = 0 */ |
54 | | |
55 | | #ifdef __GNUC__ |
56 | | __inline |
57 | | #else |
58 | | #ifdef __cplusplus |
59 | | inline |
60 | | #endif |
61 | | #endif |
62 | | static unsigned int |
63 | | link_config_gperf_hash (register const char *str, register size_t len) |
64 | 147k | { |
65 | 147k | static const unsigned char asso_values[] = |
66 | 147k | { |
67 | 147k | 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, |
68 | 147k | 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, |
69 | 147k | 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, |
70 | 147k | 203, 203, 60, 203, 203, 203, 203, 203, 203, 203, |
71 | 147k | 203, 203, 5, 203, 203, 95, 0, 10, 203, 203, |
72 | 147k | 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, |
73 | 147k | 203, 203, 203, 203, 203, 20, 0, 0, 65, 15, |
74 | 147k | 125, 25, 35, 40, 203, 203, 30, 97, 0, 25, |
75 | 147k | 0, 203, 5, 45, 0, 15, 20, 25, 203, 203, |
76 | 147k | 203, 203, 203, 203, 203, 203, 203, 0, 203, 10, |
77 | 147k | 50, 0, 0, 0, 40, 0, 203, 25, 5, 75, |
78 | 147k | 0, 0, 5, 65, 0, 0, 35, 40, 20, 5, |
79 | 147k | 0, 15, 40, 203, 203, 203, 203, 203, 203, 203, |
80 | 147k | 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, |
81 | 147k | 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, |
82 | 147k | 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, |
83 | 147k | 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, |
84 | 147k | 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, |
85 | 147k | 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, |
86 | 147k | 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, |
87 | 147k | 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, |
88 | 147k | 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, |
89 | 147k | 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, |
90 | 147k | 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, |
91 | 147k | 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, |
92 | 147k | 203, 203, 203, 203, 203, 203 |
93 | 147k | }; |
94 | 147k | register unsigned int hval = len; |
95 | | |
96 | 147k | switch (hval) |
97 | 147k | { |
98 | 22.0k | default: |
99 | 22.0k | hval += asso_values[(unsigned char)str[19]]; |
100 | | /*FALLTHROUGH*/ |
101 | 23.2k | case 19: |
102 | 29.6k | case 18: |
103 | 29.6k | hval += asso_values[(unsigned char)str[17]]; |
104 | | /*FALLTHROUGH*/ |
105 | 31.8k | case 17: |
106 | 31.8k | hval += asso_values[(unsigned char)str[16]]; |
107 | | /*FALLTHROUGH*/ |
108 | 39.1k | case 16: |
109 | 43.4k | case 15: |
110 | 50.2k | case 14: |
111 | 59.1k | case 13: |
112 | 136k | case 12: |
113 | 136k | hval += asso_values[(unsigned char)str[11]]; |
114 | | /*FALLTHROUGH*/ |
115 | 137k | case 11: |
116 | 143k | case 10: |
117 | 145k | case 9: |
118 | 147k | case 8: |
119 | 147k | case 7: |
120 | 147k | case 6: |
121 | 147k | hval += asso_values[(unsigned char)str[5]]; |
122 | 147k | break; |
123 | 147k | } |
124 | 147k | return hval + asso_values[(unsigned char)str[len - 1]]; |
125 | 147k | } |
126 | | |
127 | | const struct ConfigPerfItem * |
128 | | link_config_gperf_lookup (register const char *str, register size_t len) |
129 | 148k | { |
130 | 148k | static const struct ConfigPerfItem wordlist[] = |
131 | 148k | { |
132 | 148k | {(char*)0}, {(char*)0}, {(char*)0}, {(char*)0}, |
133 | 148k | {(char*)0}, {(char*)0}, {(char*)0}, {(char*)0}, |
134 | 148k | {(char*)0}, |
135 | 148k | #line 52 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
136 | 148k | {"Link.Name", config_parse_ifname, 0, offsetof(LinkConfig, name)}, |
137 | 148k | #line 32 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
138 | 148k | {"Match.Type", config_parse_match_strv, 0, offsetof(LinkConfig, match.iftype)}, |
139 | 148k | {(char*)0}, |
140 | 148k | #line 31 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
141 | 148k | {"Match.Driver", config_parse_match_strv, 0, offsetof(LinkConfig, match.driver)}, |
142 | 148k | #line 39 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
143 | 148k | {"Match.Version", config_parse_net_condition, CONDITION_VERSION, offsetof(LinkConfig, conditions)}, |
144 | 148k | #line 42 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
145 | 148k | {"Match.Firmware", config_parse_net_condition, CONDITION_FIRMWARE, offsetof(LinkConfig, conditions)}, |
146 | 148k | #line 92 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
147 | 148k | {"Link.TxChannels", config_parse_ring_buffer_or_channel, 0, offsetof(LinkConfig, channels.tx)}, |
148 | 148k | {(char*)0}, |
149 | 148k | #line 99 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
150 | 148k | {"Link.TxBufferSize", config_parse_ring_buffer_or_channel, 0, offsetof(LinkConfig, ring.tx)}, |
151 | 148k | {(char*)0}, {(char*)0}, |
152 | 148k | #line 91 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
153 | 148k | {"Link.RxChannels", config_parse_ring_buffer_or_channel, 0, offsetof(LinkConfig, channels.rx)}, |
154 | 148k | #line 40 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
155 | 148k | {"Match.Credential", config_parse_net_condition, CONDITION_CREDENTIAL, offsetof(LinkConfig, conditions)}, |
156 | 148k | #line 96 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
157 | 148k | {"Link.RxBufferSize", config_parse_ring_buffer_or_channel, 0, offsetof(LinkConfig, ring.rx)}, |
158 | 148k | #line 57 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
159 | 148k | {"Link.ReceiveQueues", config_parse_rx_tx_queues, 0, offsetof(LinkConfig, rxqueues)}, |
160 | 148k | #line 38 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
161 | 148k | {"Match.KernelVersion", config_parse_net_condition, CONDITION_VERSION, offsetof(LinkConfig, conditions)}, |
162 | 148k | #line 89 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
163 | 148k | {"Link.ReceiveAll", config_parse_tristate, 0, offsetof(LinkConfig, features[NET_DEV_FEAT_RXALL])}, |
164 | 148k | #line 94 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
165 | 148k | {"Link.CombinedChannels", config_parse_ring_buffer_or_channel, 0, offsetof(LinkConfig, channels.combined)}, |
166 | 148k | #line 98 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
167 | 148k | {"Link.RxJumboBufferSize", config_parse_ring_buffer_or_channel, 0, offsetof(LinkConfig, ring.rx_jumbo)}, |
168 | 148k | #line 102 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
169 | 148k | {"Link.TxFlowControl", config_parse_tristate, 0, offsetof(LinkConfig, tx_flow_control)}, |
170 | 148k | #line 34 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
171 | 148k | {"Match.Property", config_parse_match_property, 0, offsetof(LinkConfig, match.property)}, |
172 | 148k | #line 55 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
173 | 148k | {"Link.Alias", config_parse_ifalias, 0, offsetof(LinkConfig, alias)}, |
174 | 148k | {(char*)0}, {(char*)0}, |
175 | 148k | #line 101 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
176 | 148k | {"Link.RxFlowControl", config_parse_tristate, 0, offsetof(LinkConfig, rx_flow_control)}, |
177 | 148k | #line 66 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
178 | 148k | {"Link.Advertise", config_parse_advertise, 0, offsetof(LinkConfig, advertise)}, |
179 | 148k | #line 51 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
180 | 148k | {"Link.NamePolicy", config_parse_name_policy, 0, offsetof(LinkConfig, name_policy)}, |
181 | 148k | #line 119 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
182 | 148k | {"Link.TxCoalesceLowSec", config_parse_coalesce_sec, 0, offsetof(LinkConfig, coalesce.tx_coalesce_usecs_low)}, |
183 | 148k | {(char*)0}, |
184 | 148k | #line 109 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
185 | 148k | {"Link.TxCoalesceSec", config_parse_coalesce_sec, 0, offsetof(LinkConfig, coalesce.tx_coalesce_usecs)}, |
186 | 148k | {(char*)0}, |
187 | 148k | #line 53 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
188 | 148k | {"Link.AlternativeName", config_parse_ifnames, IFNAME_VALID_ALTERNATIVE, offsetof(LinkConfig, alternative_names)}, |
189 | 148k | #line 117 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
190 | 148k | {"Link.RxCoalesceLowSec", config_parse_coalesce_sec, 0, offsetof(LinkConfig, coalesce.rx_coalesce_usecs_low)}, |
191 | 148k | {(char*)0}, |
192 | 148k | #line 105 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
193 | 148k | {"Link.RxCoalesceSec", config_parse_coalesce_sec, 0, offsetof(LinkConfig, coalesce.rx_coalesce_usecs)}, |
194 | 148k | #line 67 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
195 | 148k | {"Link.Port", config_parse_port, 0, offsetof(LinkConfig, port)}, |
196 | 148k | #line 35 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
197 | 148k | {"Match.Host", config_parse_net_condition, CONDITION_HOST, offsetof(LinkConfig, conditions)}, |
198 | 148k | #line 115 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
199 | 148k | {"Link.UseAdaptiveTxCoalesce", config_parse_tristate, 0, offsetof(LinkConfig, coalesce.use_adaptive_tx_coalesce)}, |
200 | 148k | {(char*)0}, |
201 | 148k | #line 48 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
202 | 148k | {"/* rtnl setlink */"}, |
203 | 148k | {(char*)0}, |
204 | 148k | #line 30 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
205 | 148k | {"Match.Path", config_parse_match_strv, 0, offsetof(LinkConfig, match.path)}, |
206 | 148k | #line 114 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
207 | 148k | {"Link.UseAdaptiveRxCoalesce", config_parse_tristate, 0, offsetof(LinkConfig, coalesce.use_adaptive_rx_coalesce)}, |
208 | 148k | {(char*)0}, |
209 | 148k | #line 41 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
210 | 148k | {"Match.Architecture", config_parse_net_condition, CONDITION_ARCHITECTURE, offsetof(LinkConfig, conditions)}, |
211 | 148k | #line 134 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
212 | 148k | {"SR-IOV.VLANProtocol", config_parse_sr_iov_vlan_proto, 0, offsetof(LinkConfig, sr_iov_by_section)}, |
213 | 148k | #line 36 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
214 | 148k | {"Match.Virtualization", config_parse_net_condition, CONDITION_VIRTUALIZATION, offsetof(LinkConfig, conditions)}, |
215 | 148k | #line 85 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
216 | 148k | {"Link.ReceiveVLANCTAGFilter", config_parse_tristate, 0, offsetof(LinkConfig, features[NET_DEV_FEAT_HW_VLAN_CTAG_FILTER])}, |
217 | 148k | {(char*)0}, |
218 | 148k | #line 37 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
219 | 148k | {"Match.KernelCommandLine", config_parse_net_condition, CONDITION_KERNEL_COMMAND_LINE, offsetof(LinkConfig, conditions)}, |
220 | 148k | #line 56 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
221 | 148k | {"Link.TransmitQueues", config_parse_rx_tx_queues, 0, offsetof(LinkConfig, txqueues)}, |
222 | 148k | #line 33 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
223 | 148k | {"Match.Kind", config_parse_match_strv, 0, offsetof(LinkConfig, match.kind)}, |
224 | 148k | #line 84 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
225 | 148k | {"Link.TransmitVLANCTAGHardwareAcceleration", config_parse_tristate, 0, offsetof(LinkConfig, features[NET_DEV_FEAT_HW_VLAN_CTAG_TX])}, |
226 | 148k | #line 54 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
227 | 148k | {"Link.AlternativeNamesPolicy", config_parse_alternative_names_policy, 0, offsetof(LinkConfig, alternative_names_policy)}, |
228 | 148k | #line 45 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
229 | 148k | {"Link.Property", config_parse_udev_property, 0, offsetof(LinkConfig, properties)}, |
230 | 148k | {(char*)0}, |
231 | 148k | #line 88 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
232 | 148k | {"Link.ReceiveFCS", config_parse_tristate, 0, offsetof(LinkConfig, features[NET_DEV_FEAT_RXFCS])}, |
233 | 148k | #line 27 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
234 | 148k | {"Match.MACAddress", config_parse_hw_addrs, 0, offsetof(LinkConfig, match.hw_addr)}, |
235 | 148k | {(char*)0}, |
236 | 148k | #line 120 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
237 | 148k | {"Link.TxMaxCoalescedLowFrames", config_parse_coalesce_u32, 0, offsetof(LinkConfig, coalesce.tx_max_coalesced_frames_low)}, |
238 | 148k | #line 70 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
239 | 148k | {"Link.WakeOnLan", config_parse_wol, 0, offsetof(LinkConfig, wol)}, |
240 | 148k | #line 83 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
241 | 148k | {"Link.ReceiveVLANCTAGHardwareAcceleration", config_parse_tristate, 0, offsetof(LinkConfig, features[NET_DEV_FEAT_HW_VLAN_CTAG_RX])}, |
242 | 148k | #line 116 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
243 | 148k | {"Link.CoalescePacketRateLow", config_parse_coalesce_u32, 0, offsetof(LinkConfig, coalesce.pkt_rate_low)}, |
244 | 148k | {(char*)0}, |
245 | 148k | #line 118 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
246 | 148k | {"Link.RxMaxCoalescedLowFrames", config_parse_coalesce_u32, 0, offsetof(LinkConfig, coalesce.rx_max_coalesced_frames_low)}, |
247 | 148k | #line 125 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
248 | 148k | {"Link.TxMaxCoalescedHighFrames", config_parse_coalesce_u32, 0, offsetof(LinkConfig, coalesce.tx_max_coalesced_frames_high)}, |
249 | 148k | #line 65 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
250 | 148k | {"Link.AutoNegotiation", config_parse_tristate, 0, offsetof(LinkConfig, autonegotiation)}, |
251 | 148k | #line 64 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
252 | 148k | {"Link.Duplex", config_parse_duplex, 0, offsetof(LinkConfig, duplex)}, |
253 | 148k | #line 124 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
254 | 148k | {"Link.TxCoalesceHighSec", config_parse_coalesce_sec, 0, offsetof(LinkConfig, coalesce.tx_coalesce_usecs_high)}, |
255 | 148k | #line 112 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
256 | 148k | {"Link.TxMaxCoalescedIrqFrames", config_parse_coalesce_u32, 0, offsetof(LinkConfig, coalesce.tx_max_coalesced_frames_irq)}, |
257 | 148k | #line 123 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
258 | 148k | {"Link.RxMaxCoalescedHighFrames", config_parse_coalesce_u32, 0, offsetof(LinkConfig, coalesce.rx_max_coalesced_frames_high)}, |
259 | 148k | {(char*)0}, |
260 | 148k | #line 138 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
261 | 148k | {"SR-IOV.LinkState", config_parse_sr_iov_link_state, 0, offsetof(LinkConfig, sr_iov_by_section)}, |
262 | 148k | #line 122 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
263 | 148k | {"Link.RxCoalesceHighSec", config_parse_coalesce_sec, 0, offsetof(LinkConfig, coalesce.rx_coalesce_usecs_high)}, |
264 | 148k | #line 108 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
265 | 148k | {"Link.RxMaxCoalescedIrqFrames", config_parse_coalesce_u32, 0, offsetof(LinkConfig, coalesce.rx_max_coalesced_frames_irq)}, |
266 | 148k | #line 95 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
267 | 148k | {"/* ethtool ring parameters */"}, |
268 | 148k | {(char*)0}, |
269 | 148k | #line 43 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
270 | 148k | {"Link.Description", config_parse_string, 0, offsetof(LinkConfig, description)}, |
271 | 148k | #line 139 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
272 | 148k | {"SR-IOV.MACAddress", config_parse_sr_iov_mac, 0, offsetof(LinkConfig, sr_iov_by_section)}, |
273 | 148k | #line 93 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
274 | 148k | {"Link.OtherChannels", config_parse_ring_buffer_or_channel, 0, offsetof(LinkConfig, channels.other)}, |
275 | 148k | {(char*)0}, |
276 | 148k | #line 126 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
277 | 148k | {"Link.CoalescePacketRateSampleIntervalSec", config_parse_coalesce_sec, 0, offsetof(LinkConfig, coalesce.rate_sample_interval)}, |
278 | 148k | #line 103 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
279 | 148k | {"Link.AutoNegotiationFlowControl", config_parse_tristate, 0, offsetof(LinkConfig, autoneg_flow_control)}, |
280 | 148k | #line 131 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
281 | 148k | {"SR-IOV.VirtualFunction", config_parse_sr_iov_uint32, 0, offsetof(LinkConfig, sr_iov_by_section)}, |
282 | 148k | #line 29 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
283 | 148k | {"Match.OriginalName", config_parse_match_ifnames, 0, offsetof(LinkConfig, match.ifname)}, |
284 | 148k | #line 60 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
285 | 148k | {"Link.GenericSegmentOffloadMaxBytes", config_parse_iec_size, 0, offsetof(LinkConfig, gso_max_size)}, |
286 | 148k | #line 28 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
287 | 148k | {"Match.PermanentMACAddress", config_parse_hw_addrs, 0, offsetof(LinkConfig, match.permanent_hw_addr)}, |
288 | 148k | #line 111 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
289 | 148k | {"Link.TxCoalesceIrqSec", config_parse_coalesce_sec, 0, offsetof(LinkConfig, coalesce.tx_coalesce_usecs_irq)}, |
290 | 148k | #line 61 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
291 | 148k | {"Link.GenericSegmentOffloadMaxSegments", config_parse_uint32, 0, offsetof(LinkConfig, gso_max_segments)}, |
292 | 148k | #line 47 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
293 | 148k | {"Link.UnsetProperty", config_parse_udev_property_name, 0, offsetof(LinkConfig, unset_properties)}, |
294 | 148k | #line 44 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
295 | 148k | {"/* udev property */"}, |
296 | 148k | {(char*)0}, |
297 | 148k | #line 107 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
298 | 148k | {"Link.RxCoalesceIrqSec", config_parse_coalesce_sec, 0, offsetof(LinkConfig, coalesce.rx_coalesce_usecs_irq)}, |
299 | 148k | #line 137 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
300 | 148k | {"SR-IOV.Trust", config_parse_sr_iov_boolean, 0, offsetof(LinkConfig, sr_iov_by_section)}, |
301 | 148k | {(char*)0}, |
302 | 148k | #line 58 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
303 | 148k | {"Link.TransmitQueueLength", config_parse_txqueuelen, 0, offsetof(LinkConfig, txqueuelen)}, |
304 | 148k | {(char*)0}, |
305 | 148k | #line 86 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
306 | 148k | {"Link.TransmitVLANSTAGHardwareAcceleration", config_parse_tristate, 0, offsetof(LinkConfig, features[NET_DEV_FEAT_HW_VLAN_STAG_TX])}, |
307 | 148k | #line 121 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
308 | 148k | {"Link.CoalescePacketRateHigh", config_parse_coalesce_u32, 0, offsetof(LinkConfig, coalesce.pkt_rate_high)}, |
309 | 148k | #line 133 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
310 | 148k | {"SR-IOV.QualityOfService", config_parse_sr_iov_uint32, 0, offsetof(LinkConfig, sr_iov_by_section)}, |
311 | 148k | #line 46 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
312 | 148k | {"Link.ImportProperty", config_parse_udev_property_name, 0, offsetof(LinkConfig, import_properties)}, |
313 | 148k | #line 59 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
314 | 148k | {"Link.MTUBytes", config_parse_mtu, AF_UNSPEC, offsetof(LinkConfig, mtu)}, |
315 | 148k | #line 97 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
316 | 148k | {"Link.RxMiniBufferSize", config_parse_ring_buffer_or_channel, 0, offsetof(LinkConfig, ring.rx_mini)}, |
317 | 148k | #line 50 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
318 | 148k | {"Link.MACAddress", config_parse_hw_addr, 0, offsetof(LinkConfig, hw_addr)}, |
319 | 148k | #line 77 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
320 | 148k | {"Link.TCP6SegmentationOffload", config_parse_tristate, 0, offsetof(LinkConfig, features[NET_DEV_FEAT_TSO6])}, |
321 | 148k | #line 81 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
322 | 148k | {"Link.GenericReceiveOffloadHardware", config_parse_tristate, 0, offsetof(LinkConfig, features[NET_DEV_FEAT_GRO_HW])}, |
323 | 148k | {(char*)0}, |
324 | 148k | #line 75 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
325 | 148k | {"Link.GenericSegmentationOffload", config_parse_tristate, 0, offsetof(LinkConfig, features[NET_DEV_FEAT_GSO])}, |
326 | 148k | #line 62 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
327 | 148k | {"/* ethtool link settings */"}, |
328 | 148k | #line 63 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
329 | 148k | {"Link.BitsPerSecond", config_parse_si_uint64, 0, offsetof(LinkConfig, speed)}, |
330 | 148k | {(char*)0}, |
331 | 148k | #line 141 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
332 | 148k | {"EnergyEfficientEthernet.Enable", config_parse_tristate, 0, offsetof(LinkConfig, eee_enabled)}, |
333 | 148k | #line 127 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
334 | 148k | {"/* Rx RPS CPU mask */"}, |
335 | 148k | #line 144 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
336 | 148k | {"EnergyEfficientEthernet.LinkMode", config_parse_advertise, 0, offsetof(LinkConfig, eee_advertise)}, |
337 | 148k | #line 132 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
338 | 148k | {"SR-IOV.VLANId", config_parse_sr_iov_uint32, 0, offsetof(LinkConfig, sr_iov_by_section)}, |
339 | 148k | {(char*)0}, {(char*)0}, |
340 | 148k | #line 140 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
341 | 148k | {"/* ethtool EEE settings */"}, |
342 | 148k | #line 71 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
343 | 148k | {"Link.WakeOnLanPassword", config_parse_wol_password, 0, 0}, |
344 | 148k | #line 142 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
345 | 148k | {"EnergyEfficientEthernet.TxLowPowerIdle", config_parse_tristate, 0, offsetof(LinkConfig, eee_tx_lpi_enabled)}, |
346 | 148k | #line 82 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
347 | 148k | {"Link.LargeReceiveOffload", config_parse_tristate, 0, offsetof(LinkConfig, features[NET_DEV_FEAT_LRO])}, |
348 | 148k | #line 136 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
349 | 148k | {"SR-IOV.QueryReceiveSideScaling", config_parse_sr_iov_boolean, 0, offsetof(LinkConfig, sr_iov_by_section)}, |
350 | 148k | #line 129 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
351 | 148k | {"/* SR-IOV settings */"}, |
352 | 148k | #line 72 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
353 | 148k | {"/* ethtool features */"}, |
354 | 148k | #line 128 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
355 | 148k | {"Link.ReceivePacketSteeringCPUMask", config_parse_rps_cpu_mask, 0, offsetof(LinkConfig, rps_cpu_mask)}, |
356 | 148k | {(char*)0}, |
357 | 148k | #line 135 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
358 | 148k | {"SR-IOV.MACSpoofCheck", config_parse_sr_iov_boolean, 0, offsetof(LinkConfig, sr_iov_by_section)}, |
359 | 148k | #line 69 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
360 | 148k | {"/* ethtool WoL settings */"}, |
361 | 148k | #line 130 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
362 | 148k | {"Link.SR-IOVVirtualFunctions", config_parse_sr_iov_num_vfs, 0, offsetof(LinkConfig, sr_iov_num_vfs)}, |
363 | 148k | #line 78 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
364 | 148k | {"Link.PartialGenericSegmentationOffload", config_parse_tristate, 0, offsetof(LinkConfig, features[NET_DEV_FEAT_GSO_PARTIAL])}, |
365 | 148k | {(char*)0}, {(char*)0}, |
366 | 148k | #line 143 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
367 | 148k | {"EnergyEfficientEthernet.TxLowPowerIdleSec", config_parse_sec, 0, offsetof(LinkConfig, eee_tx_lpi_timer_usec)}, |
368 | 148k | #line 87 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
369 | 148k | {"Link.NTupleFilter", config_parse_tristate, 0, offsetof(LinkConfig, features[NET_DEV_FEAT_NTUPLE])}, |
370 | 148k | {(char*)0}, {(char*)0}, |
371 | 148k | #line 68 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
372 | 148k | {"Link.MDI", config_parse_mdi, 0, offsetof(LinkConfig, mdi)}, |
373 | 148k | {(char*)0}, |
374 | 148k | #line 90 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
375 | 148k | {"/* ethtool channels */"}, |
376 | 148k | #line 49 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
377 | 148k | {"Link.MACAddressPolicy", config_parse_mac_address_policy, 0, offsetof(LinkConfig, mac_address_policy)}, |
378 | 148k | {(char*)0}, |
379 | 148k | #line 100 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
380 | 148k | {"/* ethtool pause parameters */"}, |
381 | 148k | #line 113 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
382 | 148k | {"Link.StatisticsBlockCoalesceSec", config_parse_coalesce_sec, 0, offsetof(LinkConfig, coalesce.stats_block_coalesce_usecs)}, |
383 | 148k | {(char*)0}, |
384 | 148k | #line 74 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
385 | 148k | {"Link.TransmitChecksumOffload", config_parse_tristate, 0, offsetof(LinkConfig, features[NET_DEV_FEAT_TXCSUM])}, |
386 | 148k | {(char*)0}, {(char*)0}, |
387 | 148k | #line 80 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
388 | 148k | {"Link.GenericReceiveOffload", config_parse_tristate, 0, offsetof(LinkConfig, features[NET_DEV_FEAT_GRO])}, |
389 | 148k | {(char*)0}, {(char*)0}, {(char*)0}, |
390 | 148k | #line 110 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
391 | 148k | {"Link.TxMaxCoalescedFrames", config_parse_coalesce_u32, 0, offsetof(LinkConfig, coalesce.tx_max_coalesced_frames)}, |
392 | 148k | #line 104 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
393 | 148k | {"/* ethtool coalesce settings */"}, |
394 | 148k | {(char*)0}, {(char*)0}, {(char*)0}, |
395 | 148k | #line 106 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
396 | 148k | {"Link.RxMaxCoalescedFrames", config_parse_coalesce_u32, 0, offsetof(LinkConfig, coalesce.rx_max_coalesced_frames)}, |
397 | 148k | {(char*)0}, {(char*)0}, {(char*)0}, {(char*)0}, |
398 | 148k | {(char*)0}, {(char*)0}, {(char*)0}, {(char*)0}, |
399 | 148k | {(char*)0}, {(char*)0}, {(char*)0}, {(char*)0}, |
400 | 148k | {(char*)0}, {(char*)0}, {(char*)0}, {(char*)0}, |
401 | 148k | #line 73 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
402 | 148k | {"Link.ReceiveChecksumOffload", config_parse_tristate, 0, offsetof(LinkConfig, features[NET_DEV_FEAT_RXCSUM])}, |
403 | 148k | {(char*)0}, {(char*)0}, {(char*)0}, {(char*)0}, |
404 | 148k | #line 76 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
405 | 148k | {"Link.TCPSegmentationOffload", config_parse_tristate, 0, offsetof(LinkConfig, features[NET_DEV_FEAT_TSO])}, |
406 | 148k | {(char*)0}, {(char*)0}, {(char*)0}, {(char*)0}, |
407 | 148k | {(char*)0}, {(char*)0}, {(char*)0}, {(char*)0}, |
408 | 148k | {(char*)0}, {(char*)0}, {(char*)0}, {(char*)0}, |
409 | 148k | {(char*)0}, {(char*)0}, |
410 | 148k | #line 79 "../../src/systemd/src/udev/net/link-config-gperf.gperf" |
411 | 148k | {"Link.UDPSegmentationOffload", config_parse_warn_compat, DISABLED_LEGACY, 0} |
412 | 148k | }; |
413 | | |
414 | 148k | if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH) |
415 | 147k | { |
416 | 147k | register unsigned int key = link_config_gperf_hash (str, len); |
417 | | |
418 | 147k | if (key <= MAX_HASH_VALUE) |
419 | 145k | { |
420 | 145k | register const char *s = wordlist[key].section_and_lvalue; |
421 | | |
422 | 145k | if (s && *str == *s && !strcmp (str + 1, s + 1)) |
423 | 141k | return &wordlist[key]; |
424 | 145k | } |
425 | 147k | } |
426 | 7.24k | return 0; |
427 | 148k | } |