summaryrefslogtreecommitdiff
path: root/Documentation/netlink/genetlink.yaml
diff options
context:
space:
mode:
authorJakub Kicinski <kuba@kernel.org>2023-10-25 09:22:53 -0700
committerJakub Kicinski <kuba@kernel.org>2023-10-26 19:42:15 -0700
commitbc30bb88ff3153fba7693557d15733179adf7492 (patch)
tree85beef9e91858e195754d7cd361f1fec6a0fcfae /Documentation/netlink/genetlink.yaml
parentea23fbd2a8f7dadfa9cd9b9d73f3b8a69eec0671 (diff)
netlink: specs: support conditional operations
Page pool code is compiled conditionally, but the operations are part of the shared netlink family. We can handle this by reporting empty list of pools or -EOPNOTSUPP / -ENOSYS but the cleanest way seems to be removing the ops completely at compilation time. That way user can see that the page pool ops are not present using genetlink introspection. Same way they'd check if the kernel is "new enough" to support the ops. Extend the specs with the ability to specify the config condition under which op (and its policies, etc.) should be hidden. Reviewed-by: Jiri Pirko <jiri@nvidia.com> Link: https://lore.kernel.org/r/20231025162253.133159-1-kuba@kernel.org Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'Documentation/netlink/genetlink.yaml')
-rw-r--r--Documentation/netlink/genetlink.yaml5
1 files changed, 5 insertions, 0 deletions
diff --git a/Documentation/netlink/genetlink.yaml b/Documentation/netlink/genetlink.yaml
index 501ed2e6c8ef..3283bf458ff1 100644
--- a/Documentation/netlink/genetlink.yaml
+++ b/Documentation/netlink/genetlink.yaml
@@ -264,6 +264,11 @@ properties:
type: array
items:
enum: [ strict, dump, dump-strict ]
+ config-cond:
+ description: |
+ Name of the kernel config option gating the presence of
+ the operation, without the 'CONFIG_' prefix.
+ type: string
do: &subop-type
description: Main command handler.
type: object