aboutsummaryrefslogtreecommitdiffstats
path: root/tools/net/ynl/pyynl/cli.py
diff options
context:
space:
mode:
authorJakub Kicinski <[email protected]>2025-07-10 17:51:15 +0000
committerDavid S. Miller <[email protected]>2025-07-13 22:00:37 +0000
commitb06c4311711c57c5e558bd29824b08f0a6e2a155 (patch)
tree348477706504344cce645de71f1e8472e8e6f173 /tools/net/ynl/pyynl/cli.py
parentnet: dsa: mt7530: Constify struct regmap_config (diff)
downloadkernel-b06c4311711c57c5e558bd29824b08f0a6e2a155.tar.gz
kernel-b06c4311711c57c5e558bd29824b08f0a6e2a155.zip
tools: ynl: default to --process-unknown in installed mode
We default to raising an exception when unknown attrs are found to make sure those are noticed during development. When YNL CLI is "installed" and used by sysadmins erroring out is not going to be helpful. It's far more likely the user space is older than the kernel in that case, than that some attr is misdefined or missing. Signed-off-by: Jakub Kicinski <[email protected]> Reviewed-by: Donald Hunter <[email protected]> Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'tools/net/ynl/pyynl/cli.py')
-rwxr-xr-xtools/net/ynl/pyynl/cli.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/tools/net/ynl/pyynl/cli.py b/tools/net/ynl/pyynl/cli.py
index 33ccc5c1843b..8c192e900bd3 100755
--- a/tools/net/ynl/pyynl/cli.py
+++ b/tools/net/ynl/pyynl/cli.py
@@ -113,6 +113,8 @@ def main():
spec = f"{spec_dir()}/{args.family}.yaml"
if args.schema is None and spec.startswith(sys_schema_dir):
args.schema = '' # disable schema validation when installed
+ if args.process_unknown is None:
+ args.process_unknown = True
else:
spec = args.spec
if not os.path.isfile(spec):