mbox series

[net-next,v3,0/2] tools: ynl-gen: fix parse multi-attr enum attribute

Message ID 20230718162225.231775-1-arkadiusz.kubalewski@intel.com (mailing list archive)
Headers show
Series tools: ynl-gen: fix parse multi-attr enum attribute | expand

Message

Kubalewski, Arkadiusz July 18, 2023, 4:22 p.m. UTC
Fix the issues with parsing enums in ynl.py script.

v2->v3:
- Restore i iterator helper for decoding 'enum-as-flag' attributes in
_decode_enum(..) function.
- Fix _decode_enum(..) usage in case of binary & struct type attributes
by moving it to as_struct() funtion while calling _decode_enum(..) for
individual struct members.

v1->v2:
Initially this was one patch, but review shown there is need to fix also
leftover issues with indexing in _decode_enum(..) function
("tools: ynl-gen: fix enum index in _decode_enum(..)").

Arkadiusz Kubalewski (2):
  tools: ynl-gen: fix enum index in _decode_enum(..)
  tools: ynl-gen: fix parse multi-attr enum attribute

 tools/net/ynl/lib/ynl.py | 24 ++++++++++++------------
 1 file changed, 12 insertions(+), 12 deletions(-)