[PATCH v4 6/9] dts: add config parser module
Tu, Lijuan
lijuan.tu at intel.com
Wed Aug 10 08:33:02 CEST 2022
> -----Original Message-----
> From: Juraj Linkeš <juraj.linkes at pantheon.tech>
> Sent: Friday, July 29, 2022 6:56 PM
> To: thomas at monjalon.net; david.marchand at redhat.com; Randles, Ronan
> <ronan.randles at intel.com>; Honnappa.Nagarahalli at arm.com;
> ohilyard at iol.unh.edu; Tu, Lijuan <lijuan.tu at intel.com>
> Cc: dev at dpdk.org; Juraj Linkeš <juraj.linkes at pantheon.tech>
> Subject: [PATCH v4 6/9] dts: add config parser module
>
> From: Owen Hilyard <ohilyard at iol.unh.edu>
>
> The configuration is split into two parts, one defining the parameters of the test
> run and the other defining the topology to be used.
>
> The format of the configuration is YAML. It is validated according to a json
> schema which also servers as detailed documentation of the various
> configuration fields. This means that the complete set of allowed values are tied
> to the schema as a source of truth. This enables making changes to parts of DTS
> that interface with config files without a high risk of breaking someone's
> configuration.
>
> This configuration system uses immutable objects to represent the configuration,
> making IDE/LSP autocomplete work properly.
>
> There are two ways to specify the configuration file path, an environment
> variable or a command line argument, applied in that order.
>
> Signed-off-by: Owen Hilyard <ohilyard at iol.unh.edu>
> Signed-off-by: Juraj Linkeš <juraj.linkes at pantheon.tech>
> ---
> dts/conf.yaml | 7 ++
> dts/framework/config/__init__.py | 99 ++++++++++++++++++++++
> dts/framework/config/conf_yaml_schema.json | 73 ++++++++++++++++
> dts/framework/exception.py | 14 +++
> dts/framework/settings.py | 65 ++++++++++++++
> 5 files changed, 258 insertions(+)
> create mode 100644 dts/conf.yaml
> create mode 100644 dts/framework/config/__init__.py create mode 100644
> dts/framework/config/conf_yaml_schema.json
> create mode 100644 dts/framework/settings.py
>
Reviewed-by: Lijuan Tu <lijuan.tu at intel.com>
Thanks,
Lijuan
More information about the dev
mailing list