tools: ynl: cli: add --policy support
Add --policy flag which can be combined with --do or --dump to query
the kernel's netlink policy for an operation instead of executing it.
Examples:
$ ynl --family netdev --do dev-get --policy
{'ifindex': {'max-value':
4294967295, 'min-value': 1, 'type': 'u32'}}
$ ynl --family ethtool --do channels-get --policy --output-json
{"header": {"type": "nested", "policy": {"dev-index": ...}}}
$ ynl --family netdev --dump dev-get --policy
{}
Link: https://patch.msgid.link/20260310005337.3594225-6-kuba@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>