Lines Matching +full:enum +full:- +full:as +full:- +full:flags
1 # SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause)
3 ---
4 $id: http://kernel.org/schemas/netlink/netlink-raw.yaml#
5 $schema: https://json-schema.org/draft-07/schema
12 len-or-define:
14 pattern: ^[0-9A-Za-z_]+( - 1)?$
21 required: [ name, doc, attribute-sets, operations ]
31 enum: [ netlink-raw ] # Trim
32 # Start netlink-raw
34 description: Protocol number to use for netlink-raw
36 # End netlink-raw
37 uapi-header:
38 description: Path to the uAPI header, default is linux/${family-name}.h
40 # Start genetlink-c
41 c-family-name:
44 c-version-name:
47 max-by-define:
48 …description: Makes the number of attributes and commands be specified by a define, not an enum val…
50 # End genetlink-c
51 # Start genetlink-legacy
52 kernel-policy:
54 … Defines if the input policy in the kernel is global, per-operation, or split per operation type.
56 enum: [ split, per-op, global ]
57 # End genetlink-legacy
60 description: List of type and constant definitions (enums, flags, defines).
70 description: For C-compatible languages, header which already defines this value.
73 enum: [ const, enum, flags, struct ] # Trim
78 description: For const - the value.
80 # For enum and flags
81 value-start:
82 description: For enum or flags the literal initializer for the first value.
85 description: For enum or flags array of values.
89 - type: string
90 - type: object
100 render-max:
101 description: Render the max members for this enum.
103 # Start genetlink-c
104 enum-name:
105 description: Name for enum, if empty no name will be used.
107 name-prefix:
108 description: For enum the prefix of the values, optional.
110 # End genetlink-c
111 # Start genetlink-legacy
124 enum: [ u8, u16, u32, u64, s8, s16, s32, s64, string, binary ]
126 $ref: '#/$defs/len-or-define'
127 byte-order:
128 enum: [ little-endian, big-endian ]
132 enum:
133 description: Name of the enum type used for the attribute.
135 enum-as-flags:
137 Treat the enum as flags. In most cases enum is either used as flags or as values.
138 … Sometimes, however, both forms are necessary, in which case header contains the enum
141 display-hint: &display-hint
146 enum: [ hex, mac, fddi, ipv4, ipv6, uuid ]
147 # End genetlink-legacy
149 attribute-sets:
162 name-prefix:
164 Prefix for the C enum name of the attributes. Default family[name]-set[name]-a-
166 enum-name:
167 description: Name for the enum type of the attribute.
172 subset-of:
174 Name of another space which this is a logical part of. Sub-spaces can be used to define
177 # Start genetlink-c
178 attr-cnt-name:
181 attr-max-name:
182 description: The explicit name for last member of attribute enum.
184 # End genetlink-c
195 type: &attr-type
197 enum: [ unused, pad, flag, binary, u8, u16, u32, u64, s32, s64,
198 string, nest, array-nest, nest-type-value ]
203 description: Value for the enum item representing this attribute in the uAPI.
205 type-value:
206 … description: Name of the value extracted from the type of a nest-type-value attribute.
210 byte-order:
211 enum: [ little-endian, big-endian ]
212 multi-attr:
214 nested-attributes:
215 description: Name of the space (sub-space) used inside the attribute.
217 enum:
218 description: Name of the enum type used for the attribute.
220 enum-as-flags:
222 Treat the enum as flags. In most cases enum is either used as flags or as values.
223 … Sometimes, however, both forms are necessary, in which case header contains the enum
231 flags-mask:
232 … description: Name of the flags constant on which to base mask (unsigned scalar types only).
237 min-len:
239 $ref: '#/$defs/len-or-define'
240 max-len:
242 $ref: '#/$defs/len-or-define'
243 sub-type: *attr-type
244 display-hint: *display-hint
245 # Start genetlink-c
246 name-prefix:
248 # End genetlink-c
249 # Start genetlink-legacy
253 # End genetlink-legacy
255 # Make sure name-prefix does not appear in subsets (subsets inherit naming)
257 name-prefix:
259 required: [ subset-of ]
260 subset-of:
262 required: [ name-prefix ]
270 enum-model:
274 to a single enum.
277 enum: [ unified, directional ] # Trim
278 name-prefix:
280 Prefix for the C enum name of the command. The name is formed by concatenating
283 enum-name:
284 description: Name for the enum type with commands.
286 async-prefix:
287 … description: Same as name-prefix but used to render notifications and events to separate enum.
289 async-enum:
290 description: Name for the enum type with notifications/events.
292 # Start genetlink-legacy
293 fixed-header: &fixed-header
295 Name of the structure defining the optional fixed-length protocol
299 # End genetlink-legacy
309 description: Name of the operation, also defining its C enum value in uAPI.
315 description: Value for the enum in the uAPI.
317 attribute-set:
322 flags: &cmd_flags
323 description: Command flags.
326 enum: [ admin-perm ]
327 dont-validate:
328 description: Kernel attribute validation flags.
331 enum: [ strict, dump ]
332 # Start genetlink-legacy
333 fixed-header: *fixed-header
334 # End genetlink-legacy
335 do: &subop-type
340 request: &subop-attr-list
347 Names of attributes from the attribute-set (not full attribute
352 # Start genetlink-legacy
358 # End genetlink-legacy
359 reply: *subop-attr-list
366 dump: *subop-type
382 mcast-groups:
400 # Start genetlink-c
401 c-define-name:
404 # End genetlink-c
405 flags: *cmd_flags
406 # Start netlink-raw
410 # End netlink-raw